Repository navigation
Resolve Cowork transcript identity from sidecars - #18
Merged
Merged
Conversation
tadasant
force-pushed
the
fix/cowork-transcript-identity
branch
from
June 4, 2026 18:59
a1a0095 to
0515d2e
Compare
- Remove out-of-scope stop_hook_active early-exit from the capture flow. It is unrelated to identity resolution and risked skipping the final capture when a separate blocking Stop hook is present (breaking the "manifest always reflects latest state" invariant). - Document that manifest.identity is diagnostic metadata not subject to redacted privacy mode (consistent with the rest of manifest.json). - Add a comment clarifying that Cowork identity matching is deliberately stricter than detectAgent's loose substring check. - Add resolver tests for malformed sidecars, missing oauthAccount, and account/organization UUID path mismatches. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
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.
Summary
identityobject; manifest schema bumped to v3) while preserving normal Claude Code fallback behavior.manifest.user_id/manifest.identitysemantics — including thatidentityis diagnostic metadata not subject toredactedprivacy mode — and add resolver coverage for Source A, Source B, mismatch, cwd fallback, non-Cowork, malformed-sidecar, and missing-sidecar cases.Verification
npm install && npm run build && npm testinhooks/agent-transcript-capturepasses locally — 130 tests across 9 files green,tscbuild clean.dist/confirmed in sync withsrc/: a freshnpm run buildproduces no additional diff beyond the committed compiled output.oauthAccountfallback, CLI session-ID mismatch diagnostics, Source A/B email mismatch diagnostics, cwd/outputsfallback detection, non-Cowork host fallback, negativelocal_*ancestor (not misdetected as Cowork), missing-sidecar fallback tocowork-<accountUuid-prefix>, malformed/unparseable sidecars never failing capture, missingoauthAccountdiagnostic, and account/organization UUID path-mismatch diagnostics.git diff --checkclean.stop_hook_activeearly-exit (unrelated to identity, risked skipping the final capture when a separate blocking Stop hook is present), documented thatmanifest.identityis not subject toredactedmode, clarified the stricter Cowork path-matching vsdetectAgent's substring check, and added the malformed-sidecar / missing-oauthAccount/ UUID-mismatch tests above.