Skip to content

Avoid extension install wait deadline race#300

Merged
IlyaasK merged 3 commits into
mainfrom
hypeship/fix-extension-install-wait
Jun 26, 2026
Merged

Avoid extension install wait deadline race#300
IlyaasK merged 3 commits into
mainfrom
hypeship/fix-extension-install-wait

Conversation

@IlyaasK

@IlyaasK IlyaasK commented Jun 26, 2026

Copy link
Copy Markdown
Contributor

Summary

  • fix the enterprise extension install wait so it does not sleep across its deadline before failing
  • add focused coverage for the retry-delay calculation
  • speed up public e2e startup by restoring the Go build cache for the e2e job and pre-pulling headful/headless images in parallel before the Go e2e suite
  • keep server e2e files, Go test files, and testdata out of Docker image build contexts so test-only edits do not invalidate runtime image build layers

Timing

Before this PR on the rebased public branch:

  • test-server-e2e job: 4m20s
  • Run server e2e tests step: 3m50s
  • Go e2e package runtime: 186.989s
  • first display headless container start: 25.4s
  • first display headful container start: 28.0s

After this PR:

  • build-headful / docker: 50s
  • build-headless / docker: 52s
  • test-server-e2e job: 3m28s
  • Pull e2e images step: 32s
  • Run server e2e tests step: 2m29s
  • Go e2e package runtime: 129.429s
  • first measured container starts are now about 3-4s instead of paying the serial image pull during the display tests

The Go e2e package runtime is now under 2.5m. The total e2e job is still above 2.5m because GitHub Actions setup plus the explicit image pull are counted around the Go test process.

The Docker context cleanup makes image builds more stable for test-only PRs by preventing e2e/test-only files from invalidating runtime image builder layers.

Validation

  • git diff --check
  • yq . .github/workflows/server-test.yaml >/dev/null
  • cd server && go test ./e2e -run TestNextExtensionInstallPollDelay -count=1
  • autoreview clean after Docker context cleanup
  • CI green after Docker context cleanup: build-headful, build-headless, test-server-unit, test-server-e2e, scan, chromium-launcher test, socket checks

Follow-up for Cursor Bugbot feedback on #299.


Note

Low Risk
Changes are limited to e2e test timing, GitHub Actions workflow, and Docker ignore rules with no production runtime or auth logic touched.

Overview
Fixes a deadline race in enterprise extension install polling: waitForExtensionInstalled now uses nextExtensionInstallPollDelay (shorter sleeps when little time remains, skip sleep when past deadline) instead of a fixed 1s wait, with unit tests for the delay helper.

CI / build speed: the server e2e job re-enables the Go module cache (server/go.sum) and pre-pulls headful and headless Chromium images in parallel before make test-e2e.

Docker context: .dockerignore excludes server/e2e, server/**/*_test.go, and server/**/testdata so test-only changes do not invalidate runtime image build layers.

Reviewed by Cursor Bugbot for commit 46007d2. Bugbot is set up for automated code reviews on this repo. Configure here.

@IlyaasK IlyaasK force-pushed the hypeship/fix-extension-install-wait branch from 2cdd449 to 23e471f Compare June 26, 2026 15:11
@IlyaasK IlyaasK marked this pull request as ready for review June 26, 2026 15:43
@IlyaasK IlyaasK requested a review from sjmiller609 June 26, 2026 15:44
@IlyaasK IlyaasK merged commit 16fa914 into main Jun 26, 2026
11 checks passed
@IlyaasK IlyaasK deleted the hypeship/fix-extension-install-wait branch June 26, 2026 15:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants