[GH-ISSUE #42] Nice error message when building image fails #22

Closed
opened 2026-03-01 21:39:11 +03:00 by kerem · 8 comments
Owner

Originally created by @xendk on GitHub (Feb 22, 2019).
Original GitHub issue: https://github.com/nektos/act/issues/42

This got me stumped for a while:

[Spec tests] docker build -t php-action:3d6545d /home/xen/dev/acdc/.github/actions/php-action
[Unit tests] docker run image=php-action:3d6545d entrypoint=["./vendor/bin/phpunit"] cmd=["--testsuite" "Unit"]
Error: Error: No such image: php-action:3d6545d

Until running act with -v told me that the build failed due to errors in the Dockerfile. Act v 0.1.0.

Originally created by @xendk on GitHub (Feb 22, 2019). Original GitHub issue: https://github.com/nektos/act/issues/42 This got me stumped for a while: ``` [Spec tests] docker build -t php-action:3d6545d /home/xen/dev/acdc/.github/actions/php-action [Unit tests] docker run image=php-action:3d6545d entrypoint=["./vendor/bin/phpunit"] cmd=["--testsuite" "Unit"] Error: Error: No such image: php-action:3d6545d ``` Until running act with `-v` told me that the build failed due to errors in the Dockerfile. Act v 0.1.0.
kerem closed this issue 2026-03-01 21:39:11 +03:00
Author
Owner

@sosedoff commented on GitHub (Feb 27, 2019):

I have reported the same bug before (#33) but i think you're running an older version of act. If you get the latest version you'll see the error message without -v flag, that should point you in the right direction.

<!-- gh-comment-id:467742027 --> @sosedoff commented on GitHub (Feb 27, 2019): I have reported the same bug before (#33) but i think you're running an older version of `act`. If you get the latest version you'll see the error message without `-v` flag, that should point you in the right direction.
Author
Owner

@xendk commented on GitHub (Feb 27, 2019):

Yes, I saw #33, but that didn't help me much.

Define "latest version"? I'm using 0.1.0, which is the latest release I've been able to find. The latest changes https://github.com/nektos/act/compare/v0.1.0...master doesn't suggest that this problem has been addressed (doesn't mean that it's not been fixed, just that it's not obvious it has been).

<!-- gh-comment-id:467749122 --> @xendk commented on GitHub (Feb 27, 2019): Yes, I saw #33, but that didn't help me much. Define "latest version"? I'm using 0.1.0, which is the latest release I've been able to find. The latest changes https://github.com/nektos/act/compare/v0.1.0...master doesn't suggest that this problem has been addressed (doesn't mean that it's not been fixed, just that it's not obvious it has been).
Author
Owner

@sosedoff commented on GitHub (Feb 27, 2019):

Right, the latest version in my point of view is go get -u github.com/nektos/act which translates as update this thing from master (or as tip). That is due to me being the contributor, so i have to be on the latest.
RE #33, i dont know, i had the same issue but after update i was able to see the exact error i was expecting without any debug flags.

<!-- gh-comment-id:467752742 --> @sosedoff commented on GitHub (Feb 27, 2019): Right, the latest version in my point of view is `go get -u github.com/nektos/act` which translates as `update this thing from master` (or as `tip`). That is due to me being the contributor, so i have to be on the latest. RE #33, i dont know, i had the same issue but after update i was able to see the exact error i was expecting without any debug flags.
Author
Owner

@xendk commented on GitHub (Feb 27, 2019):

Due to not being a contributor, my definition of latest version is the top of the releases page.

Tried checking out 0.1.0 and seeing if the issue resurfaces?

<!-- gh-comment-id:467755549 --> @xendk commented on GitHub (Feb 27, 2019): Due to not being a contributor, my definition of latest version is the top of the releases page. Tried checking out 0.1.0 and seeing if the issue resurfaces?
Author
Owner

@sosedoff commented on GitHub (Feb 28, 2019):

Yeah the latest published 0.1.0 release still has this problem.

<!-- gh-comment-id:468115276 --> @sosedoff commented on GitHub (Feb 28, 2019): Yeah the latest published 0.1.0 release still has this problem.
Author
Owner

@cplee commented on GitHub (Mar 1, 2019):

@xendk I have released version 0.1.1...can you confirm that fixes the issue?

<!-- gh-comment-id:468556970 --> @cplee commented on GitHub (Mar 1, 2019): @xendk I have released version `0.1.1`...can you confirm that fixes the issue?
Author
Owner

@xendk commented on GitHub (Mar 1, 2019):

[Test-7.0] docker build -t buildtest-action:2ff7753 /home/xen/dev/docker/docker-drupal-php7-fpm/.github/actions/buildtest-action
[Test-5.6] docker build -t buildtest-action:2ff7753 /home/xen/dev/docker/docker-drupal-php7-fpm/.github/actions/buildtest-action
[Test-7.2] docker build -t buildtest-action:2ff7753 /home/xen/dev/docker/docker-drupal-php7-fpm/.github/actions/buildtest-action
[Test-7.1] docker build -t buildtest-action:2ff7753 /home/xen/dev/docker/docker-drupal-php7-fpm/.github/actions/buildtest-action
[Test-5.6] docker run image=buildtest-action:2ff7753 entrypoint=[] cmd=[]
[Test-7.0] docker run image=buildtest-action:2ff7753 entrypoint=[] cmd=[]
Error: Error: No such image: buildtest-action:2ff7753
~/d/d/docker-drupal-php7-fpm ▶ act --version
act version 0.1.1

Not really. No indication that the build failed. I was tripped up trying to reproduce as even with a RUN false in the Dockerfile, the workflow still worked, until I figured out it was just reusing the image from previous runs.

I think that act should notice the build failed and error out with an appropriate error message.

<!-- gh-comment-id:468573902 --> @xendk commented on GitHub (Mar 1, 2019): ``` [Test-7.0] docker build -t buildtest-action:2ff7753 /home/xen/dev/docker/docker-drupal-php7-fpm/.github/actions/buildtest-action [Test-5.6] docker build -t buildtest-action:2ff7753 /home/xen/dev/docker/docker-drupal-php7-fpm/.github/actions/buildtest-action [Test-7.2] docker build -t buildtest-action:2ff7753 /home/xen/dev/docker/docker-drupal-php7-fpm/.github/actions/buildtest-action [Test-7.1] docker build -t buildtest-action:2ff7753 /home/xen/dev/docker/docker-drupal-php7-fpm/.github/actions/buildtest-action [Test-5.6] docker run image=buildtest-action:2ff7753 entrypoint=[] cmd=[] [Test-7.0] docker run image=buildtest-action:2ff7753 entrypoint=[] cmd=[] Error: Error: No such image: buildtest-action:2ff7753 ~/d/d/docker-drupal-php7-fpm ▶ act --version act version 0.1.1 ``` Not really. No indication that the build failed. I was tripped up trying to reproduce as even with a `RUN false` in the `Dockerfile`, the workflow still worked, until I figured out it was just reusing the image from previous runs. I think that `act` should notice the build failed and error out with an appropriate error message.
Author
Owner

@cplee commented on GitHub (Mar 19, 2019):

Fixed from #46 and released in 0.1.2...closing

<!-- gh-comment-id:474151038 --> @cplee commented on GitHub (Mar 19, 2019): Fixed from #46 and released in `0.1.2`...closing
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/act#22
No description provided.