Skip to content

Fix false positive for undefined-loop-variable with enumerate()#6602

Merged
Pierre-Sassoulas merged 2 commits into
pylint-dev:mainfrom
jacobtylerwalls:loop-variable-enumerate
May 13, 2022
Merged

Fix false positive for undefined-loop-variable with enumerate()#6602
Pierre-Sassoulas merged 2 commits into
pylint-dev:mainfrom
jacobtylerwalls:loop-variable-enumerate

Conversation

@jacobtylerwalls
Copy link
Copy Markdown
Member

Type of Changes

Type
🐛 Bug fix

Description

Closes #6593

@jacobtylerwalls jacobtylerwalls added Bug 🪲 Needs backport Needs to be cherry-picked on the current patch version by a pylint's maintainer False Positive 🦟 A message is emitted but nothing is wrong with the code labels May 13, 2022
@jacobtylerwalls jacobtylerwalls added this to the 2.13.9 milestone May 13, 2022
@coveralls
Copy link
Copy Markdown

coveralls commented May 13, 2022

Pull Request Test Coverage Report for Build 2319787404

  • 2 of 2 (100.0%) changed or added relevant lines in 1 file are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage increased (+0.0006%) to 95.346%

Totals Coverage Status
Change from base Build 2318658517: 0.0006%
Covered Lines: 16043
Relevant Lines: 16826

💛 - Coveralls

Comment thread pylint/checkers/variables.py Outdated
Comment thread pylint/checkers/variables.py Outdated
Co-authored-by: Pierre Sassoulas <pierre.sassoulas@gmail.com>
@Pierre-Sassoulas
Copy link
Copy Markdown
Member

Good job "sneaking" two crash fixes in the last python 3.6 release 😉 At some point I'm pretty sure that some poor dev working on EOL python with unruly legacy enumerate, will thank you for that.

@Pierre-Sassoulas Pierre-Sassoulas merged commit 912a171 into pylint-dev:main May 13, 2022
Pierre-Sassoulas added a commit that referenced this pull request May 13, 2022
…6602)


Co-authored-by: Pierre Sassoulas <pierre.sassoulas@gmail.com>
@Pierre-Sassoulas Pierre-Sassoulas added Backported and removed Needs backport Needs to be cherry-picked on the current patch version by a pylint's maintainer labels May 13, 2022
@jacobtylerwalls jacobtylerwalls deleted the loop-variable-enumerate branch May 13, 2022 14:53
Pierre-Sassoulas added a commit that referenced this pull request May 13, 2022
…6602)


Co-authored-by: Pierre Sassoulas <pierre.sassoulas@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Backported Bug 🪲 False Positive 🦟 A message is emitted but nothing is wrong with the code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

False positive for undefined-loop-variable with enumerate()

3 participants