How to handle the pylint message: Warning: Method could be a function

Posted by biffabacon on Stack Overflow See other posts from Stack Overflow or by biffabacon
Published on 2010-04-20T09:46:19Z Indexed on 2010/04/20 9:53 UTC
Read the original article Hit count: 385

Filed under:
|
|

Being new to Python, I decided to get some feedback on a class I'd written ASAP so I ran it against pylint. Is the message it gave "Warning: Method could be a function" telling me that it would be better to move this method out of the class because it doesn't use any instance variables? In c# I would make this a static method. What's the most pythonic thing to do here?

© Stack Overflow or respective owner

Related posts about python

Related posts about pylint