-
Notifications
You must be signed in to change notification settings - Fork 821
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
Amplify push with Api change overrides schema.json path #1818
Comments
We don't expose the schemaPath custom configuration and is hardcoded currently. I'm adding this as an enahncement so that this schemaPath is configurable and not overwritten. |
Codegen use to reset the location of downloaded introspection shcema to the default location when a push was done. Updated code to prevent chaning of schema location fix aws-amplify#1818
* fix(amplify-codegen): prevent schema location change on push Codegen use to reset the location of downloaded introspection shcema to the default location when a push was done. Updated code to prevent chaning of schema location fix #1818 * tests and lint
Awesome thanks! |
This issue has been automatically locked since there hasn't been any recent activity after it was closed. Please open a new issue for related bugs. Looking for a help forum? We recommend joining the Amplify Community Discord server |
Describe the bug
I have a mono repo setup where my
/amplify
folder sits in the root of the project and my/graphql
folder is located in a shared package like sopackages/core/src/graphql/schema.json
. When I'm pushing changes in the API the schemaPath setting in my.graphqlconfig.yaml
file is always overwritten. The actual mutation and query file paths are respected and only the schemaPath is changed to a defaultschemaPath: src/graphql/schema.json
To Reproduce
Steps to reproduce the behavior:
/graphql
directory somewhere other than/src
.graphqlconfig.yaml
amplify push
and confirm updates to GraphQL API and generating GraphQL statements./graphql/schema.json
created in the root of your project AND in your.graphqlconfig.yaml
the schemaPath changed back toschemaPath: src/graphql/schema.json
Expected behavior
I expect the schemaPath setting to be respected and not overwritten.
The text was updated successfully, but these errors were encountered: