Repository navigation
test(frontend): pin the attribution cursor as the only session-id source - #85
Merged
Merged
Conversation
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.
What
FE-03 of
tavus-single-session-interview. The attribution cursor, its single mutator and every reader were ALREADY merged (they came with the invisible-competency-handover work):handle.attribution.currentfeeds/end(both sites),/suspend,sessionId, the snapshot, the resize flush and the utterance emit;advanceAttributionflushes unsent integrity events to the outgoing row, then writes the cursor, then sends; the timer-reset watch andProctorOverlay :session-idread the cursor-fedsessionId. So there is no refactor here:app/is unchanged. This PR only PINS the behaviour so FE-04 can build on it safely.attribution-cursor-arch.spec.ts(8 tests):advance()has one call site, in the composable;new AttributionCursoronly in the composable;as AdvanceTicketonly in the cursor module;createBoundaryTicket(referenced only by its own module and the composable;dbSessionIdis read only as a player key; bothProctorOverlay :session-idbindings and the timer-reset watch usesession.sessionId.value.use-interview-session-attribution.spec.ts: the muted tape[u1(A), end, u2(muted window), u3(B)]posts exactly{(A,u1),(B,u3)}; moving the cursor posts no second/endfor A.Notes
/endis never POSTed twice for A" (acompletefollowed by anendQuestiontimer) fails today with 2 POSTs: the shipped HeyGen suite relies on the second POST losing with a 409 (use-interview-session.spec.ts~l.293 and ~l.554). Deduping would change HeyGen behaviour, so only "a cursor move adds no/end" is pinned; real dedupe belongs to FE-04'sassertBoundary().handle.attribution), not one globalcursor.current; equivalent, left as merged.Verification
The arch tests characterise merged code, so RED came from mutations: cursor written after the send (3 tests fail),
/endreadinghandle.dbSessionId(2 fail), a ticket minted inInterviewSession.vue(1 fails),ProctorOverlayreadingsession.dbSessionId(2 fail), each reverted.interview-handover.spec.tsanduse-interview-session.spec.tsunmodified and green. Unit suite 115 files / 2933 tests, coverage 96.18% lines, typecheck exit 0, lint 0 errors, prettier clean; the pre-commit gate (lint-staged andgga) passed.