Skip to content

refactor(agent-manager): organize Claude provider code - #198

Merged
codeaholicguy merged 4 commits into
mainfrom
feature-claude-provider-refactor
Aug 25, 2026
Merged

refactor(agent-manager): organize Claude provider code#198
codeaholicguy merged 4 commits into
mainfrom
feature-claude-provider-refactor

Conversation

@codeaholicguy

Copy link
Copy Markdown
Owner

Summary

  • Move Claude adapter, parser, session locator/mapper, and durable print-mode implementation under providers/claude
  • Remove no-value Claude wrapper re-exports
  • Narrow agent-manager root exports to high-level public APIs
  • Add focused provider-local tests and update lifecycle docs

Validation

  • npm run nx -- test agent-manager
  • npm run typecheck, npm run lint, and npm run build in packages/agent-manager
  • pre-commit full workspace lint/test passed

Risk

  • Public package root remains stable for high-level APIs, but lower-level Claude probe/runner and process helpers are no longer exported from src/index.ts.

codeaholicguy and others added 4 commits August 23, 2026 17:23
…cator rationale

The Claude provider reorganization left three private delegation methods on
ClaudeCodeAdapter (discoverSessions, tryPidFileMatching, getProjectDir) with
no production callers — they existed only so the adapter test suite could keep
reaching them through `(adapter as any)`. Move those 19 tests onto
ClaudeSessionLocator, delete the proxies, and re-narrow tryPidFileMatching and
getProjectDir to private now that nothing outside the locator calls them.

Also carry across the explanatory comments dropped during the extraction: the
PidFileEntry field docs (including why live PID-file status beats JSONL-derived
state), the PID_FILE_STALENESS_MS recycling rationale, the lossy path-encoding
note on getProjectDir, the worktree caveat on discoverHistoricalSessionFiles,
the resume-matching and readMatchingPidFile docs, and the live-status precedence
comment on mapSessionToAgent.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@codeaholicguy
codeaholicguy merged commit 65acd86 into main Aug 25, 2026
7 checks passed
@codeaholicguy
codeaholicguy deleted the feature-claude-provider-refactor branch August 25, 2026 05:44
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