Singleton-like pattern

Michele Simionato mis6 at pitt.edu
Sun Aug 3 10:16:44 EDT 2003


Steven Taschuk <staschuk at telusplanet.net> wrote in message news:<mailman.1059863764.14138.python-list at python.org>...
> Quoth Michele Simionato:
>   [...]
> > Actually you are right, I remember now that I got problems with 
> > (args,kw) and at the end I used args,tuple(kw.items()). But I was
> > ensure if this was a good solution.
> 
> I'd worry about the order of kw.items().

Yes, indeed. Also, the args tuple can contain nested dictionaries and 
become unhashable; in such a case I should recursively flatten all 
the dictionaries to tuples, taking in account the ordering.
To much work for me ...I have really to look at the cPickle solution.
How does it solve the ordering issue? 

Michele




More information about the Python-list mailing list