Replies: 2 comments
-
Yup! We have rules for that: You'd turn them on like: [tool.ruff]
extend-select = ["UP"]
target-version = "py310" That enables all the "upgrade"-related rules, but you can be more targeted if you want: [tool.ruff]
extend-select = [
"UP006", # non-pep585-annotation
"UP007", # non-pep604-annotation
]
target-version = "py310" |
Beta Was this translation helpful? Give feedback.
0 replies
-
Perfect, thanks Charlie! |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I know that ruff has the ability to move type-specific imports into a type checking block at the top of the file (aside: how to do I enable that?), but I was wondering if it also had the ability to force-convert all types into the 3.10 syntax. i.e.
List[str]
->list[str]
, etc.Thanks!
Beta Was this translation helpful? Give feedback.
All reactions