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
{{ message }}
Repository navigation
assert a := 1 produces unclear error message #138716
>>> # TODO(@sobolevn): improve this message in the next PR
>>> assert a := 1
Traceback (most recent call last):
SyntaxError: invalid syntax
What happens? assert does not allow := without () in its body.
We need to improve the error message, because current state is not really clear for the user. Why there's a syntax error? How to fix it?
Activity
pythongh-138716: Fix `assert a := b` syntax error message
pythongh-138716: Fix `assert a := b` syntax error message
gh-138716: Fix `assert a := b` syntax error message (#138718)