This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author rhettinger
Recipients Alexander Mentis, docs@python, rhettinger, serhiy.storchaka
Date 2017-11-10.23:31:04
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
This is an artifact of how in-place operators work (which is a topic covered in the Library Reference).  It doesn't really have anything to do with frozensets specifically.  For example, you see the same effect with tuples which like frozensets are immutable and do not implement any of the in-place dunder methods:

    >>> s = ('a', 'b', 'c')
    >>> s += ('d', 'e')
    >>> s
    ('a', 'b', 'c', 'd', 'e')

IIRC, this is the first time this has come-up in the 15 year history of sets, so I don't think there is a real problem to be solved.  At best, this should be a FAQ entry or relegated to StackOverflow.  I would prefer not to alter the set documentation because doing so would likely create confusion rather than solve it.
Date User Action Args
2017-11-10 23:31:04rhettingersetrecipients: + rhettinger, docs@python, serhiy.storchaka, Alexander Mentis
2017-11-10 23:31:04rhettingersetmessageid: <>
2017-11-10 23:31:04rhettingerlinkissue31995 messages
2017-11-10 23:31:04rhettingercreate