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

Sphinx 1.7 changed more APIs #73

Closed
bitprophet opened this issue Mar 28, 2018 · 6 comments
Closed

Sphinx 1.7 changed more APIs #73

bitprophet opened this issue Mar 28, 2018 · 6 comments
Labels

Comments

@bitprophet
Copy link
Owner

Or something. See e.g. invocations exploding when it attempts to import Releases 1.4.0 on travis recently (with no changes on my end on either project):

Traceback (most recent call last):
  File "/home/travis/virtualenv/python2.7.14/bin/inv", line 11, in <module>
    sys.exit(program.run())
  File "/home/travis/virtualenv/python2.7.14/lib/python2.7/site-packages/invoke/program.py", line 282, in run
    self.parse_collection()
  File "/home/travis/virtualenv/python2.7.14/lib/python2.7/site-packages/invoke/program.py", line 356, in parse_collection
    self.load_collection()
  File "/home/travis/virtualenv/python2.7.14/lib/python2.7/site-packages/invoke/program.py", line 508, in load_collection
    module, parent = loader.load(coll_name)
  File "/home/travis/virtualenv/python2.7.14/lib/python2.7/site-packages/invoke/loader.py", line 69, in load
    module = imp.load_module(name, fd, path, desc)
  File "/home/travis/build/pyinvoke/invocations/tasks.py", line 3, in <module>
    from invocations.packaging import release
  File "/home/travis/build/pyinvoke/invocations/invocations/packaging/__init__.py", line 3, in <module>
    from . import release
  File "/home/travis/build/pyinvoke/invocations/invocations/packaging/release.py", line 30, in <module>
    from releases.util import parse_changelog
  File "/home/travis/virtualenv/python2.7.14/lib/python2.7/site-packages/releases/util.py", line 15, in <module>
    from sphinx.environment import (
ImportError: cannot import name SphinxStandaloneReader

(link: https://travis-ci.org/pyinvoke/invocations/jobs/357642688#L573-L593)

Kinda frustrating since it's not like that particular class is marked as being private or anything, but, such is Sphinx.

Need to either dial back Releases' setup.py (which I'm not a fan of but given Sphinx has broken us two minor releases in a row, seems prudent...) or dive in and add more conditional imports and such.

@bitprophet bitprophet added the bug label Mar 28, 2018
@bitprophet
Copy link
Owner Author

Fixed in 8276fa8 - neglected to add commit msg hook. (It's a day.)

@bitprophet
Copy link
Owner Author

Well, let's leave this open since it's not actually "fixed" aside from the dependency update. I would certainly like to support Sphinx 1.7 sometime.

@bitprophet bitprophet reopened this Mar 28, 2018
@rixx
Copy link

rixx commented Jun 17, 2018

I'd really appreciate you supporting Sphinx 1.7. If there is anything people can do to help with that, please let us know.

@bitprophet
Copy link
Owner Author

bitprophet commented Jun 19, 2018

@rixx Not a lot that can be done besides somebody deep-diving to identify exactly what breaks on our end, what the diff was in Sphinx which caused it, and figuring out how we can adapt to get back to functionality.

Typically involves a lot of either duck typing or explicit Sphinx version checking, which we already have in a few places (though I may be partly remembering Alabaster). As usual preference is on the former ("can I import module X / does object Y have attribute Z?") over the latter ("if Sphinx 1.7, do X, else do Y").

@hroncok
Copy link
Contributor

hroncok commented Jun 26, 2018

This might only be moved SphinxStandaloneReader module. Will try.

@hroncok
Copy link
Contributor

hroncok commented Jun 26, 2018

Prepping a PR.

hroncok added a commit to hroncok/releases that referenced this issue Jun 26, 2018
hroncok added a commit to hroncok/releases that referenced this issue Jun 26, 2018
hroncok added a commit to hroncok/releases that referenced this issue Jun 26, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants