Skip to content

classmethod doesn't honour descriptor protocol of wrapped callable #63272

Closed
@grahamd

Description

@grahamd
BPO 19072
Nosy @gvanrossum, @rhettinger, @pitrou, @durban, @ambv, @berkerpeksag, @serhiy-storchaka, @eriknw, @miss-islington, @iritkatriel
PRs
  • bpo-19072: Make @classmethod support chained decorators #8405
  • [3.9] bpo-42073: allow classmethod to wrap other classmethod-like descriptors. #22757
  • bpo-19072: Update descriptor howto for decorator chaining #22934
  • [3.9] bpo-19072: Update descriptor howto for decorator chaining (GH-22934) #22935
  • bpo-42073: allow classmethod to wrap other classmethod-like descriptors #27115
  • [3.10] bpo-42073: allow classmethod to wrap other classmethod-like descriptors (GH-27115) #27162
  • bpo-19072: Classmethod can wrap other classmethod like descriptors. See b83861f #29634
  • [3.10] bpo-19072: Classmethod can wrap other classmethod like descriptors (GH-29634) #29643
  • Files
  • funcobject.c.diff: Patch to classmethod tp_descr_get to do descriptor binding on wrapped object.
  • issue19072.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 = 'https://github.com/rhettinger'
    closed_at = <Date 2019-08-24.22:37:58.662>
    created_at = <Date 2013-09-22.13:22:44.087>
    labels = ['interpreter-core', 'type-feature', '3.8']
    title = "classmethod doesn't honour descriptor protocol of wrapped callable"
    updated_at = <Date 2021-11-19.19:12:24.582>
    user = 'https://bugs.python.org/grahamd'

    bugs.python.org fields:

    activity = <Date 2021-11-19.19:12:24.582>
    actor = 'lukasz.langa'
    assignee = 'rhettinger'
    closed = True
    closed_date = <Date 2019-08-24.22:37:58.662>
    closer = 'rhettinger'
    components = ['Interpreter Core']
    creation = <Date 2013-09-22.13:22:44.087>
    creator = 'grahamd'
    dependencies = []
    files = ['31842', '42737']
    hgrepos = []
    issue_num = 19072
    keywords = ['patch']
    message_count = 23.0
    messages = ['198274', '198672', '198673', '198679', '198682', '201512', '201523', '201572', '201713', '201714', '264911', '264916', '321217', '321222', '321227', '350404', '379509', '379510', '384405', '397547', '397551', '406607', '406617']
    nosy_count = 12.0
    nosy_names = ['gvanrossum', 'rhettinger', 'pitrou', 'grahamd', 'ionelmc', 'daniel.urban', 'lukasz.langa', 'berker.peksag', 'serhiy.storchaka', 'eriknw', 'miss-islington', 'iritkatriel']
    pr_nums = ['8405', '22757', '22934', '22935', '27115', '27162', '29634', '29643']
    priority = 'normal'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'enhancement'
    url = 'https://bugs.python.org/issue19072'
    versions = ['Python 3.8']

    Metadata

    Metadata

    Assignees

    Labels

    3.8 (EOL)end of lifeinterpreter-core(Objects, Python, Grammar, and Parser dirs)type-featureA feature request or enhancement

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions