Page MenuHomePhabricator

[Sphinx] Adjust for source_parsers deprecation in Sphinx 3.0
ClosedPublic

Authored by JDevlieghere on Feb 27 2020, 11:37 AM.

Details

Summary

Update the Sphinx configuration for the removal of source_parsers in Sphinx 3.0. The variable has been deprecated since version 1.8.

Version 1.8 deprecates and version 3.0 removes the source_parsers configuration variable that was used by older recommonmark versions.

https://www.sphinx-doc.org/en/master/usage/markdown.html

Diff Detail

Event Timeline

JDevlieghere created this revision.Feb 27 2020, 11:37 AM
Herald added a project: Restricted Project. · View Herald TranscriptFeb 27 2020, 11:37 AM

Don't bump the minimum sphinx version as the bot's are running 1.7. Before this land we should verify that the new config variable works with older Sphinx.

hans added a comment.Feb 28 2020, 2:40 AM

I don't really know anything about Sphinx, but sounds good to me if it works I guess :-)

This revision is now accepted and ready to land.Jun 18 2020, 3:43 AM
This revision was automatically updated to reflect the committed changes.

it breaks the build on Debian stable (and probably some Ubuntu LTS). With sphinx 1.8.4
Could you please revert the change ?

Sphinx error:
Source parser for markdown not registered

Ping here?

It seems like even the most recent version of the package is still 0.4 and this change seems to require 0.5: https://packages.ubuntu.com/groovy/python3-recommonmark

llvm.org/docs aren't regenerated for a few days, I don't know if it is related?

Make the change conditional on the Sphinx version.

Would someone with this setup be able to test this?

This patch works on my machine right now!

Is the sphinx version a direct indicator of the recommonmark version?

This patch works on my machine right now!

Is the sphinx version a direct indicator of the recommonmark version?

Thanks for checking, Mehdi! No, it is not, but given that Sphinx deprecates the old behavior, there's no way to make recommonmark < 0.5 with Sphinx > 3.0, at least to the best of my understanding.