amplify-category-api
amplify-category-api copied to clipboard
Build fails in Amplify Gen 2 console but local sandbox succeeds
Environment information
System:
OS: macOS 14.5
CPU: (10) arm64 Apple M1 Pro
Memory: 109.30 MB / 16.00 GB
Shell: /bin/zsh
Binaries:
Node: 22.6.0 - ~/.nvm/versions/node/v22.6.0/bin/node
Yarn: undefined - undefined
npm: 10.8.2 - ~/.nvm/versions/node/v22.6.0/bin/npm
pnpm: undefined - undefined
NPM Packages:
@aws-amplify/auth-construct: 1.3.0
@aws-amplify/backend: 1.2.1
@aws-amplify/backend-auth: 1.1.4
@aws-amplify/backend-cli: 1.2.6
@aws-amplify/backend-data: 1.1.3
@aws-amplify/backend-deployer: 1.1.2
@aws-amplify/backend-function: 1.4.0
@aws-amplify/backend-output-schemas: 1.2.0
@aws-amplify/backend-output-storage: 1.1.1
@aws-amplify/backend-secret: 1.1.1
@aws-amplify/backend-storage: 1.1.2
@aws-amplify/cli-core: 1.1.2
@aws-amplify/client-config: 1.3.0
@aws-amplify/deployed-backend-client: 1.4.0
@aws-amplify/form-generator: 1.0.1
@aws-amplify/model-generator: 1.0.6
@aws-amplify/platform-core: 1.1.0
@aws-amplify/plugin-types: 1.2.1
@aws-amplify/sandbox: 1.2.1
@aws-amplify/schema-generator: 1.2.1
aws-amplify: 6.3.7
aws-cdk: 2.158.0
aws-cdk-lib: 2.158.0
typescript: 5.5.2
AWS environment variables:
AWS_STS_REGIONAL_ENDPOINTS = regional
AWS_NODEJS_CONNECTION_REUSE_ENABLED = 1
AWS_SDK_LOAD_CONFIG = 1
No CDK environment variables
Data packages
[email protected] /Users/vinothj/Code/Next Gen/quasr-plus
├─┬ @aws-amplify/[email protected]
│ └─┬ @aws-amplify/[email protected]
│ └── @aws-amplify/[email protected]
└─┬ @aws-amplify/[email protected]
└─┬ @aws-amplify/[email protected]
└── @aws-amplify/[email protected]
Description
Bug: After I rename a custom javascript resolver, the build fails in Amplify Gen 2 console however the build & deployment are successful in local cloud sandbox environment.
Steps to reproduce:
- Create an additional AppSync API (as we have exceeded 1MB size limit of Amplify data stack a long time ago)
- Add an external DynamoDB database in backend.ts file and create a datasource for the AppSync API
- Add a mutation in graphql schema file
- Create a custom javascript resolver function and add it to backend.ts file
- Deploy the changes
- Now rename the resolver function
- Deploy again
This time the build fails in Amplify Gen 2 console.
getIncidentAndStakeholder.js is the updated resolver file name and it is available in the code repository.