Remove Neon-only identity resolver: Motion-web identity resolves from the local daemon DB - #134
Merged
Merged
Conversation
add-roles-permissions v3.3.0 + team-member-memory v3.2.0. Motion-web identity now resolves from /daemon/conversation-store/conversations.db via the runtime-injected CONVERSATION_ID — no NEON_DATABASE_URL, no production credentials at install time. Resolution logic matches the compatibility resolver proven on the customer fleet in the June 10-11 rollout (SHA 946bfa2a), adapted to the repo's organization-map.json naming and home-base paths. Fail-loud semantics kept for permissions; graceful unresolved semantics kept for team-member-memory. Refs: 2026-06-11 NEON_DATABASE_URL incident, PDEC-7817. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Public repo — changelog text should describe the change (local daemon-DB resolution, no install-time secrets), not internal incident details. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
kyra-cpu
marked this pull request as ready for review
June 12, 2026 13:36
This was referenced Jun 12, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
Repo/fleet divergence. The June 2026 runtime change shipped a local daemon conversation store (
/daemon/conversation-store/conversations.db+ a$CONVERSATION_IDenv var), and the fleet's resolvers were re-pointed at it in the June 10–11 rollout — Motion-web identity now resolves locally, no runtime secrets needed. This repo's install path was never updated to match: it still required a runtime database secret at install time. A fresh install should never prompt for a database credential. This PR brings the repo in line with the fleet.What changed
add-roles-permissionsv3.1.5 → v3.3.0 (v3.2.0 is claimed by #115 — attribution removal; no rebase needed, the diffs don't overlap on the resolver)SKILL.mdPhase 5 Step 4: the embedded Neonmotion-whoami.sh+motion-whoami-neon.pyhelper are replaced with a single daemon-DB resolver. A leftover-helper cleanup instruction is included for upgrades.sqlite3available" — both on every current VM by default — and a miss warns instead of blocking (outdated image; Motion-web users resolve as unknown until the runtime is updated).README.md: prerequisites drop the runtime secret, addsqlite3; identity-resolution description updated ("local daemon conversation store, no runtime secrets required").use-case.json/install-config.json: no secret declarations existed; only the version bump.team-member-memoryv3.1.0 → v3.2.0motion-whoami.sh: same resolver swap. Softer failure semantics kept (6/2 decision): any lookup failure returnsstatus: "unresolved"with exit 0, and the behavior-snippet asks the user where to save instead of guessing a handle.motion-whoami-neon.pydeleted; removed from theinstall-config.jsoninstall list.behavior-snippet.md+README.mdupdated to describe the daemon-DB path. Home bases stay at/agent/brain/identity/people/(the v3.1.0 path migration is respected).slack-whoami.shuntouched — it never used Neon.Provenance of the resolver
The script was not reconstructed from memory. The resolver deployed across the fleet in the June 10–11 rollout (compatibility variant) was reproduced byte-for-byte from the rollout records and verified against the recorded hash:
The version shipped here differs from that byte-proven script in exactly three ways (verified by diff — all resolution logic is identical):
organization-map.json/RUNNETH_ORG_MAP(repo convention since add-roles-permissions: organization-map rename + Neon-only motion-whoami #98) instead of the fleet'sworkspace-map.json/RUNNETH_WORKSPACE_MAP. The use case scaffoldsorganization-map.json, and the resolver must read the file the use case writes./agent/brain/team/(permissions, per v3.1.3 rename) and/agent/brain/identity/people/(team-member-memory, per its v3.1.0 migration) instead of the fleet's/agent/brain/members/.The compat behavior is included: reads
.motionUserEmailswith legacy.motionEmailsfallback, and keeps both maps in sync on provision — strictly safer for upgrades from older installs.Local verification done
bash -npasses on both resolvers (the SKILL.md-embedded one was extracted and checked).conversations.db: resolved viamotionUserEmails✓, resolved via legacymotionEmails✓, auto-provision writes both maps + scaffolds home base ✓, missingCONVERSATION_ID→ error JSON + exit 1 (permissions) /unresolved+ exit 0 (tmm) ✓, missing daemon DB → fail-loud (permissions) /unresolved(tmm) ✓.agent_conversation, nosecret run, no/agent/.runtime/conversations.dboutside changelog history;daemon/conversation-store+CONVERSATION_IDpresent in all the right places.Still to do before merge (needs VM access)
$CONVERSATION_IDmay not be set in all invocation contexts (jobs/routines); daemon DB may not exist on older images;sqlite3 -readonly -jsonneeds a recent sqlite3. team-member-memory degrades gracefully on all three; add-roles-permissions fails loud by design.set -ekills it first). Still fail-loud; kept as-is to match fleet behavior.Out of scope
Refs: PDEC-7817
🤖 Generated with Claude Code