summaryrefslogtreecommitdiff
path: root/pylint/checkers/stdlib.py
Commit message (Collapse)AuthorAgeFilesLines
* [PyCQA migration] Upgrade links to the repositories in code and doc (#8514)Pierre Sassoulas2023-03-291-2/+2
|
* [ruff] Add RUF specific rules and autofix (#8449)Pierre Sassoulas2023-03-141-1/+1
|
* Use UninferableBase instead of UninferableDaniel van Noord2023-03-071-4/+4
|
* "Message emitted" improvements caused issuesStavros Ntentos2023-02-221-1/+1
| | | | | | | | | | Wrapping "Message emitted" in monospaced formatting, causes `W1507` (`pylint/checkers/stdlib.py`) to fail on a stray space. Fix that - as it seems to be the only outlier. (Might've been nice for a more formal check in the first place šŸ™). Signed-off-by: Stavros Ntentos <133706+stdedos@users.noreply.github.com>
* Tighten design constraints (#8115)Nick Drozd2023-01-281-0/+1
| | | | | | | | | | | | | * Lower max locals * Lower max statements * Lower max try statements * Lower max branches * Lower max args * Cut design constraints with default values
* [subprocess-run-check] Add the proper confidencePierre Sassoulas2023-01-231-1/+2
|
* [subprocess-run-check] Better rationale and messagePierre Sassoulas2023-01-231-4/+5
|
* Fixes ``method-cache-max-size-none`` false positive (#7908)Dani Alcala2022-12-091-3/+7
| | | | | | | For methods inheriting from ``Enum``. Closes #7857 Co-authored-by: Pierre Sassoulas <pierre.sassoulas@gmail.com>
* Improve bad-threading-instantiation check (#7617)Dani Alcala2022-11-151-3/+9
|
* @singledispatch and @singledispatchmethod checks for methods and functions ↵Ramon Saraiva2022-10-311-1/+50
| | | | | | (#7575) Co-authored-by: Pierre Sassoulas <pierre.sassoulas@gmail.com>
* Add additional stdlib deprecations (#7664)Jacob Walls2022-10-231-1/+9
|
* Add typing to ``stdlib`` checker (#7192)Daniƫl van Noord2022-07-151-27/+41
|
* Add whitespace/punctuation to some message descriptions (#7009)Julthep Nandakwang2022-06-231-5/+5
|
* Add support of sharing message in multiple checkers. Fix DeprecatedChecker ↵Matus Valo2022-06-161-2/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | example (#6693) * Move message definitions from DeprecatedMixin * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Added typing and fixed unittests * Make DEPRECATED_MSGS and DEPRECATED_IMPORT_MSG class variables to make pylint happy * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Introduce shared messages * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Change Message codes in DeprecatedMixin to W49XX * Make mypy happy * Make pylint happy * Add support for building documentation for shared messages * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Make isort happy * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Circuvent isort * Move shared to extra message options and fix tests * Update deprecation_checker example * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Update doc/exts/pylint_messages.py Co-authored-by: Daniƫl van Noord <13665637+DanielNoord@users.noreply.github.com> * Update doc/exts/pylint_messages.py Co-authored-by: Daniƫl van Noord <13665637+DanielNoord@users.noreply.github.com> * Make messages static class attributes * Keep MessageDefinition backward compatible * Apply suggestions from code review Co-authored-by: Daniƫl van Noord <13665637+DanielNoord@users.noreply.github.com> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: Daniƫl van Noord <13665637+DanielNoord@users.noreply.github.com>
* Remove duplicate message definitionsDaniƫl van Noord2022-05-051-22/+1
|
* Create a generic ``_check_open_call`` functionDaniƫl van Noord2022-05-041-32/+23
|
* Add python 3.11 deprecations from stdlib (#6453)Jacob Walls2022-04-251-0/+18
|
* [typing] Add typing to existing function in stdlib checkerPierre Sassoulas2022-04-221-1/+1
|
* Migrate from 'check_messages' to 'only_required_for_messages' (#6417)Pierre Sassoulas2022-04-211-6/+6
|
* Fix crash when open is called with an integer mode (#6415)Pierre Sassoulas2022-04-211-1/+1
| | | Closes #6414
* Remove ``IAstroidChecker`` from ``__implements__``Daniƫl van Noord2022-04-191-2/+0
|
* Rename ``cache-max-size-none`` and check ``functools.cache`` (#6182)Daniƫl van Noord2022-04-191-14/+23
| | | Co-authored-by: Pierre Sassoulas <pierre.sassoulas@gmail.com>
* Fix enabling `deprecated-module` after `disable=all` (#6360)Jacob Walls2022-04-181-19/+3
| | | Follow-up to fabc645.
* Use ``python-typing-update`` on ``pylint/checkers`` directoryDaniƫl van Noord2022-04-141-12/+12
|
* Update broken and redirected links across the projectDaniƫl van Noord2022-04-131-1/+1
|
* Make ``linter`` non-optional for ``BaseChecker`` (#6188)Daniƫl van Noord2022-04-111-1/+1
|
* Only emit ``lru-cache-decorating-method`` when ``maxsize`` is ``None`` (#6181)Daniƫl van Noord2022-04-051-13/+15
| | | | Co-authored-by: Jacob Walls <jacobtylerwalls@gmail.com> Co-authored-by: Pierre Sassoulas <pierre.sassoulas@gmail.com>
* Add bad-open-mode and unspecified-encoding documentation (#5954)Daniƫl van Noord2022-03-241-1/+1
| | | | Co-authored-by: Vladyslav Krylasov <vladyslav.krylasov@gmail.com>
* Add a pre-commit hook to check the copyright noticePierre Sassoulas2022-03-241-1/+1
| | | | | Fix the existing file so they have a notice. No header for setup.py or examples or doc
* Simplify hard to maintain copyright noticePierre Sassoulas2022-03-241-34/+1
| | | | | | git is the source of truth for the copyright, copyrite (the tool) was taking exponentially longer with each release, and it's polluting the code with sometime as much as 50 lines of names.
* Upgrade ``pydocstringformatter`` to ``0.5.0`` (#5910)Daniƫl van Noord2022-03-131-3/+1
|
* Prevent `useless-suppression` on disables for stdlib deprecation checker (#5876)Jacob Walls2022-03-111-9/+11
| | | | Co-authored-by: Marc Mueller <30130371+cdce8p@users.noreply.github.com>
* Add `distutils` to deprecated modules (#5864)Jacob Walls2022-03-081-0/+7
|
* Add stdlib xml.etree.cElementTree to deprecated modules (#5863)Jacob Walls2022-03-061-0/+1
|
* Make ``lru-cache-decorating-method`` look for ``maxsize`` argument (#5791)Daniƫl van Noord2022-02-141-6/+18
| | | Co-authored-by: Pierre Sassoulas <pierre.sassoulas@gmail.com>
* Improved `bad-open-mode` message when providing ``None`` to the ``mode`` ↵Jacob Walls2022-01-291-1/+5
| | | | argument of an `open()` call (#5742)
* Create separate documentation page for each message (#5396)Daniƫl van Noord2022-01-281-4/+4
| | | Co-authored-by: Pierre Sassoulas <pierre.sassoulas@gmail.com>
* Fix crash when providing None to mode arg of open() (#5732)Jacob Walls2022-01-271-1/+1
|
* Fix false positive ``super-init-not-called`` for inherited ``init`` (#5698)Daniƫl van Noord2022-01-241-3/+1
| | | And remove useless suppressed messages
* Add ``lru-cache-decorating-method`` checker (#5674)Daniƫl van Noord2022-01-141-1/+42
| | | Co-authored-by: Pierre Sassoulas <pierre.sassoulas@gmail.com>
* Fix #5638: Allow for encoding to be supplied as a positional argument (#5641)Jacob Walls2022-01-061-5/+14
|
* Add typing and uniformize the checker registering in Pylinter (#5558)Pierre Sassoulas2021-12-271-5/+6
| | | | | Remove verbose docstring in code, keep them in example and doc Co-authored-by: Marc Mueller <30130371+cdce8p@users.noreply.github.com>
* Activate and fix existing use-set-for-membership checks (#5379)Pierre Sassoulas2021-11-251-1/+1
| | | | * Activate and fix existing use-set-for-membership checks
* Fix crash on ``open()`` calls for non-string ``mode`` arguments (#5332)Daniƫl van Noord2021-11-201-1/+6
| | | Co-authored-by: Marc Mueller <30130371+cdce8p@users.noreply.github.com>
* Add ``no-implicit-optional`` flag to ``mypy`` (#5075)Daniƫl van Noord2021-09-261-2/+2
|
* Fix ``unspecified-encoding`` for ``Path.read_text()``Daniƫl van Noord2021-09-171-3/+8
| | | | Closes #5029
* Fix ``unspecified-encoding`` for `Path()`Daniƫl van Noord2021-09-161-3/+10
| | | | This closes #5017
* Bump pylint to 2.11.0, update changelogv2.11.0Pierre Sassoulas2021-09-161-1/+1
|
* Refactor various typing related issues (#4940)Daniƫl van Noord2021-09-031-7/+11
| | | | | | | | | | | | | | | * Add type annotations to ``visit`` & ``leave`` calls This adds typing to most calls that visit nodes. All other changes are due to mypy errors resulting from introduction of typing. * Fix outstanding mypy issues This removes some of the `type: ignore` comments in favour of solving the mypy issues these comments were surpressing. * Fix remaining references to node_classes Except for two references to node_classes in the changelog this should be the last of them Co-authored-by: Marc Mueller <30130371+cdce8p@users.noreply.github.com> Co-authored-by: Pierre Sassoulas <pierre.sassoulas@gmail.com>
* Extend ``unspecified-encoding`` checkerDaniƫl van Noord2021-09-011-3/+3
| | | | | | The ``unspecified-encoding`` checker now also checks calls to ``pathlib.Path().read_text()`` and ``pathlib.Path().write_text()`` This closes #4945