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

ValueError exception raised when using IntEnum with an attribute called "name" and @unique decorator #71080

Closed
JulienEnche mannequin opened this issue Apr 30, 2016 · 4 comments
Assignees
Labels
stdlib Python modules in the Lib dir type-bug An unexpected behavior, bug, or error

Comments

@JulienEnche
Copy link
Mannequin

JulienEnche mannequin commented Apr 30, 2016

BPO 26893
Nosy @warsaw, @ethanfurman, @berkerpeksag, @zhangyangyu
Files
  • enumtest.py
  • 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 = 'https://github.com/ethanfurman'
    closed_at = <Date 2016-05-04.20:27:04.608>
    created_at = <Date 2016-04-30.12:35:25.970>
    labels = ['type-bug', 'library']
    title = 'ValueError exception raised when using IntEnum with an attribute called "name" and @unique decorator'
    updated_at = <Date 2016-05-04.20:27:04.607>
    user = 'https://bugs.python.org/JulienEnche'

    bugs.python.org fields:

    activity = <Date 2016-05-04.20:27:04.607>
    actor = 'berker.peksag'
    assignee = 'ethan.furman'
    closed = True
    closed_date = <Date 2016-05-04.20:27:04.608>
    closer = 'berker.peksag'
    components = ['Library (Lib)']
    creation = <Date 2016-04-30.12:35:25.970>
    creator = 'Julien Enche'
    dependencies = []
    files = ['42664']
    hgrepos = []
    issue_num = 26893
    keywords = ['3.5regression']
    message_count = 4.0
    messages = ['264554', '264555', '264568', '264600']
    nosy_count = 7.0
    nosy_names = ['barry', 'eli.bendersky', 'ethan.furman', 'python-dev', 'berker.peksag', 'xiang.zhang', 'Julien Enche']
    pr_nums = []
    priority = 'normal'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'behavior'
    url = 'https://bugs.python.org/issue26893'
    versions = ['Python 3.5', 'Python 3.6']

    @JulienEnche
    Copy link
    Mannequin Author

    JulienEnche mannequin commented Apr 30, 2016

    The linked file fails with the following error :
    ValueError: duplicate values found in <enum 'User'>: id -> User.name, name -> User.name

    This exception was not raised with Python 3.4.

    @JulienEnche JulienEnche mannequin added the type-bug An unexpected behavior, bug, or error label Apr 30, 2016
    @serhiy-storchaka serhiy-storchaka added the stdlib Python modules in the Lib dir label Apr 30, 2016
    @berkerpeksag
    Copy link
    Member

    Looks like 2545bfe0d273 (bpo-23486) is the culprit.

    @ethanfurman
    Copy link
    Member

    Thanks for catching that.

    @python-dev
    Copy link
    Mannequin

    python-dev mannequin commented May 1, 2016

    New changeset 1b6581bae5a1 by Ethan Furman in branch '3.5':
    bpo-26893: use mro() to examine class heirarchy
    https://hg.python.org/cpython/rev/1b6581bae5a1

    New changeset 7188de6b50ab by Ethan Furman in branch 'default':
    bpo-26893: use mro() to examine class heirarchy
    https://hg.python.org/cpython/rev/7188de6b50ab

    @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
    stdlib Python modules in the Lib dir type-bug An unexpected behavior, bug, or error
    Projects
    None yet
    Development

    No branches or pull requests

    3 participants