Skip to content

Doc: Clarify dict equality irrespective of ordering. #16266

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

Merged
merged 1 commit into from
Sep 19, 2019

Conversation

toonarmycaptain
Copy link
Contributor

Despite dicts now maintaining insertion order, {'a':1, 'b':2} == {'b':2, 'a':1} >>> True - and presumably will stay accurate due to the magnitude of such a breaking change.

Despite dicts now maintaining insertion order, `{'a':1, 'b':2} == {'b':2, 'a':1} >>> True` - and presumably will stay accurate due to the magnitude of such a breaking change.
@bedevere-bot bedevere-bot added docs Documentation in the Doc dir awaiting review labels Sep 18, 2019
@toonarmycaptain toonarmycaptain marked this pull request as ready for review September 18, 2019 17:42
@tirkarthi
Copy link
Member

I think by same here it's implicit that order is not considered for dict comparison but making it explicit doesn't seem to hurt though. cc: @rhettinger

@toonarmycaptain
Copy link
Contributor Author

toonarmycaptain commented Sep 18, 2019

Agreed, but the question was posed in the Python room on stackoverflow by a maintainer, so I similarly figured it wouldn't hurt, presuming this is behaviour intended to remain going forward.

@matrixise matrixise changed the title Clarify dict equality irrespective of ordering. Doc: Clarify dict equality irrespective of ordering. Sep 19, 2019
@matrixise matrixise merged commit 3171d67 into python:master Sep 19, 2019
@miss-islington
Copy link
Contributor

Thanks @toonarmycaptain for the PR, and @matrixise for merging it 🌮🎉.. I'm working now to backport this PR to: 3.7, 3.8.
🐍🍒⛏🤖 I'm not a witch! I'm not a witch!

@miss-islington
Copy link
Contributor

I'm having trouble backporting to 3.8. Reason: 'Error 110 while writing to socket. Connection timed out.'. Please retry by removing and re-adding the needs backport to 3.8 label.

@bedevere-bot
Copy link

GH-16276 is a backport of this pull request to the 3.7 branch.

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Sep 19, 2019
(cherry picked from commit 3171d67)

Co-authored-by: toonarmycaptain <toonarmycaptain@hotmail.com>
@miss-islington
Copy link
Contributor

Thanks @toonarmycaptain for the PR, and @matrixise for merging it 🌮🎉.. I'm working now to backport this PR to: 3.8.
🐍🍒⛏🤖

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Sep 19, 2019
(cherry picked from commit 3171d67)

Co-authored-by: toonarmycaptain <toonarmycaptain@hotmail.com>
@bedevere-bot
Copy link

GH-16277 is a backport of this pull request to the 3.8 branch.

miss-islington added a commit that referenced this pull request Sep 19, 2019
(cherry picked from commit 3171d67)

Co-authored-by: toonarmycaptain <toonarmycaptain@hotmail.com>
miss-islington added a commit that referenced this pull request Sep 19, 2019
(cherry picked from commit 3171d67)

Co-authored-by: toonarmycaptain <toonarmycaptain@hotmail.com>
@matrixise
Copy link
Member

Thank you for your PR, this one has been merged into master, 3.8 and 3.7

@toonarmycaptain toonarmycaptain deleted the patch-2 branch September 19, 2019 12:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs Documentation in the Doc dir skip issue skip news
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants