[es-dev-server] stale files after git checkout
See original GitHub issueI have started using es-dev-server
to work on a large project (1000+ modules) and I really like the fact that it sets proper cache headers. This feature dropped the development loading time from 10s to 1.5s (I was using polymer serve
).
Unfortunately, I ran into a problem: the server sends stale responses after switching branches. This is the scenario:
- checkout master
- start es-dev-server
- edit a file
- confirm that latest version is served
- checkout feature branch
- confirm that feature branch code is served
- edit the same file
- notice that the feature branch version is still served, instead of the edited code
if 8 did not happen, then checkout master again and notice that the code from 7. is still served.
This staleness does not go away until I restart the server, no matter how many times I edit and save the file.
This is not a browser cache problem, as I have tested this with disabled cache (via network panel).
My hunch is that it’s somehow related to the filesystem change event, but I have yet to look in the es-dev-server internals.
P.S. Thank you for this awesome project! ❤️
Issue Analytics
- State:
- Created 4 years ago
- Reactions:1
- Comments:10 (6 by maintainers)
Top GitHub Comments
I have tried to replicate the issue, but it does not seem to happen anymore. The load time was not affected by this change. Thank you very much for resolving this! 🥂
Closing as solved. Thank you for the issue. Please tell us if this continues to be a problem.