aws-amplify / amplify-cli

The AWS Amplify CLI is a toolchain for simplifying serverless web and mobile development.
Apache License 2.0
2.83k stars 823 forks source link

Build Timing out using latest Amplify CLI v12.12.6 and Amplify Studio Gen 1 #13903

Closed kimberlyas closed 1 month ago

kimberlyas commented 3 months ago

How did you install the Amplify CLI?

npm

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

16.13.0

Amplify CLI Version

12.12.6

What operating system are you using?

Ubuntu

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

I am unable to deploy my Amplify App using the latest Amplify CLI v12.12.6. I am working in a Gen 1 Amplify Project with Amplify Studio enabled. And I am deploying using the Amplify CI/CD pipeline and default build image (Amazon Linux 2023). The issue is that the build keeps timing out without any errors being shown even after setting the build timeout to its max at 2 hrs. So I am unable to deploy the app.

Build consistently times out at this point below:

2024-08-02T20:04:50.408Z [WARNING]: ✔ Successfully pulled backend environment staging from the cloud.
2024-08-02T20:04:50.488Z [INFO]: ✅
2024-08-02T20:04:52.219Z [INFO]: Note: It is recommended to run this command from the root of your app directory

Expected behavior

The Amplify App should have completed its build and be deployed successfully using the latest Amplify CLI version.

Reproduction steps

  1. Create a Gen 1 Amplify project and enable Amplify Studio.
  2. Add Amplify resources - api & auth.
  3. Trigger CI pipeline build and deploy using latest CLI in build settings.

Project Identifier

No response

Log output

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

Additional information

In troubleshooting, I was able to deploy by downgrading the Amplify CLI in the build settings to a previous version v12.0.3 in order for the app to build and deploy successfully.

So it seems the issue is with the latest versions of the Amplify CLI where they don't build Gen 1 Amplify Studio projects.

Before submitting, please confirm:

ykethan commented 3 months ago

Hey @kimberlyas, thank you for reaching out. Could you provide us the app-id and region? additionally, does this occurs locally as well? for example: when running a pull in a empty directory or the existing app Are there any additional outputs on if you add AMPLIFY_ENABLE_DEBUG_OUTPUT to true as environment variable and run a build?

kimberlyas commented 2 months ago

Hi @ykethan, please see requested information:

App ID: d3gljibf5lo8bp Region: us-east-1

When pulling the app, I don't experience any errors. Upon enabling the variable given, I see some additional warning outputs below both locally and in the deploy build:

[WARNING] @aws-cdk/aws-apigatewayv2-alpha.WebSocketApiKeySelectionExpression is deprecated. This API will be removed in the next major release. [WARNING] @aws-cdk/aws-apigatewayv2-alpha.WebSocketApiKeySelectionExpression is deprecated. This API will be removed in the next major release. [WARNING] @aws-cdk/aws-apigatewayv2-alpha.MappingValue is deprecated. This API will be removed in the next major release.

Please see full deploy build output when using latest CLI version (v12.12.6) below: BUILD.txt

ykethan commented 2 months ago

Hey @kimberlyas, thank you for the information. With the latest versions of Amplify you will need to update the CDK libraries and the extensibility package . Refer to migration documentation: https://docs.amplify.aws/gen1/react/tools/cli/migration/aws-cdk-migration/#how-do-i-migrate On updating this, could you retry the build with the latest version of Amplify CLI and let us know if this mitigates the issue.

ykethan commented 1 month ago

Closing the issue due to inactivity. Do reach out to us if you are still experiencing this issue

github-actions[bot] commented 1 month ago

This issue is now closed. Comments on closed issues are hard for our team to see. If you need more assistance, please open a new issue that references this one.