wzrd.in icon indicating copy to clipboard operation
wzrd.in copied to clipboard

Old version on /multi

Open serapath opened this issue 8 years ago • 4 comments

I'm trying to retrieve the newest version of dom-console If i'm doing that in any way but /multi it works. Also https://wzrd.in/status/dom-console shows version 4.0.1, but trying to fetch it via a POST request on the /multi route somehow gives me the old 3.2.0 version.

I already cleaned my local cache and hard reset reloaded the page - but no changes.

Not sure if https://wzrd.in/admin/cull/dom-console would be a quick fix ( i dont have admin credentials ) but maybe there is something in the code that shouldnt work like it currently works.

serapath avatar Mar 24 '17 04:03 serapath

Not sure if the culling module can handle multibundles, which are cached iirc at a separate layer. Sorry, I should have mentioned that over twitter.

jfhbrook avatar Mar 25 '17 05:03 jfhbrook

The hard-coded TTL is apparently 2 weeks https://github.com/jfhbrook/wzrd.in/blob/master/bundler/cache.js#L104

You might also be able to get around this by specifying 4.0.1 exactly when making your post, rather than latest (if that's not what's going on, I'm at a bit of a loss).

jfhbrook avatar Mar 25 '17 05:03 jfhbrook

looks like it's technically supported https://github.com/jfhbrook/wzrd.in/blob/master/admin.js#L34 but I think you need to know the bundle key https://github.com/jfhbrook/wzrd.in/blob/master/bundler/cache.js#L126-L132 for that to work...

jfhbrook avatar Mar 25 '17 05:03 jfhbrook

I'm not sure how to fix things or what exactly i need to do. How would i figure out what the latest module is?

Basically I made a little script for codepen.io to use require directly. It fetches the latest modules from wzrd.in and caches them in the browser.

This seems to work, but once i update the module on npm and wzrd.in did cache the module already, it wont pick up the new version from npm unless i'm specifying the exact version, so i added require('dom-console', '5.1.0') but i would rather not specify the version and have it always pick up the 'latest' version automatically :-) ...of course unless it's already cached locally - if it was, the user would need to clear his cache first, but that's fine for now i think...

serapath avatar May 18 '17 21:05 serapath