-
Notifications
You must be signed in to change notification settings - Fork 5
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
Cannot handle new 3.12 f-strings, hangs up completely #66
Comments
@crankedguy - yep, this should be added on the google/yapf side. It's issued here google/yapf. when yapf support this feature, I'll update the bundled yapf. |
thanks for the info. great, only open since two months... |
@EeyoreLee The extension should still have error recovery without hanging + report an error to the user w/ stack trace in the Extension's output pane. |
this is one of the main problems that this does not happen |
The extension didn't hang up. It's still running, and just do nothing modification if yapf package raise a exception for a file. But it will indeed report an error in yapf extension output channel cause I think most of people won‘t look at it unless the extension doesn't work. |
@EeyoreLee You are right, I oversaw that in the specific output channel, however it is a bit of a burden that the whole file is affected by this,,, you cannot even disable that with # yapf: disable, yapf is just completely unusable for Python 3.12 at all then as far as I can see, if there is no other solution to circumvent that at least for portions of code |
Hi,
your extension cannot handle new f-string capabilities of Python 3.12, writing a single line of code like this
f"https://ldomain.com.com{user["x1"]["x2"]["x3"]["x3"]["x5"]}",
makes the whole extension break down silently and stops it from any further formatting.
Only if you change the inside " to ' it works again.
But this is perfectly valid now in 3.12 and a massive improvement for using f-string. Please make it possible that your extension can handle that.. And on top does not just fail silently
Thanks
The text was updated successfully, but these errors were encountered: