Skip to content

bpo-32929: Dataclasses: Change the tri-state hash parameter to the boolean unsafe_hash.#5891

Merged
ericvsmith merged 20 commits intopython:masterfrom
ericvsmith:bpo-32929-dataclasses-unsafe_hash
Feb 26, 2018
Merged

bpo-32929: Dataclasses: Change the tri-state hash parameter to the boolean unsafe_hash.#5891
ericvsmith merged 20 commits intopython:masterfrom
ericvsmith:bpo-32929-dataclasses-unsafe_hash

Conversation

@ericvsmith
Copy link
Member

@ericvsmith ericvsmith commented Feb 25, 2018

@ericvsmith ericvsmith merged commit dbf9cff into python:master Feb 26, 2018
@miss-islington
Copy link
Contributor

Thanks @ericvsmith for the PR 🌮🎉.. I'm working now to backport this PR to: 3.7.
🐍🍒⛏🤖

@bedevere-bot
Copy link

@ericvsmith: Please replace # with GH- in the commit message next time. Thanks!

@ericvsmith ericvsmith deleted the bpo-32929-dataclasses-unsafe_hash branch February 26, 2018 02:30
@bedevere-bot
Copy link

GH-5902 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 Feb 26, 2018
…olean unsafe_hash. (pythonGH-5891)

unsafe_hash=False is now the default. It is the same behavior as the old hash=None parameter. unsafe_hash=True will try to add __hash__. If it already exists, TypeError is raised.
(cherry picked from commit dbf9cff)

Co-authored-by: Eric V. Smith <ericvsmith@users.noreply.github.com>
ericvsmith added a commit that referenced this pull request Feb 26, 2018
…olean unsafe_hash. (GH-5891) (GH-5902)

unsafe_hash=False is now the default. It is the same behavior as the old hash=None parameter. unsafe_hash=True will try to add __hash__. If it already exists, TypeError is raised.
(cherry picked from commit dbf9cff)

Co-authored-by: Eric V. Smith <ericvsmith@users.noreply.github.com>
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

Successfully merging this pull request may close these issues.

4 participants