New submission from Carl Friedrich Bolz <[EMAIL PROTECTED]>: When trying to remove a set from a set, the KeyError that is raised is confusing:
Python 2.6 (r26:66714, Oct 7 2008, 13:23:57) [GCC 4.2.3 (Ubuntu 4.2.3-2ubuntu7)] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> s = set([frozenset([1, 2]), frozenset([2, 3])]) >>> s.remove(set([3, 4])) Traceback (most recent call last): File "<stdin>", line 1, in <module> KeyError: frozenset([]) I understand that s.remove(set(...)) turns the set into a frozenset, but I was expecting this converted frozenset to be attached to the KeyError, not an empty set. ---------- components: Interpreter Core messages: 74461 nosy: cfbolz severity: normal status: open title: set.remove raises confusing KeyError type: behavior versions: Python 2.5, Python 2.6 _______________________________________ Python tracker <[EMAIL PROTECTED]> <http://bugs.python.org/issue4069> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com