Syntax error parsing commented-out graphql code in schema #1157
Labels
bug
Something isn't working
duplicate
This issue or pull request already exists
graphql-transformer-v2
transferred
How did you install the Amplify CLI?
npm
If applicable, what version of Node.js are you using?
v16.13.1
Amplify CLI Version
10.6.1
What operating system are you using?
Mac
Did you make any manual changes to the cloud resources managed by Amplify? Please describe the changes made.
No manual changes made
Describe the bug
Commented-out code in
schema.graphql
causes syntax error:Expected behavior
Commented-out graphql code should be ignored.
Reproduction steps
mkdir comment
cd comment
amplify init
(accept defaults)amplify add api
(graphql, blank schema, edit y, insert schema below)amplify push
Error:
Schema
Project Identifier
No response
Log output
Additional information
I believe this started happening after one of the recent updates to the amplify CLI since I have not made significant schema changes.
This problem is resolved by removing the parenthetical portion of the commented-out code:
In other words, the following schema with the above removed from the commented-out line works:
Before submitting, please confirm:
The text was updated successfully, but these errors were encountered: