Skip to content

Reject failed Docker image builds instead of hanging#1353

Open
cristianrgreco wants to merge 4 commits into
mainfrom
codex/reject-failed-docker-builds
Open

Reject failed Docker image builds instead of hanging#1353
cristianrgreco wants to merge 4 commits into
mainfrom
codex/reject-failed-docker-builds

Conversation

@cristianrgreco

Copy link
Copy Markdown
Collaborator

Summary

  • propagate Docker image build startup failures to callers
  • reject when Docker image build streams emit errors
  • add focused unit coverage for both rejection paths
  • enable the invalid Docker target integration regression

Verification

  • red: added the build-start rejection regression against the pre-fix implementation; it received "timeout" instead of "rejected" and Vitest reported an unhandled build failed rejection
  • red: added the build-stream error regression with stream error listeners temporarily removed; it received "timeout" instead of "rejected" and Vitest reported an unhandled build failed exception
  • red: the invalid Docker target integration path previously hung until terminated
  • green: npm test -- packages/testcontainers/src/container-runtime/clients/image/docker-image-client.test.ts packages/testcontainers/src/generic-container/generic-container.test.ts -t "rejects when the Docker image build cannot start|rejects when the Docker image build stream errors|should throw an error for a target stage that does not exist"
  • npm run format
  • npm run lint
  • npm run check-compiles
  • git diff --check

Test results

  • focused green suite: 3 passed, 49 skipped

Compatibility

This is a backward-compatible bug fix. Successful Docker image builds retain their existing behavior.

@cristianrgreco cristianrgreco added the bug Something isn't working label Jun 1, 2026 — with ChatGPT Codex Connector
@netlify

netlify Bot commented Jun 1, 2026

Copy link
Copy Markdown

Deploy Preview for testcontainers-node ready!

Name Link
🔨 Latest commit 17b0bec
🔍 Latest deploy log https://app.netlify.com/projects/testcontainers-node/deploys/6a257236e667110008d1b856
😎 Deploy Preview https://deploy-preview-1353--testcontainers-node.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@cristianrgreco cristianrgreco added the patch Backward compatible bug fix label Jun 1, 2026 — with ChatGPT Codex Connector

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 5d628d2197

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working patch Backward compatible bug fix

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant