Skip to content

Commit ce7346b

Browse files
Fix caching issue that led to incorrect all-options.rst being merged on main (#10320)
Using tox works because tox does not use the cached venv from the github action. It's not efficient but this is a fast fix. We removed the pre-commit hook for doc generation because it's too slow to be usable and we have already two ways to generate the doc. Also "make build-html" does not exists anymore so upgraded the doc. Co-authored-by: Pierre Sassoulas <[email protected]>
1 parent 4471242 commit ce7346b

File tree

5 files changed

+7
-21
lines changed

5 files changed

+7
-21
lines changed

.github/workflows/checks.yaml

+2-3
Original file line numberDiff line numberDiff line change
@@ -180,11 +180,10 @@ jobs:
180180
- name: Check documentation build and links
181181
run: |
182182
. venv/bin/activate
183-
cd doc
184-
pre-commit run --hook-stage push sphinx-generated-doc --all-files || {
183+
tox -e docs || {
185184
echo "git diff:" ; \
186185
git diff ; \
187186
echo "End of 'git diff'" ; \
188-
echo "Make sure that 'make html' succeed without any modifications locally." ; \
187+
echo "Make sure that 'tox -e docs' succeed without any modifications locally." ; \
189188
exit 1; \
190189
}

.pre-commit-config.yaml

-7
Original file line numberDiff line numberDiff line change
@@ -103,13 +103,6 @@ repos:
103103
]
104104
exclude: tests(/\w*)*/functional/|tests/input|tests(/\w*)*data/|doc/
105105
stages: [manual]
106-
- id: sphinx-generated-doc
107-
alias: sphinx-generated-doc
108-
name: sphinx-generated-doc
109-
entry: make -C doc/ html
110-
pass_filenames: false
111-
language: system
112-
stages: [pre-push]
113106
- id: check-newsfragments
114107
name: Check newsfragments
115108
entry: python3 -m script.check_newsfragments

doc/development_guide/contributor_guide/contribute.rst

+4-6
Original file line numberDiff line numberDiff line change
@@ -125,14 +125,12 @@ Tips for Getting Started with Pylint Development
125125
Building the documentation
126126
----------------------------
127127

128-
You can use the makefile in the doc directory with ``make html`` to build the
129-
documentation. To test smaller changes you can consider ``build-html``, which skips some checks but will be faster::
128+
You can use the makefile in the doc directory to build the documentation::
130129

131-
$ cd doc
132-
$ make install-dependencies
133-
$ make html
130+
$ make -C doc/ install-dependencies
131+
$ make -C doc/ html
134132

135-
We're reusing generated files for speed, use ``make clean`` when you want to start from scratch.
133+
We're reusing generated files for speed, use ``make clean`` or ``tox -e docs`` when you want to start from scratch.
136134

137135
How to choose the target version ?
138136
----------------------------------

doc/development_guide/contributor_guide/tests/install.rst

-4
Original file line numberDiff line numberDiff line change
@@ -28,10 +28,6 @@ This ensures your testing environment is similar to Pylint's testing environment
2828
pre-commit hooks which should take care of the autoformatting for you before each
2929
commit. To enable it, run ``pre-commit install`` in the ``pylint`` root directory.
3030

31-
**Even more optionally**: You can enable slow on push hooks with ``pre-commit install --install-hooks -t pre-push``.
32-
It will do slow checks like checking that the generated documentation is up to date
33-
before each push.
34-
3531
Astroid installation
3632
--------------------
3733

doc/user_guide/configuration/all-options.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -1501,7 +1501,7 @@ Standard Checkers
15011501

15021502
--missing-member-hint-distance
15031503
""""""""""""""""""""""""""""""
1504-
*The minimum edit distance a name should have in order to be considered a similar match for a missing member name.*
1504+
*The maximum edit distance a name should have in order to be considered a similar match for a missing member name.*
15051505

15061506
**Default:** ``1``
15071507

0 commit comments

Comments
 (0)