What is the difference between a function decorated with @staticmethod and one decorated with @classmethod?
The definitive guide on how to use static, class or abstract methods in Python is one good link for this topic, and summary it as following.
@staticmethod
function is nothing more than a function defined inside a class. It is callable without instantiating the class first. It’s definition is immutable via inheritance.
@classmethod
function also callable without instantiating the class, but its definition follows Sub class, not Parent class, via inheritance, can be overridden by subclass. That’s because the first argument for @classmethod
function must always be cls (class).