aws-amplify / aws-amplify/amplify-hosting

Deployment fails with no error message when test artifacts are present

Open
#1,039 20 comments 11 reactions 0 assignees View on GitHub
bug deploy
Dominant language
Dockerfile
Stars
481
Forks
123
PR merge metrics
No merged PRs in 30d

Description

First of all, I am aware that there are 2 similar-looking issues already open, but this is different: for me, the deployment step fails without any error message, whereas the other issues refer to situations where the CI log says "Deployment failed".

I added Cypress tests to my build process about a week ago, and initially it worked. Then I added visual snapshots to my tests, which produce .png artifacts, as well as the .mp4 ones normally generated by Cypress. I am skipping these tests on my master branch (via a Node.js script), but the snapshots are always there. This leads to 2 situations:
- PR previews run the tests ok, but fail on deployment - no error message, it just stops after uploading the test artifacts
- master branch skips tests, but also fails on deployment - again no error message, it just stops after uploading the test artifacts

For the master branch, this is the entire log output for the deployment step:

![image](https://user-images.githubusercontent.com/21035153/92955782-b724ce80-f45d-11ea-8145-15a94d2ffc80.png)
![image](https://user-images.githubusercontent.com/21035153/92955809-c3109080-f45d-11ea-8264-7912cbb89955.png)

If I remove the "test" step from the build entirely, it works just fine. This is really concerning, since a significant part of CI is to run tests, and it's exactly what I cannot do.

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the deployment step with Cypress-generated .png and .mp4 test artifacts, comparing a PR preview with the master branch where tests are skipped. Done means deployments complete successfully with these artifacts, or the deployment step reports a useful error instead of stopping after artifact upload.

Written by the indexing model from the issue text.

Assessment

Tech stack
cypress, node.js
Domain
ci-cd, cloud
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.