Skip to content

Make ParamSpec.args/kwargs more useful objects #87949

Closed

Description

@JelleZijlstra
BPO 43783
Nosy @gvanrossum, @ilevkivskyi, @JelleZijlstra, @Fidget-Spinner
PRs
  • bpo-43783: add ParamSpecArgs/Kwargs #25298
  • 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/JelleZijlstra'
    closed_at = <Date 2021-04-11.02:57:21.727>
    created_at = <Date 2021-04-09.02:06:06.482>
    labels = ['library', '3.10']
    title = 'Make ParamSpec.args/kwargs more useful objects'
    updated_at = <Date 2021-04-11.02:57:21.726>
    user = 'https://github.com/JelleZijlstra'

    bugs.python.org fields:

    activity = <Date 2021-04-11.02:57:21.726>
    actor = 'gvanrossum'
    assignee = 'JelleZijlstra'
    closed = True
    closed_date = <Date 2021-04-11.02:57:21.727>
    closer = 'gvanrossum'
    components = ['Library (Lib)']
    creation = <Date 2021-04-09.02:06:06.482>
    creator = 'JelleZijlstra'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 43783
    keywords = ['patch']
    message_count = 2.0
    messages = ['390583', '390763']
    nosy_count = 4.0
    nosy_names = ['gvanrossum', 'levkivskyi', 'JelleZijlstra', 'kj']
    pr_nums = ['25298']
    priority = 'normal'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = None
    url = 'https://bugs.python.org/issue43783'
    versions = ['Python 3.10']

    Activity

    1. JelleZijlstra commented on Apr 9, 2021

      @JelleZijlstra
      MemberAuthor

      Currently, typing.ParamSpec.args and ParamSpec.kwargs are just object() instances, which makes them useless for runtime inspection of __annotations__. This type was introduced by PEP-612.

      Instead, I propose to make them return some special helper object with __origin__ set to the underlying ParamSpec object. I'll work on a PR soon.

    2. added
      stdlibStandard Library Python modules in the Lib/ directory
      on Apr 9, 2021
    3. self-assigned this
      on Apr 9, 2021
    4. gvanrossum commented on Apr 11, 2021

      @gvanrossum
      Member

      New changeset 5224336 by Jelle Zijlstra in branch 'master':
      bpo-43783: Add ParamSpecArgs/Kwargs (GH-25298)
      5224336

    5. transferred this issue fromon Apr 10, 2022
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

    Metadata

    Metadata

    Assignees

    Labels

    3.10 (EOL)end of lifestdlibStandard Library Python modules in the Lib/ directory

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions