-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. Weβll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove safe_decode()
and deprecated_option()
from utils
#5046
Remove safe_decode()
and deprecated_option()
from utils
#5046
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Too bad coverall is down, this would have been Γ pleasant report :D thanks for the cleanup !
Just a followup, for the future should we deprecate methods first before we remove them? |
Yeah theoretically, I just don't think of |
I was thinking the same as Pierre, but you are indeed right Marc. Sorry about this! |
What about
Regarding the two methods, I do agree that a deprecation probably wasn't necessary. -- |
On the top of my head the public API is:
I would need to check the major plugin that depends on pylint:
Now that I think of it, the "is it a public API" approach is the wrong one, we should probably ask ourselves what is not instead. And I would say "the small helper functions". The safest way would be to consider everything public API, but then we could never refactor anything without releasing a major and that would make our live really hard, right ? |
Just to round off this discussion, I think it will be hard to come up with a one solution/rule that fits all cases. We should probably be a little bit more considerate about what not to remove outright, but should not fully constrain ourselves. In the latest refactoring PRs I think we striked the right balance! |
Type of Changes
Description
While working on the typing of
pylint/utils/utils.py
I noticed these two functions never get called. Therefore they seem like candidates for removal from the codebase.