What happened
After uninstalling a prior tool (Aperant / Auto-Claude, which shares the ~/.archon/workspaces/ directory layout), my first archon workflow run in a fresh git repo failed with:
{"err":{"type":"Error","message":"Source symlink at C:\Users\<user>\.archon\workspaces\<org>\<repo>\source already points to C:\Users\<user>\.archon\workspaces\<repo>, expected C:/dev/<repo>"}...}
Error: Cannot create worktree: not in a git repository.
Run from within a git repo, or use --no-worktree to skip isolation.
The repo is a valid git repository. The real cause was a stale <org>/<repo>/source symlink pointing to a leftover workspace snapshot (~/.archon/workspaces/<repo>/, ~34MB of files from the prior tool).
Problems
- The secondary "Cannot create worktree: not in a git repository" error is misleading — it implies a git-detection failure when the root cause is registration bailing before git even gets consulted.
- No self-heal path. Nothing in the error suggests recovery. A user has to read the stack trace, locate
createProjectSourceSymlink (packages/paths/src/archon-paths.ts), and manually rm -rf ~/.archon/workspaces/<org>/<repo>/ (and usually the stale target too) to unblock.
- Discoverability is poor.
archon isolation list doesn't show the broken entry as broken — it appears fine until a workflow is actually run.
Reproduction
- Have a stale workspace dir from any prior tool sharing the
~/.archon/workspaces/ layout (or any leftover symlink at <org>/<repo>/source pointing to an unexpected target).
- Run
archon workflow run <any-workflow> --branch <name> "<msg>" from a valid git repo whose derived name collides.
- Observe the error above.
Suggested fixes (any one helps)
- Detect stale-target symlink and auto-repoint when the old target no longer exists (or matches the current repo root).
- Add
archon isolation repair <name> or a --repair flag that deletes the broken registration and re-creates it.
- Suppress the secondary "not in a git repository" line when the true cause was a registration failure earlier in the chain.
- Include the
rm -rf ~/.archon/workspaces/<org>/<repo>/ recovery hint directly in the error message body.
Environment
- Archon CLI v0.3.6 (source build)
- Windows 11 Pro, build 10.0.26200
- bun runtime, MINGW64 (Git Bash)
- Prior tool that created the collision: Aperant / Auto-Claude (uninstalled before filing)
What happened
After uninstalling a prior tool (Aperant / Auto-Claude, which shares the
~/.archon/workspaces/directory layout), my firstarchon workflow runin a fresh git repo failed with:The repo is a valid git repository. The real cause was a stale
<org>/<repo>/sourcesymlink pointing to a leftover workspace snapshot (~/.archon/workspaces/<repo>/, ~34MB of files from the prior tool).Problems
createProjectSourceSymlink(packages/paths/src/archon-paths.ts), and manuallyrm -rf ~/.archon/workspaces/<org>/<repo>/(and usually the stale target too) to unblock.archon isolation listdoesn't show the broken entry as broken — it appears fine until a workflow is actually run.Reproduction
~/.archon/workspaces/layout (or any leftover symlink at<org>/<repo>/sourcepointing to an unexpected target).archon workflow run <any-workflow> --branch <name> "<msg>"from a valid git repo whose derived name collides.Suggested fixes (any one helps)
archon isolation repair <name>or a--repairflag that deletes the broken registration and re-creates it.rm -rf ~/.archon/workspaces/<org>/<repo>/recovery hint directly in the error message body.Environment