aws-amplify / amplify-category-api

The AWS Amplify CLI is a toolchain for simplifying serverless web and mobile development. This plugin provides functionality for the API category, allowing for the creation and management of GraphQL and REST based backends for your amplify project.
https://docs.amplify.aws/
Apache License 2.0
89 stars 76 forks source link

🛑 ENOENT: no such file or directory, stat '.../schema.graphql' #1431

Closed rafaelfaria closed 1 year ago

rafaelfaria commented 1 year ago

How did you install the Amplify CLI?

npm

If applicable, what version of Node.js are you using?

16.18.1

Amplify CLI Version

16.18.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

For my schema, I organised all of them in different files, so I have users.graphql, courses.graphql, etc... I don't have a "schema.graphql".

I have just recently updated the amplify version, and I started getting the following message When I finish pushing my changes:

🛑 ENOENT: no such file or directory, open '/Users/..../myproject/amplify/backend/api/GraphQLAPI/schema.graphql'

Resolution: Please report this issue at https://github.com/aws-amplify/amplify-cli/issues and include the project identifier from: 'amplify diagnose --send-report' Learn more at: https://docs.amplify.aws/cli/project/troubleshooting/ 🛑 ENOENT: no such file or directory, stat '/Users/..../myproject/amplify/backend/api/GraphQLAPI/schema.graphql'

Expected behavior

I shouldn't get this message. The schema is there, just separately in different files.

Reproduction steps

  1. Create schema for your models without the default "schema.graphl"

Project Identifier

No response

Log output

``` # Put your logs below this line ```

Additional information

No response

Before submitting, please confirm:

johnf commented 1 year ago

Confirming I see the same issue after upgrading. I also have a schema directory instead of a schema.graphql

ykethan commented 1 year ago

hey @rafaelfaria and @rafaelfaria, 👋 thank you for reaching out. This issue is currently being tracked on https://github.com/aws-amplify/amplify-category-api/issues/1074. transferring this issue to api-category repository for better tracking.

AnilMaktala commented 1 year ago

Hi @rafaelfaria and @johnf, The engineering team is actively investigating the specific #1074 issue as we have been able to reproduce it in the latest CLI version.