-
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
AttributeError: 'Values' object has no attribute 'section_self_link' #9825
Comments
That's strange. How did you install docutils-0.18? Sphinx-4.2.0 depends docutils < 0.18. So it seems your environment is inconsistent. Please downgrade docutils to 0.17.1. |
I installed everything using When I create my own virtualenv and install
But somehow when I run tox, it installs docutils 0.18.
Aha, so the clue is in the message:
So pip is telling me it knows it's installed incompatible versions and it can't do anything about it. But why does it do that only when invoked by tox? Strangely, even when I run those same commands on my own, I'm unable to replicate the behavior that I see when running under tox.
My best guess at this point is virtualenv is passing parameters to pip in secret (such as through environment variables) that are somehow triggering the use of the legacy resolver. Perhaps the fact that the project under test (pytest-checkdocs) depends on docutils is a factor. In any case, thanks for pointing to the cause and helping me discover the issue. I'll follow up with the tox project to figure out why the legacy resolver is being used. |
…/sphinx#9825." This reverts commit aa1c71c.
confirm - update lib to sphinx==4.3.0 version - it will fix your issue |
While working on another PR I ran into this bug on my test website. I had a test document with only an HTML code block and found out unescaped HTML was added to the meta tag: ```html <meta property="og:description" content="<meta property="og:image" content="_images/normal.jpg" /> <img alt="_images/normal.jpg" src="_images/normal.jpg" />" /> <meta property="og:image" content="_images/normal.jpg" /> ``` Fixing this by skipping literal blocks. Also fixed docs build. I was getting the exception: `AttributeError: 'Values' object has no attribute 'section_self_link'` This was caused by sphinx-doc/sphinx#9825. Updating dependencies fixed the issue.
While working on another PR I ran into this bug on my test website. I had a test document with only an HTML code block and found out unescaped HTML was added to the meta tag: ```html <meta property="og:description" content="<meta property="og:image" content="_images/normal.jpg" /> <img alt="_images/normal.jpg" src="_images/normal.jpg" />" /> <meta property="og:image" content="_images/normal.jpg" /> ``` Fixing this by skipping literal blocks. Also fixed docs build. I was getting the exception: `AttributeError: 'Values' object has no attribute 'section_self_link'` This was caused by sphinx-doc/sphinx#9825. Updating dependencies fixed the issue.
Describe the bug
In the pytest-checkdocs project, I'm running
tox -e docs
and the run fails with this output:Full traceback is here:
The issue is new to Sphinx 4.2. If I run the tests on Python 3.9 and Sphinx 4.1.2, the docs build, though with a warning:
That warning is just a nitpick.
Docs are building on other projects, so there must be something unique about this project that's triggering the failure.
How to Reproduce
Expected behavior
Docs should build or provide an actionable error message.
Your project
https://github.com/jaraco/pytest-checkdocs
Screenshots
No response
OS
macOS 12
Python version
3.9
Sphinx version
4.2
Sphinx extensions
'sphinx.ext.autodoc', 'jaraco.packaging.sphinx', 'rst.linker', 'sphinx.ext.intersphinx'
Extra tools
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: