Skip to content

refactor(runtime): migrate session store and tool IO owners#1062

Merged
limityan merged 1 commit into
GCWing:mainfrom
limityan:yanzhn/session-store-runtime-owner
Jun 4, 2026
Merged

refactor(runtime): migrate session store and tool IO owners#1062
limityan merged 1 commit into
GCWing:mainfrom
limityan:yanzhn/session-store-runtime-owner

Conversation

@limityan

@limityan limityan commented Jun 4, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • Move session restore/load request, timing, and storage-path facts into runtime ports/services while keeping the core session-store adapter as the concrete bridge.
  • Move local Write/Edit/Delete/Glob filesystem and search execution primitives into tool-runtime; core keeps the agent-facing Tool adapters, freshness checks, permission admission, checkpoint hooks, and product assembly boundaries.
  • Keep the runtime-ports API minimal by avoiding delivery-shape policy helpers in the shared contracts; desktop keeps its own 16-turn restore-view clamp.
  • Update the core decomposition plan/completed docs to mark PR-2 as complete without changing the target architecture design.

Behavior / Risk

  • Preserves desktop restore response shape, session-view tail clamp behavior, tool-result preview compacting, and startup timing recording.
  • Preserves tool names, schemas, prompt-visible exposure, file-read freshness, workspace-search preference, remote shell fallback, and MCP/ACP catalog behavior.
  • Local blocking filesystem/search primitives run behind blocking tasks when entered from async tool paths.
  • Glob local fallback now matches rg --files --glob files-only behavior for wildcard basename patterns, covering CI environments that take the fallback path.
  • Does not move Bash/terminal lifecycle, indexed workspace search service, remote shell execution, permission Tool handler, checkpoint orchestration, session manager lifecycle, or persistence file IO.

Verification

  • cargo test -p tool-runtime
  • cargo test -p bitfun-runtime-ports
  • cargo test -p bitfun-runtime-services
  • cargo test -p bitfun-agent-tools
  • cargo test --locked -p bitfun-core
  • node scripts/check-core-boundaries.mjs
  • cargo check -p bitfun-core --no-default-features
  • cargo check -p bitfun-core --features product-full
  • cargo check -p bitfun-desktop
  • git diff --check

@limityan
limityan force-pushed the yanzhn/session-store-runtime-owner branch from ca7caaf to 2d2bdfa Compare June 4, 2026 03:45
@limityan limityan changed the title refactor(runtime): migrate session restore store contracts refactor(runtime): migrate session store and tool IO owners Jun 4, 2026
@limityan
limityan force-pushed the yanzhn/session-store-runtime-owner branch from 2d2bdfa to 3f91edc Compare June 4, 2026 04:22
@limityan
limityan merged commit 8bb2921 into GCWing:main Jun 4, 2026
4 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