-
-
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
sphinx.errors.VersionRequirementError: The sphinxcontrib.applehelp extension used by this project needs at least Sphinx v5.0 #11890
Comments
Sphinx only supports the latest version (i.e. currently 7.2.6; version 5 is unsupported). Sadly, Python's dependency system doesn't allow us to specify that the new versions of the sphinxcontrib packages require Sphinx 5 or newer without causing issues for others. c.f.:
A |
Yeah, I understand maintainers support only the latest release series, but I suppose I'm also not suggesting changing previous releases. This is a bug introduced with the recent help packages, and can be addressed there. I worry that this is a user hostile change, as the deprecation happens without warning. |
I'm open to suggestions, but what seems natural (adding a requirement of A |
Hah yeah, understand that completely. I wish I could suggest a better fix, but these changes are getting pretty deep into the arcane arts of Python packaging. I don't know what configuration would still allow Poetry/pip/etc to resolve the same dependencies as Bazel (outside explicit package pinning of course). For now, we see projects hitting this on RTD, but our build failure rate is not remarkably higher yet either. I don't have recent figures, but projects pinning Sphinx<=4 represent a shrinking but not trivial number of projects. |
This issue happens because Sphinx itself doesn't pin dependencies as seen here: Lines 59 to 64 in fa29004
To prevent this from happening in the future those dependencies should be pinned to a specific version. Likewise, the |
Running into the same issue here: https://readthedocs.org/projects/pyhd/builds/23253592/ |
Any solution to this error?
|
Changing requirements.txt solved the issue with me: |
Thanks. I just did that. |
Describe the bug
I'm having trouble fully understanding why this is happening, but I'll try to describe things as best I can.
The issue we're noticing is that if you install Sphinx < 5 in a fresh environment, your build will fail with the exception:
It seems the releases of the
sphinxcontrib-*help
packages a few days ago are maybe avoiding proper dependency resolution now. I noticed with pip and poetry that install Sphinx 4.5.0 still grabbed the latest versions of these packages.It seems this might all be related to commits similar to: sphinx-doc/sphinxcontrib-applehelp@ccc77c8
4 days prior to this, the build was successful, and Poetry installed the following dependencies while install Sphinx 4.5:
sphinxcontrib-applehelp-1.0.4
sphinxcontrib-devhelp-1.0.2
sphinxcontrib-htmlhelp-2.0.1
sphinxcontrib-qthelp-1.0.3
sphinxcontrib-serializinghtml-1.1.5
This is also maybe similar to problems in the past with docutils, Jinja, and other unpinned dependencies. New releases of these packages, and unpinned dependencies at Sphinx, caused abrupt upgrades to dependencies.
For anyone hitting this issue, you can upgrade Sphinx or pin the dependencies that were recently updated:
How to Reproduce
Here is a build on RTD showing the package installation, environment, and the build exception. Most importantly, note the Sphinx version is 4.5.0 and the
sphinxcontrib-*help
packages are all the latest releases.https://readthedocs.org/projects/test-builds/builds/23151025/
Environment Information
Sphinx extensions
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: