Skip to content

ci: pin deno to 2.8.2 (2.8.3 regressed import-map override resolution)#120

Merged
AquiGorka merged 1 commit into
mainfrom
ci/pin-deno-2.8.2
Jun 11, 2026
Merged

ci: pin deno to 2.8.2 (2.8.3 regressed import-map override resolution)#120
AquiGorka merged 1 commit into
mainfrom
ci/pin-deno-2.8.2

Conversation

@AquiGorka

Copy link
Copy Markdown
Contributor

Summary

Pin the CI deno toolchain to 2.8.2. denoland/setup-deno@v2 with deno-version: v2.x floated to deno 2.8.3 (released 2026-06-11), which regressed import-map override resolution and broke the pay tests' mock isolation — turning the test job red across all open PRs.

CI-config only — no production code, no test code changes.

Bisection (Linux containers, cold cache)

deno pay test import-map overrides test job
2.7.x / 2.8.2 applied (deno info: env.ts absent from the pay graph) green
2.8.3 bypassed (deno info: real drizzle/config.ts, generate-jwt.ts, service-auth-secret.ts + env.ts all in the graph) red (34 passed / 11 failed)

Under 2.8.3 the real modules load instead of the mocks, so src/config/env.ts eager-evaluates requireEnv("DATABASE_URL") at module load → DATABASE_URL is not loaded in the 11 handler-importing pay tests. Satisfying the env vars under 2.8.3 turns the failures into assertion errors (real deps, not PGlite/jwt mocks) — confirming every override is inert, not just one. The env.ts eager read is intentional production fail-fast and is left untouched.

Reproduced only on denoland/deno:debian-2.8.3; green on 2.8.2 in every configuration (serial/parallel, 2-cpu, cold cache).

Why pin (not lazify / not mock)

The mocks already isolate the pay tests correctly on 2.8.2 — there is no real race. The only change needed is to stop floating onto the regressed 2.8.3. Pinning to 2.8.2 restores all overrides at once. The e2e/build jobs pin deno 2.7.9 via compose and are unaffected.

This PR's own CI runs on the pin → it is self-validating.

Upstream: deno 2.8.3 import-map specific-key override regression (to be filed / tracked; revert the pin once a fixed 2.8.x ships).

deno 2.8.3 (which setup-deno's `v2.x` floats to) stopped applying the pay
tests' import-map module overrides (config.ts→PGlite, jwt, channel deps). The
real modules load instead, so src/config/env.ts eager-evaluates
requireEnv("DATABASE_URL") at module load and the DB-touching pay tests fail
(34 passed / 11 failed). Bisected in Linux containers, cold cache:

  - deno 2.8.2 / 2.7.x: overrides applied (`deno info` shows env.ts absent from
    the pay graph) → suite green.
  - deno 2.8.3: overrides bypassed (`deno info` shows the real config/jwt/
    service-auth-secret + env.ts in the graph) → suite red. With env vars
    satisfied the failures become assertion errors (real deps, not mocks),
    confirming every override is inert, not just one.

Pin to 2.8.2 (the last version that honors the overrides) until the upstream
regression is fixed. CI-config only; no production code touched.
@AquiGorka
AquiGorka merged commit c9d89dd into main Jun 11, 2026
7 checks passed
@AquiGorka
AquiGorka deleted the ci/pin-deno-2.8.2 branch June 11, 2026 21:55
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.

1 participant