Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

set() comparisons do not play well with others #47183

Closed
ncoghlan opened this issue May 21, 2008 · 2 comments
Closed

set() comparisons do not play well with others #47183

ncoghlan opened this issue May 21, 2008 · 2 comments

Comments

@ncoghlan
Copy link
Contributor

BPO 2934
Nosy @ncoghlan

Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

Show more details

GitHub fields:

assignee = None
closed_at = <Date 2008-05-21.13:23:44.133>
created_at = <Date 2008-05-21.13:19:21.108>
labels = ['invalid']
title = 'set() comparisons do not play well with others'
updated_at = <Date 2008-05-21.13:23:43.992>
user = 'https://github.com/ncoghlan'

bugs.python.org fields:

activity = <Date 2008-05-21.13:23:43.992>
actor = 'ncoghlan'
assignee = 'none'
closed = True
closed_date = <Date 2008-05-21.13:23:44.133>
closer = 'ncoghlan'
components = []
creation = <Date 2008-05-21.13:19:21.108>
creator = 'ncoghlan'
dependencies = []
files = []
hgrepos = []
issue_num = 2934
keywords = []
message_count = 2.0
messages = ['67152', '67153']
nosy_count = 1.0
nosy_names = ['ncoghlan']
pr_nums = []
priority = 'normal'
resolution = 'not a bug'
stage = None
status = 'closed'
superseder = None
type = None
url = 'https://bugs.python.org/issue2934'
versions = []

@ncoghlan
Copy link
Contributor Author

The rich compare implementation for set objects raises TypeError
directly instead of returning NotImplemented to allow the other type
involved in the comparison a chance at handling the operation.

@ncoghlan
Copy link
Contributor Author

Eh, never mind, raising the TypeError explicitly is necessary due to the
misbehaviour of the default comparisons in 2.x.

I'll work around the problem in my test case.

@ezio-melotti ezio-melotti transferred this issue from another repository Apr 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant