Bugs item #1114776, was opened at 2005-02-02 09:43 Message generated for change (Comment added) made by kbk You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1114776&group_id=5470
Category: Python Library Group: Python 2.3 Status: Open Resolution: Fixed Priority: 9 Submitted By: Vincenzo Di Somma (disommav) Assigned to: Anthony Baxter (anthonybaxter) Summary: copy.py bug Initial Comment: upgrading from python 2.3.4 to 2.3.5rc1 I got this error on a module that was working correctly File "../Field.py", line 203, in copy properties = deepcopy(cdict) File "/usr/lib/python2.3/copy.py", line 191, in deepcopy y = copier(x, memo) File "/usr/lib/python2.3/copy.py", line 285, in _deepcopy_dict y[deepcopy(key, memo)] = deepcopy(value, memo) File "/usr/lib/python2.3/copy.py", line 200, in deepcopy copier = _getspecial(cls, "__deepcopy__") File "/usr/lib/python2.3/copy.py", line 66, in _getspecial for basecls in cls.__mro__: AttributeError: __mro__ ---------------------------------------------------------------------- >Comment By: Kurt B. Kaiser (kbk) Date: 2005-04-14 16:00 Message: Logged In: YES user_id=149084 Should this be closed? ---------------------------------------------------------------------- Comment By: Alex Martelli (aleax) Date: 2005-02-06 02:57 Message: Logged In: YES user_id=60314 Fixed (using inspect.getmro instead of direct __mro__ access) -- added unittest for that thanks to John Lenton's suggestion on c.l.py ---------------------------------------------------------------------- Comment By: Alex Martelli (aleax) Date: 2005-02-05 04:07 Message: Logged In: YES user_id=60314 The problem's easy to fix (using inspect.getmro instead of direct __mro__ access) but hard to reproduce -- what type not recorded in the dispatch table lacks an __mro__? Can't find one easily, and I'd like to have a unit-test reproducing the bug before I commit the fix. Vincenzo, can you explain what the type is happening to be in that value whose deepcopy gives problems? or can anybody else suggest a type as above? ---------------------------------------------------------------------- Comment By: Anthony Baxter (anthonybaxter) Date: 2005-02-02 22:26 Message: Logged In: YES user_id=29957 http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=293338 has a fuller stack trace. ---------------------------------------------------------------------- Comment By: Michael Hudson (mwh) Date: 2005-02-02 14:35 Message: Logged In: YES user_id=6656 Eek, that sounds pretty bad! Can you attach the code/cook up a smaller test case? ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1114776&group_id=5470 _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com