Skip to content

Remove timestamps from asset URLs #202

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 5 commits into from
Closed

Conversation

rpkyle
Copy link
Contributor

@rpkyle rpkyle commented May 25, 2020

Closes #201 .

TODO:

@rpkyle rpkyle changed the base branch from master to dev May 25, 2020 20:12
@rpkyle rpkyle requested a review from Marc-Andre-Rivet May 25, 2020 20:12
@rpkyle rpkyle self-assigned this May 25, 2020
@rpkyle rpkyle force-pushed the 201-remove-timestamps branch from 84e4baa to c563db2 Compare May 25, 2020 22:13
@rpkyle
Copy link
Contributor Author

rpkyle commented May 26, 2020

@Marc-Andre-Rivet All references to ?m= have been expunged from Dash for R, yet this error appears on soft reloading CSS:

image

I believe the cause is L35745 within dash_renderer.dev.js, which appends ?m= with the CSS modification timestamp to the request coming in to the backend from the renderer:

if (a.modified > 0) {
  var link = document.createElement('link');
  link.href = "".concat(a.url, "?m=").concat(a.modified);
  link.type = 'text/css';
  link.rel = 'stylesheet';

  this._head.appendChild(link); // Else the file was deleted.
}

Is this also related to flask.Blueprint? Or can we eliminate the concat statements now?

Until 👆 is resolved and the soft reloading test passes again, this PR will have to be held.

@rpkyle rpkyle force-pushed the 201-remove-timestamps branch from 4b55896 to c563db2 Compare May 26, 2020 13:16
@rpkyle
Copy link
Contributor Author

rpkyle commented Aug 10, 2020

@Marc-Andre-Rivet I've opened an issue to track the above, since I hadn't previously: plotly/dash#1359. I can take this one on if it would be helpful.

@rpkyle
Copy link
Contributor Author

rpkyle commented Aug 16, 2020

It turns out that the underlying code which takes advantage of ?m is a bit more complex to remove based on the bug observed in plotly/dash#1363; this will likely be held until some housekeeping is done in Dash for Python as well.

@rpkyle rpkyle requested review from Marc-Andre-Rivet and removed request for Marc-Andre-Rivet August 26, 2020 05:30
@rpkyle rpkyle added this to the R & Julia milestone Aug 26, 2020
@Marc-Andre-Rivet Marc-Andre-Rivet modified the milestones: R & Julia, Platforms Oct 6, 2020
@rpkyle rpkyle closed this May 20, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Remove outdated timestamp for Dash assets
2 participants