seasick / openscad-web-gui

Web GUI for OpenSCAD, using OpenSCAD WASM
https://seasick.github.io/openscad-web-gui/
GNU General Public License v3.0
45 stars 5 forks source link

Script appears to be cached, and does not load latest version #47

Open ostat opened 6 months ago

ostat commented 6 months ago

Describe the bug It appears that the openscad script is cached somewhere. reloading the page does not reload the script.

To Reproduce I am using this link https://seasick.github.io/openscad-web-gui/?https%3A%2F%2Fraw.githubusercontent.com%2Fostat%2Fgridfinity_extended_openscad%2Fmain%2Fcombined%2Fgridfinity_basic_cup.scad Within openscad-web-gui I can see the version of the script is 2024-02-17 image

However I can see that the script has been updated since then https://raw.githubusercontent.com/ostat/gridfinity_extended_openscad/main/combined/gridfinity_basic_cup.scad image

Expected behavior I expected that each time the page is loaded it would get the latest version of the script from the source.

Environment

Openscad Script Provided above

seasick commented 5 months ago

Thanks for raising the issue. This has definitely to do with the used CORS proxy. I sent a request to cors.sh as I hope I have more control over caching times with them.

I expected that each time the page is loaded it would get the latest version of the script from the source.

I fear that this might not be feasible - at least not with free services. But another thing I could do is to add some kind of cache buster. Like a parameter that will be appended to the given url (e.g. https://seasick.github.io/openscad-web-gui/?https%3A%2F%2Fraw.githubusercontent.com%2Fostat%2Fgridfinity_extended_openscad%2Fmain%2Fcombined%2Fgridfinity_basic_cup.scad?___busted=1234)