Skip to content

feat(coordinator): add the Project move log and its contract - #3071

Merged
kunickiaj merged 1 commit into
mainfrom
feat/project-moves-contract
Nov 29, 2026
Merged

kunickiaj merged 1 commit into
mainfrom
feat/project-moves-contract

Conversation

@kunickiaj

@kunickiaj kunickiaj commented Nov 29, 2026 •

Copy link
Copy Markdown
Owner

Description

Each shared Project moves from its older scope (team, team_default, org, client) to its own managed_project boundary, the mechanism new shares already use (ADR 0007 Decision 2). This PR adds the coordinator's log of those moves and the contract the coordinator, the admin device and the other devices follow. Nothing writes the log yet.

  • Migration 0058 adds coordinator_project_moves: one row per boundary with the older scope, the admin device that asked, the devices granted, the devices the admin device excluded and the time. Triggers refuse every update and delete, so a move is one-way and the log only grows.
  • docs/contracts/coordinator-project-moves.md sets out the trust model, the move request and its answers (including the devices the admin device excludes and the Team removal sequence it built that list from), the version gate (every authorized member of the older scope lists project_boundary_migration_v1 in its presence), the "Unassigned" identity for memories with no Project, and the signed read a device uses to learn its Project moved.
  • SQLite installs the same storage on startup. The migration is registered in the D1 inventory, the baseline, the post-stage readiness map and the historical fixtures.

Type of Change

  • 🚀 Feature (new functionality)
  • 🐛 Bug fix (fixes an issue)
  • 📚 Documentation (docs-only change)
  • 🔧 Maintenance (refactor, chore, CI, etc.)
  • 🧪 Testing (test-only changes)

Testing

  • New tests check that the migration file and the Worker schema match the shared SQL, that the storage reports itself present only with its table and triggers, that a logged move can't be changed or deleted, and that each older scope gets its own Unassigned boundary.

  • Targeted coordinator store, D1 baseline, inventory and schema-stage suites pass. pnpm run tsc and the Biome ratchet pass. The full suite runs in CI.

  • Relevant checks pass locally (pnpm run tsc, pnpm run lint, pnpm run test)

  • Added/updated tests for changes

  • Manually verified changes work as expected

Checklist

  • Code follows project style (pnpm run lint passes for touched files)
  • Self-review completed
  • Documentation updated (if needed)
  • No new warnings introduced

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 29, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-29T03:53:38.396446Z f13948e New commits
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

Every shared Project moves from its older scope to its own managed_project boundary, once and one-way. Migration 0058 adds the coordinator's move log: one row per boundary with the older scope, the admin device that asked and the devices granted. Triggers refuse every update and delete.

docs/contracts/coordinator-project-moves.md fixes the trust model, the admin move request and its answers, the version gate (every authorized member of the older scope lists project_boundary_migration_v1 in presence), the Unassigned identity for memories with no Project, and the device-signed read that tells a device its Project moved. No route or writer uses the storage yet.
@kunickiaj
kunickiaj force-pushed the feat/project-moves-contract branch from 056d907 to f13948e Compare November 29, 2026 03:52
@kunickiaj kunickiaj mentioned this pull request Nov 29, 2026
8 of 12 tasks
@kunickiaj
kunickiaj merged commit 3402ff5 into main Nov 29, 2026
23 checks passed
@kunickiaj
kunickiaj deleted the feat/project-moves-contract branch November 29, 2026 04:09
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