# Feature or enhancement Currently when user makes an error with mixing up `==` and `=` there's a special error for that: ```python >>> 1 = 2 File "<python-input-1>", line 1 1 = 2 ^ SyntaxError: cannot assign to literal here. Maybe you meant '==' instead of '='? ``` But, not when using `assert`, where we do lots of `==` operations naturally: ```python >>> assert 1 = 2 File "<python-input-0>", line 1 assert 1 = 2 ^ SyntaxError: invalid syntax ``` I will send a PR with the improvement. <!-- gh-linked-prs --> ### Linked PRs * gh-136653 <!-- /gh-linked-prs -->
Activity
pythongh-136616: Improve `assert` syntax error messages
gh-136616: Improve `assert` syntax error messages (#136653)
pythongh-136616: Improve `assert` syntax error messages (python#136653)