Skip to content

refactor: group shared journal and request contracts - #36882

Merged
nwparker merged 1 commit into
mainfrom
module-organization/pr54-pr55-session-journal-requests
Nov 1, 2026
Merged

nwparker merged 1 commit into
mainfrom
module-organization/pr54-pr55-session-journal-requests

Conversation

@nwparker

@nwparker nwparker commented Nov 1, 2026 •

Copy link
Copy Markdown
Contributor

ELI5

Organize shared chat journal and request contracts into their owning folders. Preserve the same queue, send, and journal behavior.

What Changed

Move 34 existing files into src/shared/agent-session/journal/ and src/shared/agent-session/requests/, updating desktop, server, CLI, mobile, tests and validation scripts atomically. Import concrete defining owners, removing existing forwarding exports. No barrels, forwarding shims or convenience aliases added.

Preserve runtime bodies, wire/storage values, namespace identity, mock targets, five timing values and historical released-source paths. Keep all active CI routing after the moves. Add the existing reliability schema’s currentCommand field to map the relocated test command while preserving its historical executed command and result. Remove an obsolete type-only import and the journal-store error forwarder, directing its sole test consumer to the defining owner. Move the complete projection turn-verdict test group to its own discovered test file so import growth stays within the existing line budget.

Why

Make related contracts easier to locate and review in one coherent ownership batch. This continues the maintainer-requested module organization sequence with larger PRs.

Linked Issue

Maintainer-requested cleanup sequence; no separate issue linked.

Visual Proof

N/A — module organization preserves rendered behavior and interactions.

Testing

  • 403 focused test executions pass across 19 suite runs on macOS (396 reused from prior validated phases plus seven retained-suite tests rerun after rebasing), covering moved contracts, journal recovery, projection verdicts, namespace/mocks, queue cards, CI routing and mixed-version loading.
  • Full-file lint, formatting, import boundaries, test discovery and line-limit ratchet pass.
  • Root and mobile typechecks and changed-code quality pass; Node typecheck and test discovery pass again on the refreshed source.
  • Two independent final-source audits pass.
  • All nine hosted PR workflows pass; actual squash parent, tree and preservation proof match the independent reviews.

The rebase retains the 31 suites deleted upstream by #36877 and its edits to retained tests; no deleted suite is recreated. Existing tests move with their owners; no behavior change needs new assertions. One original settlement helper test was deliberately deleted upstream in #33778 and remains absent. Its reviewed retirement receives zero move credit; detailed evidence remains local.

AI Disclosure

Internal contributor; section not applicable under the repository template.

Review

Two independent full source audits and bounded reviews of each main advance pass. All nine hosted PR workflows pass. The actual squash matches the independently reviewed parent and tree, and the unmodified merge-preservation gate passes. CodeRabbit skips this 1,191-file change because its limit is 300 files; both native audits cover the full scope. Later upstream test cleanups remain preserved, including the 39 suites deleted by #36901.

Agent skill upstream boundary

  • Not applicable; no upstream skill-installer material copied or translated.

Notes

Desktop, mobile, remote and mixed-version behavior retained. No platform-specific behavior changes. Existing feature and history holds remain. Local evidence and planning files are excluded from the commit.

Checklist

  • Coherent journal/request ownership batch.
  • Explained what changed and why.
  • Visual proof marked N/A with reason.
  • Cross-platform, remote and mobile impact considered.
  • Final self-review and independent source audits complete.
  • All applicable checks passed before merge.

@nwparker
nwparker force-pushed the module-organization/pr54-pr55-session-journal-requests branch from d6dd84b to 1421ab2 Compare November 1, 2026 04:03
@nwparker
nwparker force-pushed the module-organization/pr54-pr55-session-journal-requests branch from 1421ab2 to fd8d8a3 Compare November 1, 2026 04:28
@nwparker
nwparker merged commit 7d76028 into main Nov 1, 2026
135 of 137 checks passed
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