-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Add autofix for RUF039 #14527
Comments
At least for the common cases. Conversions to raw strings can be tricky if backslashes are involved |
Or a fix involving backslashes at least needs to be unsafe because
|
Yeah. But even an autofix just for strings that don't have any backslashes in them would make things much more ergonomic. E.g. none of the strings that I had to manually edit in python-trio/trio#3143 had any backslashes in them. |
@AlexWaygood feel free to reopen if you'd like to encourage a second pass on this with more extensive auto-fixing! |
Thanks! 😃 I think this is going to take care of most of the noise as-is, so I'm happy to leave it there for now unless we get requests from users for fixes in more cases 👍 |
The newly added preview rule RUF039 doesn't have an autofix. It would be very convenient if it had one, since it's otherwise quite a noisy rule.
The text was updated successfully, but these errors were encountered: