mirror of
https://github.com/astral-sh/ruff
synced 2026-01-23 06:20:55 -05:00
This PR adds a sometimes-available, safe autofix for [unraw-re-pattern (RUF039)](https://docs.astral.sh/ruff/rules/unraw-re-pattern/#unraw-re-pattern-ruf039), which prepends an `r` prefix. It is used only when the string in question has no backslahses (and also does not have a `u` prefix, since that causes a syntax error.) Closes #14527 Notes: - Test fixture unchanged, but snapshot changed to include fix messages. - This fix is automatically only available in preview since the rule itself is in preview