Repository navigation
ci(docs): build the documentation in the official GDAL image - #532
Merged
Merged
Conversation
Run the docs job in ghcr.io/osgeo/gdal:ubuntu-small-3.11.0, the same image as the root Dockerfile, so libgdal and the osgeo Python bindings are already installed and version-matched. This removes the ubuntugis PPA, the apt GDAL packages, setup-python and the compilation of the GDAL wheel. Python tooling and Tk are installed with apt, and a virtual environment created with --system-site-packages exposes the image's osgeo bindings to the project. AI-Level: 7 AI-Model: Claude Sonnet 5.5 Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01CUNZAXTg3vthj5KZYCgf3m
| # Install GDAL first | ||
| python -m pip install GDAL=="`gdal-config --version`.*" | ||
| - name: Upgrade packaging tools | ||
| run: python -m pip install -U pip setuptools wheel |
| # Install GDAL first | ||
| python -m pip install GDAL=="`gdal-config --version`.*" | ||
| - name: Upgrade packaging tools | ||
| run: python -m pip install -U pip setuptools wheel |
…icogis.ui The documentation build did not install PyQt6, so autodoc failed to import the 14 GUI and qt_compat modules and their API pages were empty. Install the gui extra and the system libraries PyQt6 needs to be imported in the GDAL image. AI-Level: 7 AI-Model: Claude Sonnet 5.5 Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01CUNZAXTg3vthj5KZYCgf3m
The API pages of dicogis.ui need PyQt6 to be importable, as in the CI workflow. AI-Level: 7 AI-Model: Claude Sonnet 5.5 Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01CUNZAXTg3vthj5KZYCgf3m
|
| - name: Install project as a package | ||
| run: python -m pip install .[doc] | ||
| # gui extra: PyQt6 must be importable so autodoc can document dicogis.ui | ||
| run: python -m pip install .[doc,gui] |
| - name: Install project as a package | ||
| run: python -m pip install .[doc] | ||
| # gui extra: PyQt6 must be importable so autodoc can document dicogis.ui | ||
| run: python -m pip install .[doc,gui] |
This was referenced Nov 6, 2026
Guts
added a commit
that referenced
this pull request
Nov 6, 2026
…als (#533) ## Description Remove the Sphinx warnings that appeared on the API pages of `dicogis.ui` now that PyQt6 is installed in the documentation build (#532): - six module docstrings raised "Unexpected indentation": the `Name/Purpose/Author` headers of `wdg_tab_publish`, `workers`, `progress` and `read_vector_flat_dataset` become a reStructuredText field list, and the continuation lines of `ui/main` and `mw_dicogis` are dedented; - the unescaped `*.dbconf` of `read_db_conf` is put in a literal; - PyQt gives every signal without a docstring of its own a generic one containing `*types`, read as an unfinished emphasis: a small `autodoc-process-docstring` hook in `docs/conf.py` drops it and leaves the signals documented by hand untouched. The six docstrings were checked with docutils and the hook on a minimal Sphinx project; the full build has not been run locally (it needs GDAL), so the CI run of this PR is the confirmation. ## Related issue(s) Follows #532. ## Type of change - [ ] Bug fix (`fix/…` branch) - [ ] New feature or enhancement (`feature/…` branch) - [x] Documentation (`docs/…` branch or `*.md`/`docs/**` changes) - [ ] Packaging / build (`packaging/…` branch or `builder/**` changes) - [ ] Tooling / CI-CD (`tooling/…` branch or `.github/**` changes) - [ ] Tests only (`tests/**` changes) ## Checklist - [ ] I have read the [Contributing Guidelines](/CONTRIBUTING.md) - [ ] `pre-commit run --all-files` passes locally - [ ] I have added or updated tests covering my changes - [ ] I have updated the documentation where relevant - [ ] `pytest` passes locally ## AI/LLM disclosure - Level: 7 (human specced, bots coded) - Model: Claude Sonnet 5.5 - Session: https://claude.ai/code/session_01CUNZAXTg3vthj5KZYCgf3m --- _Generated by [Claude Code](https://claude.ai/code/session_01CUNZAXTg3vthj5KZYCgf3m)_
Guts
added a commit
that referenced
this pull request
Nov 6, 2026
## Description `docs/usage/cli.md` was empty: `sphinx-click` failed with `TypeError: 'module' object is not callable` when importing `dicogis.cli.main:click_object`. With Sphinx 9.1, `from sphinx.ext.autodoc import mock` returns the `mock` module instead of the function once `sphinx_autodoc_typehints` has been imported (sphinx-doc/sphinx#14333), and `sphinx_click` calls it. Loading `sphinx_click` first in `extensions` keeps the function. The order is no longer alphabetical, hence the comment in `docs/conf.py`. Reproduced on a minimal Sphinx project with both extension orders: the error occurs with `sphinx_autodoc_typehints` first and not with `sphinx_click` first. The full build has not been run locally, so the CI run of this PR is the confirmation. ## Related issue(s) Follows #532. ## Type of change - [ ] Bug fix (`fix/…` branch) - [ ] New feature or enhancement (`feature/…` branch) - [x] Documentation (`docs/…` branch or `*.md`/`docs/**` changes) - [ ] Packaging / build (`packaging/…` branch or `builder/**` changes) - [ ] Tooling / CI-CD (`tooling/…` branch or `.github/**` changes) - [ ] Tests only (`tests/**` changes) ## Checklist - [ ] I have read the [Contributing Guidelines](/CONTRIBUTING.md) - [ ] `pre-commit run --all-files` passes locally - [ ] I have added or updated tests covering my changes - [ ] I have updated the documentation where relevant - [ ] `pytest` passes locally ## AI/LLM disclosure - Level: 7 (human specced, bots coded) - Model: Claude Sonnet 5.5 - Session: https://claude.ai/code/session_01CUNZAXTg3vthj5KZYCgf3m --- _Generated by [Claude Code](https://claude.ai/code/session_01CUNZAXTg3vthj5KZYCgf3m)_
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.




Description
Build the documentation in the official GDAL image (
ghcr.io/osgeo/gdal:ubuntu-small-3.11.0, the same as the rootDockerfile) instead of installing GDAL on the runner.libgdaland theosgeobindings are already installed and version-matched, which removes the ubuntugis PPA, the apt GDAL packages,setup-pythonand the compilation of theGDALwheel.Python tooling and Tk are installed with apt, and a virtual environment created with
--system-site-packagesexposes the image's bindings to the project, as in theDockerfile.Points to check on the first run:
pipdeptreeandpip-licensesnow run in a venv that also sees system packages, sodocs/misc/dependencies.mdanddocs/misc/licenses.mdmay list more packages than before.requires-python.setup-pythonis gone.This has not been run yet: the workflow only triggers on
docs/**or workflow changes in pull requests, so this PR's own run is the first test.Related issue(s)
None.
Type of change
fix/…branch)feature/…branch)docs/…branch or*.md/docs/**changes)packaging/…branch orbuilder/**changes)tooling/…branch or.github/**changes)tests/**changes)Checklist
pre-commit run --all-filespasses locallypytestpasses locallyAI/LLM disclosure
Generated by Claude Code