You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In the demo above, a line like this should pass pylint, but instead I get a Bad option value '-no-jfly' (bad-option-value) message. Note that the option value is actually j3-no-jfly, not-no-jfly:
pylint: disable=j3-no-jfly
Expected behavior
I suppose it's possible that Pylint intentionally does not want to support checkers with numbers in their names. That used to be supported, though, so I'd prefer that Pylint support this (as it did in 2.4 and before).
If it is intentional to not support numbers in checker names, then I think it would be nice for this to be explicitly called out in a release note, and I also think the error could be clearer about what's going on.
Some digging into how this broke between pylint 2.4.4 and 2.5
As demonstrated here, this worked on Pylint 2.4.4, and started breaking with Pylint 2.5.0. I did some code spelunking, and it looks like this commit 9bdae8b broke support for checkers with numbers in the name. Specifically, it defines MESSAGE_STRING's regex in a way such that numbers are not allowed. One fix may be to just tweak that regex so it allows numbers.
The text was updated successfully, but these errors were encountered:
jfly
added a commit
to jfly/pylint
that referenced
this issue
Jun 5, 2020
Steps to reproduce
Using a version of Pylint 2.5, it's impossible to ignore warnings about checkers whose names contain numbers.
Reproducing this requires writing custom checker, which is a bit complicated to describe in a single issue. I've put together a simple reproduction here: https://github.com/jfly/pylint-demo#pylint-checker-naming-issue
Current behavior
In the demo above, a line like this should pass pylint, but instead I get a
Bad option value '-no-jfly' (bad-option-value)
message. Note that the option value is actuallyj3-no-jfly
, not-no-jfly
:Expected behavior
I suppose it's possible that Pylint intentionally does not want to support checkers with numbers in their names. That used to be supported, though, so I'd prefer that Pylint support this (as it did in 2.4 and before).
If it is intentional to not support numbers in checker names, then I think it would be nice for this to be explicitly called out in a release note, and I also think the error could be clearer about what's going on.
pylint --version output
(see readme for more information)
Some digging into how this broke between pylint 2.4.4 and 2.5
As demonstrated here, this worked on Pylint 2.4.4, and started breaking with Pylint 2.5.0. I did some code spelunking, and it looks like this commit 9bdae8b broke support for checkers with numbers in the name. Specifically, it defines
MESSAGE_STRING
's regex in a way such that numbers are not allowed. One fix may be to just tweak that regex so it allows numbers.The text was updated successfully, but these errors were encountered: