pylint
pylint copied to clipboard
Feature request: Check use of deprecated exception classes like IOError
#Is your feature request related to a problem? Please describe
Python reworked exception classes a while ago (starting version 3.3) and several error classes are now just aliases for OSError, see: https://www.python.org/dev/peps/pep-3151/#step-1-coalesce-exception-types
Describe the solution you'd like
pylint could warn about the use of deprecated error classes like IOError and propose that programmers use OSError instead.
I see this is from 2022. Is help still wanted?
Yes!
Probably needs to be added here: https://github.com/pylint-dev/pylint/blob/5feface0d48ba7a6a5eb2b7a2cac99f983afa6b8/pylint/checkers/stdlib.py#L309