Skip to content
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

DOC: Switch to pydata-sphinx-theme #1013

Merged
merged 31 commits into from
Feb 9, 2023

Conversation

larsoner
Copy link
Contributor

I hit a bug during doc build I thought was due to sphinx_rtd_theme, so I decided to try pydata-sphinx-theme to see if it would fix it. It didn't, but given that this simplifies our config a bit and matches what a bunch of other scientific packages are doing (numpy, scipy, matplotlib, scikit-learn, etc.) let's see if it looks good enough to keep. (Or really, seems like it's headed in a good enough direction to tweak a little bit more then merge!)

@GaelVaroquaux
Copy link
Contributor

GaelVaroquaux commented Sep 23, 2022 via email

@lucyleeow
Copy link
Contributor

Is it possible to add a left sidebar containing all sections?

https://pydata-sphinx-theme.readthedocs.io/en/v0.7.2/user_guide/configuring.html#configure-the-navigation-depth-and-collapsing-of-the-sidebar
Maybe with:

html_theme_options = {
  "navigation_depth": 2
}

?

@melissawm
Copy link
Contributor

Hi folks - I checked this branch locally and managed to build the docs by pinning sphinx<6 - see pydata/pydata-sphinx-theme#1094

@larsoner
Copy link
Contributor Author

Okay I got CIs happy and restructured things a bit to fit into the structure pydata-sphinx-theme prefers. I don't think this is perfect but I think it's good enough to merge and iterate on separately:

https://output.circle-artifacts.com/output/job/2fafe7f8-0fa1-496b-bb1b-3ce512240068/artifacts/0/rtd_html/index.html

I think that we should maybe tweak it a tiny bit to have a distinguishable visual identity,

For this I created an "icon" using an emoji, which is hopefully good enough until someone with more artistic skills can make a pass on the design :)

Good enough for now @lucyleeow @GaelVaroquaux ?

Also @melissawm since you showed some interest and got me working on this again :) -- if you have specific usability suggestions you'd like to push, feel free to make a PR based on my to my fork and I'll merge it there, then we can hopefully merge here!

@melissawm
Copy link
Contributor

@larsoner thanks for the ping - I think this looks amazing, thanks for this 🚀

@choldgraf
Copy link
Contributor

We'll get a new pydata-sphinx-theme release out soon I promise! If you like, try out the RC and provide feedback so we don't break something!

* upstream/master:
  TST: gallery inventory/re-structure tinybuild (sphinx-gallery#1072)
  MAINT: Fix CIs (sphinx-gallery#1074)
@larsoner
Copy link
Contributor Author

larsoner commented Feb 9, 2023

@choldgraf the failure here seems like a bug in pydata-sphinx-theme:

WARNING: The version switcher "[https://sphinx-gallery.github.io/dev/_static/switcher.json"](https://sphinx-gallery.github.io/dev/_static/switcher.json%22) file cannot be read due to the following error:
HTTPError('404 Client Error: Not Found for url: https://sphinx-gallery.github.io/dev/_static/switcher.json')

note the extra ') at the end of the URL. This happens in our one Windows test, but in the Linux ones that use the same config. Do you test sphinx builds on Windows with a switcher.json over there?

@larsoner
Copy link
Contributor Author

larsoner commented Feb 9, 2023

Argh wait no I think this is my error, let me confirm...

@larsoner
Copy link
Contributor Author

larsoner commented Feb 9, 2023

All green! I'll merge this so we can start trying this out. Fingers crossed it doesn't cause any problems...

@larsoner larsoner merged commit caef783 into sphinx-gallery:master Feb 9, 2023
@larsoner larsoner deleted the pydata-sphinx-theme branch February 9, 2023 18:09
@larsoner
Copy link
Contributor Author

larsoner commented Feb 9, 2023

Seems to be working

https://sphinx-gallery.github.io/dev/index.html

@GaelVaroquaux
Copy link
Contributor

GaelVaroquaux commented Feb 9, 2023 via email

@GaelVaroquaux
Copy link
Contributor

image

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.

6 participants