False positive used-before-assignment
when else
of try/else
calls sys.exit()
#7563
Labels
C: used-before-assignment
Issues related to 'used-before-assignment' check
Control flow
Requires control flow understanding
False Positive 🦟
A message is emitted but nothing is wrong with the code
Good first issue
Friendly and approachable by new contributors
Needs PR
This issue is accepted, sufficiently specified and now needs an implementation
Milestone
Bug description
Given this code snippet:
Since
sys.exit()
in the else branch is aborting, there is no doubt thatlint_result
must be assigned.Configuration
Command used
Pylint output
Expected behavior
Warning should not be given.
Pylint version
OS / Environment
Debian Buster with PyPI packages
Additional dependencies
No response
The text was updated successfully, but these errors were encountered: