Back to Prisma

Brief: D3 R1 — prove the installed compatibility contract

projects/prisma7-config/briefs/D3-R1.md

7.10.0-integration-fix-prisma-publish-token.14.1 KB
Original Source

Brief: D3 R1 — prove the installed compatibility contract

Task

Extend the existing packed prisma7-compatibility client E2E so real installed Prisma 7 commands prove the finalized config contract: versioned config precedence, invalid versioned config hard-failure without legacy fallback, quiet legacy fallback, prisma7.config.ts generation, and equivalent config behavior through both Prisma 7 entrypoints present in this branch. Preserve the existing packed version/generate/migrate/db/client smoke, then complete the production literal audit and final cross-package gates.

Scope

In: packages/client/tests/e2e/prisma7-compatibility/ fixture/tests/steps/package metadata as needed; concise installed-command assertions for loaded config paths, exit status, and generated files; narrow fixes to D1/D2 implementation/tests only if installed evidence exposes a real regression; final production prisma.config.ts literal classification; final validation.

Out: New package-manager topology coverage, Prisma 8 implementation, network installs/fetches, release automation, config conversion, warnings/deprecation, unrelated E2E refactors, broad snapshot churn, and renaming legacy fallback fixtures solely for consistency.

Completed when

  • Installed prisma7 and installed prisma commands both demonstrate the shared Prisma 7 versioned-precedence policy without relying only on loader unit tests.
  • A real command with an invalid prisma7.config.* beside a valid legacy config exits non-zero and identifies the versioned file; no legacy fallback occurs.
  • A legacy-only project succeeds through fallback with the existing loaded-file diagnostic and no new warning/deprecation output.
  • Real init behavior writes prisma7.config.ts (with identity-appropriate import where both entrypoints can be exercised) and existing packed generate/migrate/db/generated-client smoke remains green.
  • Final production-literal audit finds no unclassified stale concrete default guidance; intentional legacy/generic references are recorded in the report.
  • Affected builds/focused package tests and pnpm --filter @prisma/client test:e2e --verbose --runInBand prisma7-compatibility pass; relevant lint/Prettier, git diff --check, and transient-ID scan pass; changes are committed explicitly.

Standing instruction

Prefer behavior assertions from installed commands over implementation-specific mocks. Keep added scenarios concise and isolated in temporary directories. Never install packages or fetch from the network inside the test.

References

  • Slice spec: projects/prisma7-config/slices/versioned-config-coexistence/spec.md.
  • Slice plan: projects/prisma7-config/slices/versioned-config-coexistence/plan.md § Dispatch 3.
  • Review ledger: projects/prisma7-config/reviews/code-review.md (read-only).
  • Existing E2E: packages/client/tests/e2e/prisma7-compatibility/.
  • D1/D2 hand-off commits through 14d5c875bb.
  • Repository E2E instructions in AGENTS.md.

Operational metadata

  • Model tier: orchestrator — installed-artifact tests are cross-package and must avoid network/fixture false positives.
  • Time-box: 90 minutes.
  • Halt conditions: Halt if the E2E harness cannot expose both entrypoints from packed artifacts without changing package topology; if a required test would install/fetch; if installed behavior contradicts the settled spec; if completing proof requires Prisma 8 implementation; or if a gate remains red for unrelated infrastructure reasons.

Carry-over

  • D1 and D2 are reviewer-SATISFIED; do not redesign their contracts.
  • Accepted unchanged production literals: the historical Prisma 6 compatibility comment and concrete legacy panic-test fixture lookup. Re-audit rather than assuming no new escapees.
  • Local engine-backed tests previously lacked schema-engine-linux-nixos; the standard client Docker E2E is the intended installed-artifact validation boundary.

Return shape

Report reconnaissance, decisions, diff highlights, every gate result, commits, literal audit classification, surprises, deferrals, and pushback. Write heartbeat; do not edit project specs/plans/reviews.