You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
$ ruff x.py
error: Failed to parse x.py:1:16: f-string: single '}' is not allowed
x.py:1:16: E999 SyntaxError: f-string: single '}' is not allowed
Found 1 error.
$ ruff --version
ruff 0.0.292
Thanks for the bug report! It seems to be caused by the two {{ inside the format spec part. It seems that the rules for escaping {/} are different in and out of a format spec.
Activity
dhruvmanila commentedon Oct 3, 2023
Thanks for the bug report! It seems to be caused by the two
{{inside the format spec part. It seems that the rules for escaping{/}are different in and out of a format spec.Avoid curly brace escape in f-string format spec (#7780)