nova team mailing list archive
-
nova team
-
Mailing list archive
-
Message #00152
pylint and methods that could be functions
All,
What's the preference on methods that could be functions? pylint is currently complaining on any class method that doesn't access 'self', meaning that the method doesn't necessarily need to be a part of a class. I'm going back and forth on it. I tend to think it makes sense to keep some things as a part of a class for organizational purposes... but I don't know.
Some examples are in nova/compute/model.py's InstanceDirectory. Most of the methods don't need to be a part of the class, but I can see where it's nice to organize it all that way... If we want to keep it, I think we may want to make pylint ignore this code?
Thoughts?
- Chris
Follow ups