Skip to content

Allow CircleCI to load version switcher hosted on matplotlib.org #27861

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
dstansby opened this issue Mar 4, 2024 · 4 comments
Closed

Allow CircleCI to load version switcher hosted on matplotlib.org #27861

dstansby opened this issue Mar 4, 2024 · 4 comments
Labels
Documentation: website layout/behavior/styling changes

Comments

@dstansby
Copy link
Member

dstansby commented Mar 4, 2024

I'm currently trying to bump the version of pydata-sphinx-theme that we're using (#27658), so we can get recent accessibility improvements from the theme. It's not currently possible to load the version switcher hosted at https://matplotlib.org/devdocs/_static/switcher.json on the documentation build that CircleCI generates. The console error is:

Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at https://matplotlib.org/devdocs/_static/switcher.json?v3.8.1-1173-gfa55c9f44. (Reason: CORS header ‘Access-Control-Allow-Origin’ missing). Status code: 200.

Is there anyone who has access to the Matplotlib website that can fix this to allow pages served by https://output.circle-artifacts.com to load https://matplotlib.org/devdocs/_static/switcher.json ? If this needs any more debugging, here's a link to the full CircleCI doc build on the PR updating pydata-sphinx-theme.

@dstansby dstansby added the Documentation: website layout/behavior/styling changes label Mar 4, 2024
@tacaswell
Copy link
Member

I'm not sure that we want to open up the holes required to opt out of that CORS protection.

@dstansby
Copy link
Member Author

dstansby commented Mar 4, 2024

👍 in that case (I have zero knowledge/experience of these things) I'm happy to close this, and work out how to turn off the version switcher in the CircleCI build.

@dstansby dstansby closed this as not planned Won't fix, can't repro, duplicate, stale Mar 4, 2024
@dstansby
Copy link
Member Author

dstansby commented Mar 5, 2024

FWIW I worked out how to use the version switcher that circleCI hosts with each artifact upload, so no need for this PR or a workaround on the circleCI builds.

@QuLogic
Copy link
Member

QuLogic commented Mar 6, 2024

Some time ago, I manually allowed this for CircleCI. However, this was not a long-term solution, so it was overwritten the next time we refreshed the server, which is why it stopped working again.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Documentation: website layout/behavior/styling changes
Projects
None yet
Development

No branches or pull requests

3 participants