mirror of
https://github.com/fish-shell/fish-shell.git
synced 2026-05-29 18:51:15 -03:00
Revert "Only load sphinx_markdown_builder extension if it's used"
sphinx-build fails with sphinx.errors.SphinxError: Builder name markdown not registered or available through entry point Apparently this issue was hidden locally by caching, and not checked in CI because of this error causing tests/checks/sphinx-markdown-changelog.fish to be skipped. sphinx-build 7.2.6 runner@runnervm3ublj:~/work/fish-shell/fish-shell$ python -c 'import sphinx_markdown_builder' Traceback (most recent call last): File "<string>", line 1, in <module> File "/home/runner/.local/lib/python3.12/site-packages/sphinx_markdown_builder/__init__.py", line 6, in <module> from sphinx.util.typing import ExtensionMetadata ImportError: cannot import name 'ExtensionMetadata' from 'sphinx.util.typing' (/usr/lib/python3/dist-packages/sphinx/util/typing.py) This reverts commit7b495497d7. While at it, fail the test earlier if something went wrong, because the remaining check will likely also fail and confuse. (cherry picked from commitaab22a453b)
This commit is contained in:
@@ -6,7 +6,9 @@ permissions:
|
||||
runs:
|
||||
using: "composite"
|
||||
steps:
|
||||
- run: |
|
||||
commit=a6dd85e7b13107172c0502937bec6b718002510d
|
||||
- shell: bash
|
||||
run: |
|
||||
set -x
|
||||
commit=b259de1dc97573a71470a1d71c3d83535934136b
|
||||
pip install git+https://github.com/krobelus/sphinx-markdown-builder@"$commit"
|
||||
shell: bash
|
||||
python -c 'import sphinx_markdown_builder'
|
||||
|
||||
@@ -16,6 +16,10 @@ from docutils import nodes
|
||||
|
||||
try:
|
||||
import sphinx_markdown_builder
|
||||
|
||||
extensions = [
|
||||
"sphinx_markdown_builder",
|
||||
]
|
||||
except ImportError:
|
||||
pass
|
||||
|
||||
|
||||
@@ -7,7 +7,10 @@ if not test -e $workspace_root/.git
|
||||
return
|
||||
end
|
||||
|
||||
$workspace_root/build_tools/release-notes.sh -q >relnotes.md
|
||||
or echo "Failed to build Markdown release notes."
|
||||
$workspace_root/build_tools/release-notes.sh -q >?relnotes.md
|
||||
or {
|
||||
echo "Failed to build Markdown release notes."
|
||||
return
|
||||
}
|
||||
sed -n 1p relnotes.md | grep -q '^## fish \S* (released .*)'
|
||||
or echo "Unexpected changelog title"
|
||||
|
||||
Reference in New Issue
Block a user