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

Could not import extension sphinxcontrib.mermaid (exception: cannot import name 'ExtensionError' from 'sphinx.util' ... #13002

Closed
IHMEkaleb opened this issue Oct 10, 2024 · 5 comments

Comments

@IHMEkaleb
Copy link

Describe the bug

When I run sphinx-build with sphinxcontrib.mermaid 0.9.2 and sphinx 8.1.0, I get this error:

sphinx-build /path/to/docs /path/for/build/output
Running Sphinx v8.1.0
loading translations [en]... done

Extension error:
Could not import extension sphinxcontrib.mermaid (exception: cannot import name 'ExtensionError' from 'sphinx.util' (/path/to/my_env/lib/python3.11/site-packages/sphinx/util/__init__.py))

However, with sphinx 8.0.x, it builds fine.

How to Reproduce

  1. Install sphinxcontrib.mermaid 0.9.2 and sphinx 8.1.0, and add the extension.
  2. Run sphinx-build.
  3. Build fails.

Environment Information

`sphinxcontrib.mermaid=0.9.2` and `sphinx=8.1.0`

Sphinx extensions

sphinxcontrib.mermaid

Additional context

Filed same issue with Mermaid: mermaid-js/mermaid#5954

@AA-Turner
Copy link
Member

sphinxcontrib.mermaid should use the proper import location for sphinx.errors.ExtensionError.

A

@AA-Turner AA-Turner closed this as not planned Won't fix, can't repro, duplicate, stale Oct 10, 2024
@AA-Turner
Copy link
Member

@IHMEkaleb you should report this to https://github.com/mgaitan/sphinxcontrib-mermaid

A

@IHMEkaleb
Copy link
Author

@IHMEkaleb you should report this to https://github.com/mgaitan/sphinxcontrib-mermaid

A

Done here: mermaid-js/mermaid#5954

@IHMEkaleb
Copy link
Author

Oh, wait, AA-Turner, I see that you responded in that ticket as well and have added it to the 8.1.0 milestone here. Thanks!

@jacobtomlinson
Copy link

I've proposed mgaitan/sphinxcontrib-mermaid#161 to resolve this

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants