Closed Bug 1178027 Opened 9 years ago Closed 5 years ago

Firefox caches scripts built with TypeScript even if caching is disabled

Categories

(DevTools :: Debugger, defect)

41 Branch
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED INCOMPLETE

People

(Reporter: marco, Unassigned)

Details

For some reason, Firefox seems to cache scripts built with TypeScript even if the server is using all the no-cache headers.
The cached scripts are used even if I clear the browser cache.

It doesn't happen with normal JavaScript. In the app I'm working on I have a mixture of JS and TS, the changes to the JS files have visible effects.

I've noticed that when I open a script from the developer tools (so, a new tab is opened to "view-source:url"), the script that is opened is not the updated version. If I reload the "view-source:url" page, I see the updated script. If I reload the app's page again and reopen the script from the developer tools, I get the old version again.
Do you see this in Firefox 41? ISTR that we don't cache source-mapped sources anymore. Can you provide a test page/URL for debugging?
Component: Developer Tools → Developer Tools: Debugger
Flags: needinfo?(mar.castelluccio)
Are you talking about the debugger specifically, that it caches those files, or even that the page itself runs outdated files, regardless of the devtools?
(In reply to Panos Astithas [:past] from comment #1)
> Do you see this in Firefox 41? ISTR that we don't cache source-mapped
> sources anymore. Can you provide a test page/URL for debugging?

I was seeing this in Firefox 41 with https://github.com/mozilla/pluotsorbet, unfortunately it's not really a basic test case.
It was working correctly in a clean profile.

(In reply to James Long (:jlongster) from comment #2)
> Are you talking about the debugger specifically, that it caches those files,
> or even that the page itself runs outdated files, regardless of the devtools?

I believe the page itself was running outdated files, because some |console.log| that I added were not being logged.
Flags: needinfo?(mar.castelluccio)
Product: Firefox → DevTools

I'm sorry it's been awhile. Could you see if this is still relevant?

Flags: needinfo?(mcastelluccio)

I haven't been working on that for a while, it would be hard for me to reproduce now.

Status: NEW → RESOLVED
Closed: 5 years ago
Flags: needinfo?(mcastelluccio)
Resolution: --- → INCOMPLETE
You need to log in before you can comment on or make changes to this bug.