agent-orchestrator/packages/plugins
Harshit Singh Bhandari e465a4702d
fix(agent-claude-code): fold underscores in Claude project slug (#1611) (#1612)
`toClaudeProjectPath` only normalized `/`, `.`, and `:` — but Claude Code's
on-disk slug also folds underscores (and other non-alphanumerics) to `-`.
AO project data dirs are named `<sanitized>_<hash>` (e.g.
`graph-isomorphism_d185b44d56`), so the slug AO computed pointed at a
directory that never existed. Cascading failures:

- `getSessionInfo` couldn't read the JSONL → `claudeSessionUuid` never
  got persisted to session metadata.
- On restore, `getRestoreCommand`'s metadata lookup found nothing AND its
  workspace-scan fallback also missed (same bad slug), returning `null`.
- Session-manager's native-restore guard then threw
  `SessionNotRestorableError` → API returned 409.

Verified on-disk: every session under projects without underscores has
`claudeSessionUuid` persisted; every session under projects with
underscores does not. The orchestrator angle in #1611 is the loudest
symptom — orchestrators die early so they have nothing else to fall back
on — but the same bug silently broke worker restore in any multi-project
setup.

Fix: replace `[/.]` with `[^a-zA-Z0-9-]` in the slug regex, matching
Claude Code's actual encoding. Adds direct unit tests for
`toClaudeProjectPath` covering the underscore case plus existing paths,
and a regression test in the `getSessionInfo` path-conversion suite.

Fixes #1611.

Co-authored-by: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-03 20:40:18 +05:30
..
agent-aider chore: align workspace package.json versions with npm registry (#1587) 2026-05-01 15:31:04 +05:30
agent-claude-code fix(agent-claude-code): fold underscores in Claude project slug (#1611) (#1612) 2026-05-03 20:40:18 +05:30
agent-codex Fix native restore fallback for Claude and Codex sessions (#1602) 2026-05-01 21:27:17 +05:30
agent-cursor chore: align workspace package.json versions with npm registry (#1587) 2026-05-01 15:31:04 +05:30
agent-kimicode feat(plugin): implement kimicode agent plugin (#1390) 2026-05-01 14:11:30 +05:30
agent-opencode chore: align workspace package.json versions with npm registry (#1587) 2026-05-01 15:31:04 +05:30
notifier-composio chore: align workspace package.json versions with npm registry (#1587) 2026-05-01 15:31:04 +05:30
notifier-desktop chore: align workspace package.json versions with npm registry (#1587) 2026-05-01 15:31:04 +05:30
notifier-discord chore: align workspace package.json versions with npm registry (#1587) 2026-05-01 15:31:04 +05:30
notifier-openclaw chore: align workspace package.json versions with npm registry (#1587) 2026-05-01 15:31:04 +05:30
notifier-slack chore: align workspace package.json versions with npm registry (#1587) 2026-05-01 15:31:04 +05:30
notifier-webhook chore: align workspace package.json versions with npm registry (#1587) 2026-05-01 15:31:04 +05:30
runtime-process chore: align workspace package.json versions with npm registry (#1587) 2026-05-01 15:31:04 +05:30
runtime-tmux chore: align workspace package.json versions with npm registry (#1587) 2026-05-01 15:31:04 +05:30
scm-github fix(scm-github): silence HTTP 304 warnings in ETag guards (#1581) 2026-05-03 18:30:27 +05:30
scm-gitlab chore: align workspace package.json versions with npm registry (#1587) 2026-05-01 15:31:04 +05:30
terminal-iterm2 chore: align workspace package.json versions with npm registry (#1587) 2026-05-01 15:31:04 +05:30
terminal-web chore: align workspace package.json versions with npm registry (#1587) 2026-05-01 15:31:04 +05:30
tracker-github chore: align workspace package.json versions with npm registry (#1587) 2026-05-01 15:31:04 +05:30
tracker-gitlab chore: align workspace package.json versions with npm registry (#1587) 2026-05-01 15:31:04 +05:30
tracker-linear chore: align workspace package.json versions with npm registry (#1587) 2026-05-01 15:31:04 +05:30
workspace-clone chore: align workspace package.json versions with npm registry (#1587) 2026-05-01 15:31:04 +05:30
workspace-worktree chore: align workspace package.json versions with npm registry (#1587) 2026-05-01 15:31:04 +05:30