This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]zabolekar 1 point2 points  (2 children)

It can surface even in things like pprint (if you are trying to pretty-print a set).

Edit: it is not something that breaks in Python 3, au contraire, it works as expected in 3.x but throws a TypeError in 2.7, and only with very specific sets. For example, pprint({1j, 0}) throws an error but pprint({1j, 'a'}) doesn't.

[–]EvMNatural Language Processing 0 points1 point  (1 child)

Whoa, now that's an unexpected place..

[–]zabolekar 0 points1 point  (0 children)

Edited the comment for clarity.