Skip to content

Instance methods compare equal when their self's are equal #44345

Description

@fniessink
mannequin
BPO 1617161
Nosy @loewis, @abalkin, @devdanzin, @serhiy-storchaka, @jdemeyer, @MojoVampire
PRs
  • bpo-1617161: Make the hash and equality of methods not depending on the value of self. #7848
  • Files
  • instancemethod.py: Example
  • method_compare.diff: use identity instead of equality of 'self'
  • 1617161_test_update.diff
  • 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 2018-07-31.06:43:10.168>
    created_at = <Date 2006-12-16.21:36:32.000>
    labels = ['interpreter-core', 'type-bug', '3.8']
    title = "Instance methods compare equal when their self's are equal"
    updated_at = <Date 2018-07-31.06:43:10.167>
    user = 'https://bugs.python.org/fniessink'

    bugs.python.org fields:

    activity = <Date 2018-07-31.06:43:10.167>
    actor = 'serhiy.storchaka'
    assignee = 'none'
    closed = True
    closed_date = <Date 2018-07-31.06:43:10.168>
    closer = 'serhiy.storchaka'
    components = ['Interpreter Core']
    creation = <Date 2006-12-16.21:36:32.000>
    creator = 'fniessink'
    dependencies = []
    files = ['2254', '9666', '34367']
    hgrepos = []
    issue_num = 1617161
    keywords = ['patch']
    message_count = 20.0
    messages = ['30822', '30823', '30824', '63376', '63413', '63414', '63415', '63421', '63500', '84597', '110512', '110518', '196476', '213201', '305155', '308106', '320168', '320200', '320212', '322729']
    nosy_count = 9.0
    nosy_names = ['loewis', 'belopolsky', 'fniessink', 'ajaksu2', '_doublep', 'westley.martinez', 'serhiy.storchaka', 'jdemeyer', 'josh.r']
    pr_nums = ['7848']
    priority = 'normal'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'behavior'
    url = 'https://bugs.python.org/issue1617161'
    versions = ['Python 3.8']

    Metadata

    Metadata

    Assignees

    No one assigned

      Labels

      3.8 (EOL)end of lifeinterpreter-core(Objects, Python, Grammar, and Parser dirs)type-bugAn unexpected behavior, bug, or error

      Projects

      No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions