-
-
Notifications
You must be signed in to change notification settings - Fork 431
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
Pest parser does not handle significant whitespaces correctly #1039
Comments
I believe the issue is this change in the parser: 1f67e3a#diff-7fe48281e06de04d34f56adf27094658fcfd043c278255b994be6a9357409231R19 Because the whitespace are ignored with async-graphql/parser/src/graphql.pest Line 1 in 69dfe25
It thinks the fragment spread is using a type_condition async-graphql/parser/src/graphql.pest Line 23 in 69dfe25
I believe we can fix the issue by setting |
Further reading of the current pest grammer indicates that a lot of significant whitespaces are currently ignored and this is not good. For example The problem is to fix that we would need to make rules atomic (with For fragment that would look like:
I am unsure how you want to proceed with this significant vs non significant spacing issue @sunli829, but let me know. |
I fixed it in the |
Will do, I believe the rest is still broken though but I guess its all right. |
EDIT: I kinda opened a larger can or worms, please read all comments to understand the full issue
Expected Behavior
Given a query like:
It used to work before to update from 4.0.1 to 4.0.10. But it now interprets the "on" in the fragment name.
Actual Behavior
Parsing error:
Steps to Reproduce the Problem
Specifications
The text was updated successfully, but these errors were encountered: