Commit
1 year ago
gh-38100: Remove nitpick_patch_config function <!-- ^ Please provide a concise and informative title. --> <!-- ^ Don't put issue numbers in the title, do this in the PR description below. --> <!-- ^ For example, instead of "Fixes #12345" use "Introduce new method to calculate 1 + 2". --> <!-- v Describe your changes below in detail. --> <!-- v Why is this change required? What problem does it solve? --> <!-- v If this PR resolves an open issue, please link to it here. For example, "Fixes #12345". --> Fixes #37996. We remove this function ```python def nitpick_patch_config(app): """ Patch the default config for nitpicky [...] ensure that nitpicky is not considered as a Sphinx environment variable but rather as a Sage environment variable. As a consequence, changing it doesn't force the recompilation of the entire documentation. """ app.config.values['nitpicky'] = (False, 'sage') app.config.values['nitpick_ignore'] = ([], 'sage') ``` from `src/sage_docbuild/conf.py`. The original purpose of the function seems to change `"env"` to `"sage"` for `nitpicky` config variable. But the recent Sphinx is setting `""` (empty string) instead of `"env"` by default. See https://github.com/sphinx-doc/sphinx/blob/48cbb43e28efe82b198137042811e0 ade3599ae7/sphinx/config.py#L250C1-L250C41 - Hence the function is already no-op. But this old and obsolete function is the cause of #37996. Hence we simply remove it. - To prepare for Sphinx 7.3.7, we also remove some code which seems to have become obsolete when `sage -clone` was removed long time ago. - Made some docstring up-to-date, to test incremental doc build. ### :memo: Checklist <!-- Put an `x` in all the boxes that apply. --> - [x] The title is concise and informative. - [x] The description explains in detail what this PR is about. - [x] I have linked a relevant issue or discussion. - [ ] I have created tests covering the changes. - [ ] I have updated the documentation and checked the documentation preview. ### :hourglass: Dependencies <!-- List all open PRs that this PR logically depends on. For example, --> <!-- - #12345: short description why this is a dependency --> <!-- - #34567: ... --> URL: https://github.com/sagemath/sage/pull/38100 Reported by: Kwankyu Lee Reviewer(s):
Author
Release Manager
Loading