Open chrisjsewell opened 1 year ago
cc @choldgraf
Good on the whole though cheers 👌
Note, I think it only happens on rebuilds where nothing changes:
building [mo]: targets for 0 po files that are out of date
building [html]: targets for 0 source files that are out of date
updating environment: 0 added, 0 changed, 0 removed
looking for now-outdated files... none found
no targets are out of date.
Writing redirects...
WARNING: Color theme None not found by pygments, falling back to tango.
WARNING: Color theme None not found by pygments, falling back to monokai.
build finished with problems, 2 warnings.
Interesting - I wonder if the pygments themes aren't being added to the build because they are depending on a sphinx event that sometimes does not trigger or something 🤔
@trallard do you have any idea why we would be seeing this error in the book theme?
Not sure - but I can look into this tomorrow.
@trallard did you get a chance to look into this? has it been reported in any other projects that use these pygments stylings?
Ah I forgot 😂 looking into this today.
But so far this has not been reported elsewhere
Yeh not critical, but it is reproducible
Myst-parser is using rc2 at the moment btw: https://myst-parser.readthedocs.io/ 😄
On the pydata theme I wasn't able to reproduce this (ie, by building the docs once, then re-building them immediately, though I did find this bug https://github.com/pydata/pydata-sphinx-theme/issues/1222). I was able to reproduce it on the sphinx-book-theme. So for some reason something different is happening in this theme than in the pydata theme.
Ok so did some hunting and this was reported in https://github.com/pydata/pydata-sphinx-theme/issues/1081
Which resolved by adding accessible-pygments
as a full dependency to the theme.
I think we could improve the warning upstream - but in any case this should be fixed if the Pydata Sphinx theme version used is upgraded.
I have the same problem on a simple sphinx-build using pydata-sphinx-theme, but I checked and in my environment I have accessible-pygments
...
any news on this? it seems to be also erratic: 5' ago I didn't see it and now it popped out again!
I think this should be fixed now by pydata/pydata-sphinx-theme#1264. Hopefully now nobody ever sees that warning unless they actually request a pygments theme that doesn't exist.
Heya, just tried updating myst-parser to
sphinx-book-theme==1.0.0rc2
, but now on rebuilds I get 😢 :Not very informative, but managed to hunt down the warning to:
https://github.com/pydata/pydata-sphinx-theme/blame/0c0d6ca130953ac92ce454ea2d11167d7373e76d/src/pydata_sphinx_theme/__init__.py#L911
I'll leave you guys to deal with upstreaming the problem, I would also suggest that the warning be changed, to indicate that it's from pydata-sphinx-theme, and even give it a type/subtype to suppress