pylint #99672 Warn on self.method(self,...) [open]
I think it's a fairly common mistake for Python developers to accidentally type "self.method(self,....)" and a warning should be generated for this code, for any method name.
I think the warning should be something along the lines of "passing self as first argument to method".
Similarly, I think it could be a style warning for method invocations that look like this:
self.method(self.a_member, self.another_member)
which I've seen on several occasions as well, usually intermixed with non-self arguments. | |
priority | normal |
---|---|
type | enhancement |
done in | <not specified> |
closed by | <not specified> |