Repository navigation
TML-2763: Add telemetry contract hash advance migration - #666
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (7)
✅ Files skipped from review due to trivial changes (4)
🚧 Files skipped from review as they are similar to previous changes (3)
📝 WalkthroughWalkthroughThis PR introduces a new migration for telemetry-backend that records a contract hash advance. The migration declares a from/to hash transition, provides before/after contract snapshots as TypeScript and JSON artifacts, and specifies no actual data operations. ChangesContract Hash Advance Migration
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Possibly related PRs
Suggested reviewers
Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
c283668 to
f63651e
Compare
Fixes: TML-2763 Signed-off-by: Alexey Orlenko's AI Agent <[email protected]>
f63651e to
7586799
Compare
size-limit report 📦
|
@prisma-next/extension-author-tools
@prisma-next/mongo-runtime
@prisma-next/family-mongo
@prisma-next/sql-runtime
@prisma-next/family-sql
@prisma-next/extension-arktype-json
@prisma-next/middleware-cache
@prisma-next/mongo
@prisma-next/extension-paradedb
@prisma-next/extension-pgvector
@prisma-next/extension-postgis
@prisma-next/postgres
@prisma-next/sql-orm-client
@prisma-next/sqlite
@prisma-next/target-mongo
@prisma-next/adapter-mongo
@prisma-next/driver-mongo
@prisma-next/contract
@prisma-next/utils
@prisma-next/config
@prisma-next/errors
@prisma-next/framework-components
@prisma-next/operations
@prisma-next/ts-render
@prisma-next/contract-authoring
@prisma-next/ids
@prisma-next/psl-parser
@prisma-next/psl-printer
@prisma-next/cli
@prisma-next/cli-telemetry
@prisma-next/emitter
@prisma-next/migration-tools
prisma-next
@prisma-next/vite-plugin-contract-emit
@prisma-next/mongo-codec
@prisma-next/mongo-contract
@prisma-next/mongo-value
@prisma-next/mongo-contract-psl
@prisma-next/mongo-contract-ts
@prisma-next/mongo-emitter
@prisma-next/mongo-schema-ir
@prisma-next/mongo-query-ast
@prisma-next/mongo-orm
@prisma-next/mongo-query-builder
@prisma-next/mongo-lowering
@prisma-next/mongo-wire
@prisma-next/sql-contract
@prisma-next/sql-errors
@prisma-next/sql-operations
@prisma-next/sql-schema-ir
@prisma-next/sql-contract-psl
@prisma-next/sql-contract-ts
@prisma-next/sql-contract-emitter
@prisma-next/sql-lane-query-builder
@prisma-next/sql-relational-core
@prisma-next/sql-builder
@prisma-next/target-postgres
@prisma-next/target-sqlite
@prisma-next/adapter-postgres
@prisma-next/adapter-sqlite
@prisma-next/driver-postgres
@prisma-next/driver-sqlite
commit: |
Linked issue
Refs TML-2763
At a glance
{ "from": "sha256:41700ef5fda97339b39ea345a56aae72a1ff4be11ddc3ffcab7130bfc71c109d", "to": "sha256:50aadcf996213451cd2876e3caf50c2752b5b8c9ce1aa55dcae24918518b4ffb", "providedInvariants": [] }ops.jsonfor this migration is[], so this advances the telemetry backend contract marker without running SQL.Summary
The telemetry-backend deploy failed because production was at the previous contract storage hash and the current emitted contract had no migration graph edge from that marker. This PR adds the missing zero-operation migration edge so
prisma-next migratecan reach the current contract during deploy.Decision
This PR ships a no-op app-space migration package for
apps/telemetry-backendthat links the production marker hash41700e…to the current contract hash50aadcf…. The migration includes start/end contract snapshots, an attestedmigration.json, and an emptyops.json.How it fits together
sha256:41700ef5fda97339b39ea345a56aae72a1ff4be11ddc3ffcab7130bfc71c109d.sha256:50aadcf996213451cd2876e3caf50c2752b5b8c9ce1aa55dcae24918518b4ffb.prisma-next migrateonly replays planned graph edges; it does not invent an edge between those hashes at deploy time.apps/telemetry-backend/migrations/app/20260601T1347_contract_hash_advance/records the missing edge with no operations, allowing the deploy workflow to advance the stored marker.Behavior changes & evidence
41700e…to50aadcf…, avoiding theMIGRATION.PATH_UNREACHABLEfailure seen in deploy.prisma-next migration check --json,prisma-next migration list --jsonNotes for the reviewer
ops.jsonis empty, so no tables or indexes are changed.start-contract.*/end-contract.*) required for the migration package shape..envfile was present under/home/aqrln.guestandDATABASE_URLis not set in the shell. Runningpnpm --dir apps/telemetry-backend run migratefails before connecting withDATABASE_URL must be set.Testing performed
DATABASE_URL=postgres://postgres:postgres@localhost:5432/postgres pnpm --filter @prisma-next/telemetry-backend exec prisma-next migration check --jsonDATABASE_URL=postgres://postgres:postgres@localhost:5432/postgres pnpm --filter @prisma-next/telemetry-backend exec prisma-next migration list --jsonpnpm --dir apps/telemetry-backend run migrate— failed before connecting becauseDATABASE_URLis not set and no.envfile exists in this workspace.Skill update
n/a — migration artifact only; no user-facing CLI/API/skill surface changed.
Alternatives considered
Checklist
git commit -s) per the DCO. The DCO status check will block merge if any commit is missing aSigned-off-by:trailer.n/aif the change is doc-only / refactor with no behavioural delta).TML-NNNN: <sentence-case title>form (Linear ticket prefix + concise title naming the concrete deliverable). See.claude/skills/create-pr/SKILL.mdfor the full convention.n/a — internal only).