Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Regression fix for `unused-variable` false negative (#8684) | Zen Lee | 2023-05-15 | 2 | -0/+18 |
| | |||||
* | [use-implicit-booleaness] Reinstate tests that are expected to fail | Pierre Sassoulas | 2023-05-03 | 1 | -10/+10 |
| | |||||
* | Add applicability notes for `compare-to-empty-string/zero` (#8592) | Jason Lau | 2023-05-03 | 3 | -44/+44 |
| | | | | | | The extension `compare-to-empty-string` is only applicable when the expression being compared is strictly a `str`. The extension `compare-to-zero` is only applicable when the expression being compared is strictly an `int`. | ||||
* | Switch from ' to " in use-implicit-booleaness-not-comparison | Pierre Sassoulas | 2023-05-03 | 1 | -32/+32 |
| | | | | | Because empty string needs to " because node.as_string() use simple quote. | ||||
* | Merge the empty-string extensions to 'implicit_booleaness_checker' | Pierre Sassoulas | 2023-05-02 | 3 | -0/+30 |
| | |||||
* | Merge the compare-to-zero extensions to 'implicit_booleaness_checker' | Pierre Sassoulas | 2023-05-02 | 3 | -0/+54 |
| | |||||
* | Fix false negative for calling module-level function before definition (#8494) | Jacob Walls | 2023-04-29 | 3 | -10/+23 |
| | |||||
* | Drop support for Python 3.7 (#8609) | Marc Mueller | 2023-04-24 | 2 | -10/+5 |
| | | | | | * Drop support for Python 3.7 * Update py-version + classifier * Update functional tests | ||||
* | Fix FP `used-before-assignment` for statements guarded under same test (#8581) | Jacob Walls | 2023-04-16 | 2 | -1/+50 |
| | |||||
* | Fix `used-before-assignment` TYPE_CHECKING false negatives (#8431) | Zen Lee | 2023-04-15 | 2 | -0/+20 |
| | | | | Co-authored-by: Pierre Sassoulas <pierre.sassoulas@gmail.com> Co-authored-by: Jacob Walls <jacobtylerwalls@gmail.com> | ||||
* | Fix check unused arguments false positive bug (#8542) | Théo Battrel | 2023-04-06 | 2 | -0/+23 |
| | | | | | | | | | | | | | | | | | | | Problem: the special method `__new__` must match the arguments of the `__init__` method even if `__new__` method does not use them. This generate `unused-argument` for the `__new__` method. Fix: the unused arguments check should not be done on the `__new__` method if the `__init__` method is defined in the same class. Update `unused-argument` test to include a check for the case of `__init__` and `__new__` being defined in a class but `__new__` does not use all of the argument. This is fine because `__new__` must have the same argument of `__init__`. Update with a second check in case of `__init__` being not defined in a class. Then the unused arguments check must be done on `__new__`. Fixes https://github.com/pylint-dev/pylint/issues/3670 | ||||
* | Add regression test for #7506 (#8432) | Jacob Walls | 2023-04-03 | 2 | -8/+11 |
| | |||||
* | [cleanup] Upgrade more doc following the PyCQA migration | Pierre Sassoulas | 2023-03-31 | 1 | -1/+1 |
| | |||||
* | Fix `used-before-assignment` false positive for `TYPE_CHECKING` elif branch ↵ | Zen Lee | 2023-03-30 | 5 | -7/+22 |
| | | | | | | imports (#8441) Co-authored-by: Pierre Sassoulas <pierre.sassoulas@gmail.com> | ||||
* | [PyCQA migration] Upgrade links to the repositories in code and doc (#8514) | Pierre Sassoulas | 2023-03-29 | 45 | -95/+95 |
| | |||||
* | Fix `unnecessary-lambda` false positive for lambdas using its parameters in ↵ | cherryblossom | 2023-03-28 | 2 | -0/+13 |
| | | | | | | | their body (#8498) Fixes #8496 | ||||
* | [cleanup] Move tests starting with 'unbalanced' in a subdir | Pierre Sassoulas | 2023-03-23 | 5 | -0/+0 |
| | |||||
* | Add regression test for #5288 (#8385) | Jacob Walls | 2023-03-07 | 2 | -0/+13 |
| | |||||
* | Fix FP for used-before-assignment with assignment expressions in containers ↵ | Jacob Walls | 2023-02-11 | 2 | -6/+9 |
| | | | | (#8253) | ||||
* | Fix `used-before-assignment` false positive for walrus operator in ↵ | Zen Lee | 2023-02-10 | 1 | -0/+13 |
| | | | | dictionary (#8176) | ||||
* | Fix `used-before-assignment` false positive for TYPE_CHECKING if/elif/else ↵ | Zen Lee | 2023-02-07 | 4 | -17/+121 |
| | | | | usage (#8071) | ||||
* | Update docs for `global-variable-not-assigned` (#8151) | Dani Alcala | 2023-02-01 | 1 | -1/+1 |
| | | | Co-authored-by: Pierre Sassoulas <pierre.sassoulas@gmail.com> | ||||
* | Fix false positive for `use-maxsplit-arg` with custom split (#8114) | yushao2 | 2023-01-30 | 1 | -0/+8 |
| | | | | | | Closes #4857 Co-authored-by: Daniël van Noord <13665637+DanielNoord@users.noreply.github.com> Co-authored-by: Pierre Sassoulas <pierre.sassoulas@gmail.com> | ||||
* | Update disallowed-name to flag module-level variables (#7808) | Dani Alcala | 2023-01-25 | 3 | -9/+9 |
| | | | Co-authored-by: Pierre Sassoulas <pierre.sassoulas@gmail.com> | ||||
* | Fix FP for `used-before-assignment` when reimporting name used in type ↵ | Jacob Walls | 2023-01-23 | 2 | -1/+4 |
| | | | | | | annotation (#8095) Co-authored-by: Mark Byrne <31762852+mbyrnepr2@users.noreply.github.com> | ||||
* | Fix `used-before-assignment` false positive for walrus operators in ifs (#8029) | Zen Lee | 2023-01-08 | 3 | -0/+46 |
| | | | Co-authored-by: Pierre Sassoulas <pierre.sassoulas@gmail.com> | ||||
* | Fix `use-sequence-for-iteration` when unpacking a set with `*` (#7975) | Dani Alcala | 2022-12-26 | 2 | -5/+16 |
| | |||||
* | Fix `used-before-assignment` if conditional imports guarded again when used ↵ | Jacob Walls | 2022-12-25 | 2 | -5/+12 |
| | | | | (#7980) | ||||
* | [pypy3.8] Disable multiple-statements false positive on affected functional ↵ | Pierre Sassoulas | 2022-12-15 | 1 | -1/+8 |
| | | | | tests | ||||
* | Fix unreleased false positives with `used-before-assignment` (#7921) | Jacob Walls | 2022-12-12 | 2 | -0/+14 |
| | | | | | Cases with NamedExpr and Starred relating to definitions under "always false" conditions added in https://github.com/PyCQA/pylint/pull/6677 | ||||
* | Prevent `used-before-assignment` in pattern matching with a guard (#7922) | Jacob Walls | 2022-12-12 | 2 | -0/+9 |
| | |||||
* | Emit `used-before-assignment` for further imports guarded by TYPE_CHECKING ↵ | Jacob Walls | 2022-12-10 | 2 | -4/+16 |
| | | | | | | | | (#7806) Previously, this message was only emitted for imports guarded directly under TYPE_CHECKING, not guarded two if-branches deep, nor when TYPE_CHECKING was imported from typing under an alias. | ||||
* | Clearer ``reimported`` and new ``shadowed-import`` messages for aliased ↵ | Dani Alcala | 2022-11-30 | 2 | -2/+2 |
| | | | | | | | import (#7756) Co-authored-by: Pierre Sassoulas <pierre.sassoulas@gmail.com> | ||||
* | Prevent `used-before-assignment` for variables defined in assignment ↵ | Jacob Walls | 2022-11-25 | 2 | -4/+5 |
| | | | | expressions (#7847) | ||||
* | Fix crash when using ``enumerate`` with ``start`` and a class attribute (#7824) | Dani Alcala | 2022-11-24 | 1 | -0/+11 |
| | | | Co-authored-by: Pierre Sassoulas <pierre.sassoulas@gmail.com> | ||||
* | Fix `used-before-assignment` for variable annotations guarded by ↵ | Jacob Walls | 2022-11-23 | 2 | -4/+21 |
| | | | | TYPE_CHECKING (#7810) | ||||
* | Emit `used-before-assignment` for variables only defined under always false ↵ | Jacob Walls | 2022-11-22 | 6 | -3/+94 |
| | | | | tests (#6677) | ||||
* | New checker `unbalanced dict unpacking` (#7750) | Dani Alcala | 2022-11-20 | 4 | -10/+118 |
| | | | | Co-authored-by: Pierre Sassoulas <pierre.sassoulas@gmail.com> | ||||
* | Better error message for unpacking-non-sequence and ↵ | Pierre Sassoulas | 2022-11-19 | 2 | -11/+11 |
| | | | | | | | | unbalanced-tuple-unpacking (#7778) Necessary to be able to do https://github.com/PyCQA/pylint/pull/7750 without thinking about it. Co-authored-by: Mark Byrne <31762852+mbyrnepr2@users.noreply.github.com> | ||||
* | Fix `valid-metaclass-classmethod-first-arg` default value (#7791) | Cubicpath | 2022-11-19 | 1 | -2/+2 |
| | | | | | * Change default value to "mcs" * Fix functional tests to use "mcs" for first MetaClass classmethod arg | ||||
* | Fix false positive for 'used-before-assignment' with terminating func (#7784) | Dani Alcala | 2022-11-17 | 2 | -5/+18 |
| | |||||
* | Fixes ``unnecessary-list-index-lookup`` false negative when ``enumerate`` is ↵ | Dani Alcala | 2022-11-17 | 2 | -0/+10 |
| | | | | called with ``iterable`` as a kwarg. (#7789) | ||||
* | Fix false positive for ``unhashable-member`` when subclassing ``dict``. (#7757) | Mark Byrne | 2022-11-14 | 1 | -0/+6 |
| | | | | | Closes #7501 Co-authored-by: Pierre Sassoulas <pierre.sassoulas@gmail.com> | ||||
* | Detect unreachable code after sys.exit, quit, exit, and os._exit (#7520) | Dani Alcala | 2022-11-13 | 2 | -6/+58 |
| | | | | | Co-authored-by: Pierre Sassoulas <pierre.sassoulas@gmail.com> Co-authored-by: Mark Byrne <31762852+mbyrnepr2@users.noreply.github.com> | ||||
* | false positive `unnecessary-list-index-lookup` for enumerate (#7685) | Dani Alcala | 2022-11-13 | 2 | -0/+53 |
| | | | | | | | * do not report unnecessary list index lookup if start arg is passed * account for calling start with 0 or negative num Co-authored-by: Pierre Sassoulas <pierre.sassoulas@gmail.com> | ||||
* | Fix a false negative for ``unused-import`` (#7678) | Mark Byrne | 2022-11-09 | 3 | -0/+13 |
| | | | | | | | | | | | * Fix a false negative for ``unused-import`` when a constant inside ``typing.Annotated`` was treated as a reference to an import. * Update with Daniël's suggestions: - More understandable function parameter name. - Update function parameter type: Expect a tuple of strings. Closes #7547 | ||||
* | [use-implicit-booleaness-not-comparison] Better message with the type of ↵ | Pierre Sassoulas | 2022-11-09 | 1 | -32/+32 |
| | | | | sequence | ||||
* | Add R1737 use-dict-literal-without-kwargs | Robert Hofer | 2022-11-09 | 8 | -22/+68 |
| | |||||
* | [implicit_booleaness_checker] Add the confidence to related messages (#7721) | Pierre Sassoulas | 2022-11-06 | 2 | -55/+55 |
| | | | First step prior doing #6870 in order to make it more reviewable. | ||||
* | Rename `broad-except` and new check `broad-exception-raised` (#7709) | Dani Alcala | 2022-11-05 | 5 | -4/+5 |
| | | | | Co-authored-by: Pierre Sassoulas <pierre.sassoulas@gmail.com> |