class Foo: instance = None def __new__(cls, *args, **kwargs): if not Foo.instance: Foo.instance = object.__new__(cls,*args,**kwargs) return Foo.instance else: return Foo.instance