Skip to content

Argument Clinic: add support for deprecating keyword use of parameters #107704

Description

@erlend-aasland

See #95065 (comment) by Serhiy. Quoting:

Turn positional-or-keyword parameters into positional-only parameters. A directive which means "the preceding positional-or-keyword parameters will be positional-only parameters in future".

In #95151, Argument Clinic learned how to deprecate positional use of parameters. In this issue, we propose to teach Argument Clinic how to deprecate keyword use of parameters.

Suggesting to use a similar syntax as the one introduced in #95151

func
   a: object
   / [from X.Y]

Meaning a will be positional-only from Python version X.Y. We can reuse parts of the code introduced in #95151 to implement this feature.

Linked PRs

Activity

  1. erlend-aasland commented on Aug 7, 2023

    @erlend-aasland
    ContributorAuthor
  2. serhiy-storchaka commented on Aug 8, 2023

    @serhiy-storchaka
    Member

    I am working on this.

  3. added 6 commits that reference this issue on Aug 14, 2023
  4. erlend-aasland commented on Aug 22, 2023

    @erlend-aasland
    ContributorAuthor

    Thanks for doing this, Serhiy.

  5. added a commit that references this issue on Sep 26, 2023
  6. added a commit that references this issue on Oct 1, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions