Skip to content

Commit

Permalink
[doc] Add a check for changelogs and fix the issues encountered (#6735)
Browse files Browse the repository at this point in the history
  • Loading branch information
Pierre-Sassoulas committed Jun 1, 2022
1 parent c2b9144 commit 214201a
Show file tree
Hide file tree
Showing 36 changed files with 1,105 additions and 680 deletions.
7 changes: 7 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,13 @@ repos:
args: ["-rn", "-sn", "--rcfile=pylintrc", "--fail-on=I", "--spelling-dict=en"]
exclude: tests/functional/|tests/input|tests(/\w*)*data/|doc/
stages: [manual]
- id: check-changelog
alias: check-changelog
name: check-changelog
types: [text]
entry: python3 script/check_changelog.py
pass_filenames: false
language: system
- id: fix-documentation
name: Fix documentation
entry: python3 -m script.fix_documentation
Expand Down
3 changes: 3 additions & 0 deletions .pyenchant_pylint_custom_dict.txt
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ BaseChecker
basename
behaviour
bidi
Bitbucket
bla
bom
bool
Expand Down Expand Up @@ -172,6 +173,7 @@ linkers
linter
linux
listcomp
Logilab
longstring
lsp
mapfile
Expand Down Expand Up @@ -351,4 +353,5 @@ wc
xfails
xml
xyz
yml
yoda
2 changes: 1 addition & 1 deletion doc/development_guide/contributor_guide/tests/install.rst
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ This ensures your testing environment is similar to Pylint's testing environment

**Optionally** (Because there's an auto-fix if you open a merge request): We have
pre-commit hooks which should take care of the autoformatting for you before each
commits. To enable it, run ``pre-commit install`` in the ``pylint`` root directory.
commit. To enable it, run ``pre-commit install`` in the ``pylint`` root directory.

Astroid installation
--------------------
Expand Down
22 changes: 11 additions & 11 deletions doc/whatsnew/0/0.x.rst
Original file line number Diff line number Diff line change
Expand Up @@ -658,7 +658,7 @@ Release date: 2006-08-10
* started a reference user manual

* new W0212 message for access to protected member from client code
(close #14081)
(Closes #14081)

* new W0105 and W0106 messages extracted from W0104 (statement seems
to have no effect) respectively when the statement is actually string
Expand All @@ -668,7 +668,7 @@ Release date: 2006-08-10
* reclassified W0302 to C0302

* fix so that global messages are not anymore connected to the last
analyzed module (close #10106)
analyzed module (Closes #10106)

* fix some bugs related to local disabling of messages

Expand Down Expand Up @@ -708,7 +708,7 @@ Release date: 2006-03-06

* W0705 has been reclassified to E0701, and is now detecting more
inheriting problem, and a false positive when empty except clause is
following an Exception catch has been fixed (close #10422)
following an Exception catch has been fixed (Closes #10422)

* E0212 and E0214 (metaclass/class method should have mcs/cls as first
argument have been reclassified to C0202 and C0203 since this not as
Expand Down Expand Up @@ -812,13 +812,13 @@ Release date: 2005-11-07
module whose name starts with a deprecated module's name (close
#10061)

* fix "module has no name __dict__" false positive (close #10039)
* fix "module has no name __dict__" false positive (Closes #10039)

* fix "access to undefined variable __path__" false positive (close
#10065)

* fix "explicit return in __init__" false positive when return is
actually in an inner function (close #10075)
actually in an inner function (Closes #10075)


What's New in Pylint 0.8.0?
Expand All @@ -835,7 +835,7 @@ Release date: 2005-10-21

* new --acquired-members option on the classes checker, used when
--zope=yes to avoid false positive on acquired attributes (listed
using this new option) (close #8616)
using this new option) (Closes #8616)

* generate one E0602 for each use of an undefined variable
(previously, only one for the first use but not for the following)
Expand All @@ -855,11 +855,11 @@ Release date: 2005-10-21
* fix astng checkers traversal order

* fix bug in format checker when parsing a file from a platform
using different new line characters (close #9239)
using different new line characters (Closes #9239)

* fix encoding detection regexp

* fix --rcfile handling (support for --rcfile=file, close #9590)
* fix --rcfile handling (support for --rcfile=file, Closes #9590)


What's New in Pylint 0.7.0?
Expand Down Expand Up @@ -896,11 +896,11 @@ Release date: 2005-04-14
* don't fail if we are unable to read an inline option (e.g. inside a
module), just produce an information message (test func_i0010)

* new message E0103 for break or continue outside loop (close #8883,
* new message E0103 for break or continue outside loop (Closes #8883,
test func_continue_not_in_loop)

* fix bug in the variables checker, causing non detection of some
actual name error (close #8884, test
actual name error (Closes #8884, test
func_nameerror_on_string_substitution)

* fix bug in the classes checker which was making pylint crash if
Expand Down Expand Up @@ -980,7 +980,7 @@ Release date: 2005-01-20
* correctly detect access to member defined latter in __init__ method

* now depends on common 0.8.1 to fix problem with interface resolution
(close #8606)
(Closes #8606)

* new --list-msgs option describing available checkers and their
messages
Expand Down
39 changes: 25 additions & 14 deletions doc/whatsnew/1/1.2.rst
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ Release date: 2014-04-30
* Restore the ability to specify the init-hook option via the
configuration file, which was accidentally broken in 1.2.0.

* Add a new warning [bad-continuation] for badly indentend continued
* Add a new warning [bad-continuation] for badly indented continued
lines.

* Emit [assignment-from-none] when the function contains bare returns.
Expand All @@ -25,7 +25,8 @@ Release date: 2014-04-30
* Fix explicit checking of python script (1.2 regression, #219)

* Restore --init-hook, renamed accidentally into --init-hooks in 1.2.0
(#211)

Closes #211

* Add 'indexing-exception' warning, which detects that indexing
an exception occurs in Python 2 (behaviour removed in Python 3).
Expand Down Expand Up @@ -73,7 +74,8 @@ Release date: 2014-04-18
configurable; contributed by morbo@google.com.

* ensure init-hooks is evaluated before other options, notably load-plugins
(#166)

Closes #166

* Python 2.5 support restored: fixed small issues preventing pylint to run
on python 2.5. Bitbucket issues #50 and #62.
Expand All @@ -83,9 +85,9 @@ Release date: 2014-04-18
assignments.

* Add new warning, 'bad-reversed-sequence', for checking that the
reversed() builtin receive a sequence (implements __getitem__ and __len__,
reversed() builtin receive a sequence (implements ``__getitem__`` and ``__len__``,
without being a dict or a dict subclass) or an instance which implements
__reversed__.
``__reversed__``.

* Mark ``file`` as a bad function when using python2 (closes #8).

Expand All @@ -101,26 +103,35 @@ Release date: 2014-04-18

* Add a new warning 'abstract-class-instantiated' for checking
that abstract classes created with ``abc`` module and
with abstract methods are instantied.
with abstract methods are instantiated.

* Do not warn about 'return-arg-in-generator' in Python 3.3+.

* Do not warn about 'abstract-method' when the abstract method
is implemented through assignment (#155).
is implemented through assignment

* Improve cyclic import detection in the case of packages, patch by Buck
Golemon
Closes #155

* Improve cyclic import detection in the case of packages, patch by Buck Golemon

* Add new warnings for checking proper class __slots__:
``invalid-slots-object`` and ``invalid-slots``.

* Search for rc file in `~/.config/pylintrc` if `~/.pylintrc`
doesn't exists (#121)
doesn't exists

Closes #121

* Don't register the new style checker w/ python >= 3

* Fix unused-import false positive w/ augment assignment

Closes #78

* Don't register the newstyle checker w/ python >= 3
* Fix access-member-before-definition false negative wrt aug assign

* Fix unused-import false positive w/ augment assignment (#78)
Closes #164

* Fix access-member-before-definition false negative wrt aug assign (#164)
* Do not attempt to analyze non python file, e.g. .so file

* Do not attempt to analyze non python file, e.g. .so file (#122)
Closes #122
70 changes: 51 additions & 19 deletions doc/whatsnew/1/1.3.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,25 +5,36 @@
Release date: 2014-07-26

* Allow hanging continued indentation for implicitly concatenated
strings. Closes issue #232.
strings.

Closes #232.

* Pylint works under Python 2.5 again, and its test suite passes.

* Fix some false positives for the cellvar-from-loop warnings.
Closes issue #233.

Closes #233.

* Return new astroid class nodes when the inferencer can detect that
that result of a function invocation on a type (like ``type`` or
`abc.ABCMeta`) is requested. Closes #205.
`abc.ABCMeta`) is requested.

Closes #205.

* Emit 'undefined-variable' for undefined names when using the
Python 3 ``metaclass=`` argument.

* Checkers respect priority now. Close issue #229.
* Checkers respect priority now.

Closes #229

* Fix a false positive regarding W0511.

* Fix a false positive regarding W0511. Closes issue #149.
Closes #149.

* Fix unused-import false positive with Python 3 metaclasses (#143).
* Fix unused-import false positive with Python 3 metaclasses

Closes #143

* Don't warn with 'bad-format-character' when encountering
the 'a' format on Python 3.
Expand All @@ -34,15 +45,23 @@ Release date: 2014-07-26
'missing-format-attribute' and 'invalid-format-index'.

* Issue broad-except and bare-except even if the number
of except handlers is different than 1. Fixes issue #113.
of except handlers is different than 1.

Closes #113

* Issue attribute-defined-outside-init for all cases, not just
for the last assignment. Closes issue #262.
for the last assignment.

Closes #262

* Emit 'not-callable' when calling properties. Closes issue #268.
* Emit 'not-callable' when calling properties.

Closes #268.

* Fix a false positive with unbalanced iterable unpacking,
when encountering starred nodes. Closes issue #273.
when encountering starred nodes.

Closes #273.

* Add new checks, 'invalid-slice-index' and 'invalid-sequence-index'
for invalid sequence and slice indices.
Expand All @@ -51,25 +70,35 @@ Release date: 2014-07-26
attributes not defined in slots.

* Don't emit 'no-name-in-module' for ignored modules.
Closes issue #223.

Closes #223.

* Fix an 'unused-variable' false positive, where the variable is
assigned through an import. Closes issue #196.
assigned through an import.

Closes #196.

* Definition order is considered for classes, function arguments
and annotations. Closes issue #257.
and annotations.

Closes #257.

* Don't emit 'unused-variable' when assigning to a nonlocal.
Closes issue #275.

Closes #275.

* Do not let ImportError propagate from the import checker, leading to crash
in some namespace package related cases. Closes issue #203.
in some namespace package related cases.

Closes #203.

* Don't emit 'pointless-string-statement' for attribute docstrings.
Closes issue #193.

Closes #193.

* Use the proper mode for pickle when opening and writing the stats file.
Closes issue #148.

Closes #148.

* Don't emit hidden-method message when the attribute has been
monkey-patched, you're on your own when you do that.
Expand All @@ -78,7 +107,10 @@ Release date: 2014-07-26
module as the offended class, avoiding to mangle the output in some cases.

* Don't emit 'unnecessary-lambda' if the body of the lambda call contains
call chaining. Closes issue #243.
call chaining.

Closes #243.

* Don't emit 'missing-docstring' when the actual docstring uses ``.format``.
Closes issue #281.

Closes #281.

0 comments on commit 214201a

Please sign in to comment.