use-maxsplit-arg
false positive with custom split method
#4857
Labels
False Positive 🦟
A message is emitted but nothing is wrong with the code
Needs PR
This issue is accepted, sufficiently specified and now needs an implementation
Bug description
I get a false positive when implementing a
split
method on a custom class:Problem seems to be in the
[0]
part. When I change this to[1]
, no warning is shown.Configuration
No response
Command used
Pylint output
C0207: Use obj.split((0, 0), maxsplit=1)[0] instead (use-maxsplit-arg)
Expected behavior
No warning
Pylint version
OS / Environment
No response
Additional dependencies
No response
The text was updated successfully, but these errors were encountered: