Given a Python class which will be instantiated only once, i.e. there will be only one object of the class. I was wondering in which cases it makes sense to create a single class instance instead of working directly with the class instead.
There is a similar question, but it has a different focus:
- it is about grouping global variables and functions into a class and
- It isn't Python-specific. The latter means it does not consider the fact that (in Python) classes are objects too.