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

pyupgrade rule for Unpack #13891

Open
fzimmermann89 opened this issue Oct 23, 2024 · 0 comments
Open

pyupgrade rule for Unpack #13891

fzimmermann89 opened this issue Oct 23, 2024 · 0 comments
Labels
accepted Ready for implementation help wanted Contributions especially welcome rule Implementing or modifying a lint rule

Comments

@fzimmermann89
Copy link

It seems ruff is missing asottile/pyupgrade#745 G[Unpack[T]] => G[*T] to change UNPACK to asterisk if supported by the python version:

from typing import Unpack
def f(*x: Unpack[tuple[int, ...]]):
    return x

should be rewritten as

def f(*x: *tuple[int, ...]):
    return x
@MichaReiser MichaReiser added the rule Implementing or modifying a lint rule label Oct 23, 2024
@AlexWaygood AlexWaygood added accepted Ready for implementation help wanted Contributions especially welcome labels Oct 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
accepted Ready for implementation help wanted Contributions especially welcome rule Implementing or modifying a lint rule
Projects
None yet
Development

No branches or pull requests

3 participants