Skip to content

Add mcp_assets Drizzle migration - #50

Closed
eliteprox wants to merge 4 commits into
mainfrom
feat/mcp-assets-schema
Closed

Add mcp_assets Drizzle migration#50
eliteprox wants to merge 4 commits into
mainfrom
feat/mcp-assets-schema

Conversation

@eliteprox

@eliteprox eliteprox commented Sep 5, 2026

Copy link
Copy Markdown
Collaborator

Summary

Schema-only. Adds the mcp_assets table (principal-scoped media URLs for MCP/history joins) via Drizzle so later PRs can query it without shipping DDL in app code.

  • db/schema.ts + drizzle/0000_warm_hellfire_club.sql (CREATE TABLE IF NOT EXISTS + indexes)
  • drizzle-orm / drizzle-kit and pnpm db:generate / pnpm db:migrate
  • No store, MCP, or query changes
  • No GitHub Actions / ignoreCommand — that moved to Add production GitHub deploy (migrate then Vercel) #52

No foreign keys. principal_id is an opaque eu_… string, not a waitlist/EA user UUID. Unique is (gateway_request_id, url) only.

Safe to run on the shared production/preview Neon fork: IF NOT EXISTS matches the table already created by ensureSchema. Do not run pnpm db:migrate against waitlist primary main (br-wild-boat-auv00x69); that journal already owns 0000–0004.

Follow-up: #47.
Replaces the broader #49.

Test plan

  • pnpm typecheck / pnpm lint
  • Confirm this PR does not change lib/mcp/ or runtime query paths
  • Confirm no FKs on mcp_assets (live waitlist table and this SQL)
  • Merge Add production GitHub deploy (migrate then Vercel) #52 first (or immediately after), then enable VERCEL_PRODUCTION_AUTO_DEPLOY
  • pnpm db:migrate against the shared fork only; waitlist primary journal stays at 0000–0004

Move table creation out of request-time DDL so follow-up PRs can query
the table without owning schema or rewriting MCP/store code.
@vercel

vercel Bot commented Sep 5, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
console Ready Ready Preview Sep 5, 2026 5:22am UTC

Request Review

Skip native Git production builds so schema is applied with pnpm
db:migrate before vercel build --prod / deploy --prebuilt, matching
the PymtHouse path and keeping preview Git deploys.
The initial migration is a no-op on production (same unique and
indexes) so we do not need a follow-up ALTER.
Schema and drizzle journal stay here; Actions plus ignoreCommand live
in the dedicated deploy workflow PR.
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