amplify-cli: Amplify CLI Migration fails
Note: If your issue/bug is regarding the AWS Amplify Console service, please log it in the Amplify Console GitHub Issue Tracker
Describe the bug Amplify CLI fails to migrate to newer version.
To Reproduce Steps to reproduce the behavior:
- I have a project configured with an older version of the CLI.
- Update the CLI to 3.0.0.
- Try almost any amplify command (this triggers a request to migrate).
- Try migrating.
During the migration the following appears a bit in:
⠴ Migrating your project
The following types do not have '@auth' enabled. Consider using @auth with @model
- TripComponent
- PackItem
- TripComponentConnection
- TripPackItemExclude
- TripPackItemInclude
- Trip
- User
- TripParticipation
- PackAssign
- PackList
- PackListEntry
Learn more about @auth here: https://aws-amplify.github.io/docs/cli-toolchain/graphql#auth
⠙ Migrating your projectReverting API migration.
⠋ Migrating your project
And at the end, all I get is the following error:
⠋ Migrating your projectAPI successfully reverted.
✖ There was an error migrating your project.
migration operations are rolledback.
Cannot convert undefined or null to object
Expected behavior I expect the automatic migration command to work. I haven’t really changed anything in the API other than a simple graphql schema.
Desktop (please complete the following information): Using WSL in Visual Studio Code.
About this issue
- Original URL
- State: closed
- Created 5 years ago
- Comments: 17 (5 by maintainers)
Commits related to this issue
- fix(graphql-transformer-core): fix migration errors Updated stack sanity check and stack mapping code to work with older version of project when migrating project partial fix to #2196 — committed to yuth/amplify-cli by yuth 5 years ago
- fix(graphql-transformer-core): fix migration errors (#2245) Updated stack sanity check and stack mapping code to work with older version of project when migrating project partial fix to #2196 — committed to aws-amplify/amplify-cli by yuth 5 years ago
I was able to reproduce the issue. I am working on a fix for this