Skip to content

fix(agents): pass multi-root sources to Chat, Loop, and Graph - #756

Merged
im-ian merged 1 commit into
mainfrom
fix/multiroot-native-agent-sources
Aug 6, 2026
Merged

fix(agents): pass multi-root sources to Chat, Loop, and Graph#756
im-ian merged 1 commit into
mainfrom
fix/multiroot-native-agent-sources

Conversation

@im-ian

@im-ian im-ian commented Aug 6, 2026

Copy link
Copy Markdown
Owner

Summary

Ensure Claude Code and Codex receive every source root in a multi-root project across terminal and native agent sessions.

  1. Shared root resolution — reuse one sibling-root resolver for PTY and native execution paths.
  2. Native agent coverage — pass additional roots through Chat, Loop, and Graph adapters as attached --add-dir arguments.
  3. Provider scoping — keep Antigravity, Grok, Ollama, LLM, and custom provider arguments unchanged.
  4. Regression coverage — verify spaces and colons in direct CLI path arguments plus primary/source root symmetry.

Expected impact

Flow Before After
Terminal Claude/Codex All project roots visible All project roots visible
Chat / Loop Claude/Codex Starting root only All project roots visible
Graph Claude/Codex Starting root only All project roots visible
Other providers Starting root only Unchanged

Design notes

  • Native CLI invocations receive typed path arguments directly instead of reusing the colon-delimited PTY environment representation.
  • Codex source flags stay before the exec subcommand, matching the existing wrapper contract.
  • Graph retries and human-input continuations clone the same additional-root set as the original executor.

Test plan

  • cargo test --manifest-path src-tauri/Cargo.toml commands::tests::chat_cli_invocation -- --test-threads=1 — 9 passed
  • cargo test --manifest-path src-tauri/Cargo.toml commands::tests::source_dirs_env_lists_only_the_session_root_siblings -- --test-threads=1 — 1 passed
  • cargo test --workspace --manifest-path src-tauri/Cargo.toml -- --test-threads=1 with Acorn control-session environment overrides removed — passed
  • git diff --check — passed

@im-ian im-ian added the fix Bug fix label Aug 6, 2026
@im-ian

im-ian commented Aug 6, 2026

Copy link
Copy Markdown
Owner Author

Merge readiness note: this PR is technically mergeable now.

  • GitHub reports MERGEABLE / CLEAN.
  • CI is green: Frontend, E2E (shard 1/2), and E2E (shard 2/2) passed.
  • Self-review is complete with no blocking findings.
  • fix label is applied.

Proceeding to merge because the user explicitly requested the reviewed release fixes to be merged.

@im-ian
im-ian merged commit 1214d7f into main Aug 6, 2026
3 checks passed
@im-ian
im-ian deleted the fix/multiroot-native-agent-sources branch August 6, 2026 00:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

fix Bug fix

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant