-
Notifications
You must be signed in to change notification settings - Fork 190
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
CSTValidationError Must have at least one space before 'for' keyword. #854
Comments
Note that the parse error doesn't happen anymore with the native parser, but the validation error is still there. That should be reasonably easy to fix |
@zsol Looks like there might still be some uncovered cases - the following fails on the latest PyPI version: cst.parse_module("[(b if 1 else a)for x in []]") |
@zsol seems like it's something specific to ternary statements that's not getting parsed correctly as the following also fail with a similar error: cst.parse_module('assert(1 if True else 0)')
cst.parse_module('1 if True else(1 if True else 0)') |
We'll probably need to relax the validation rules even further than #935, if it's still broken in recent releases |
Code
Parser output
The text was updated successfully, but these errors were encountered: