You copied an instance, not a class. Here's an example of attempting to deepcopy a class: >>> class X: pass ... >>> import copy >>> X is copy.deepcopy(X) Traceback (most recent call last): File "<stdin>", line 1, in ? File "/usr/lib/python2.2/copy.py", line 179, in deepcopy raise error, \ copy.Error: un-deep-copyable object of type <type 'class'>
In theory, one could provide a metaclass that allows copying of instances of that metaclass. I'll leave this as an exercise to the reader. Jeff
pgpjJrXN93ruF.pgp
Description: PGP signature
-- http://mail.python.org/mailman/listinfo/python-list