coleam00/Archon · error · Error
--adopt and ${conflicts.join('/')} are mutually exclusive.
Error message
--adopt and ${conflicts.join('/')} are mutually exclusive.
Adoption resolves its own lane: reuse the adopted worktree, or cut a fresh one from its branch. What it means
The workflow-start preflight rejects `--adopt` when any of `--resume`, `--branch`, `--from/--from-branch`, `--base`, or `--no-worktree` is also present. Adoption resolves its own worktree lane (it reuses the adopted run's worktree or cuts a fresh one from that run's branch), so worktree-lane flags have nothing to apply to.
Source
Thrown at packages/cli/src/commands/workflow.ts:1864
if (options.resume && options.inputs !== undefined && options.inputs.length > 0) {
throw new Error(
'--resume and --input are mutually exclusive.\n' +
" A resume replays the original invocation's inputs, recorded on the run.\n" +
' Drop --input to resume, or start a fresh run to supply different values.'
);
}
// Between-run continuation (#2747): adoption dictates the lane itself, so the
// lane-choosing flags are refused rather than silently overridden.
if (options.adoptRunId !== undefined) {
const conflicts: string[] = [];
if (options.resume) conflicts.push('--resume');
if (options.branchName !== undefined) conflicts.push('--branch');
if (options.fromBranch !== undefined) conflicts.push('--from/--from-branch');
if (options.baseBranch !== undefined) conflicts.push('--base');
if (options.noWorktree) conflicts.push('--no-worktree');
if (conflicts.length > 0) {
throw new Error(
`--adopt and ${conflicts.join('/')} are mutually exclusive.\n` +
' Adoption resolves its own lane: reuse the adopted worktree, or cut a fresh one from its branch.'
);
}
} else if (options.supersedesRunId !== undefined && options.resume) {
throw new Error(
'--supersedes records a FRESH-lane rerun as replacing a prior open item; it cannot be combined with --resume.'
);
}
// Per-dispatch --base override, normalized once. Wins over repo config + the
// codebase default for both the worktree cut-from (the provider request's
// `baseOverride` below) and the PR target / $BASE_BRANCH (executeWorkflow's
// `baseOverride` opt). Both halves need their own channel: the `baseBranch`
// field on either side is the codebase-default FALLBACK and ranks below repo
// config, so routing the flag through it would silently lose to a repo that
// sets `worktree.baseBranch`.
const flagBase = options.baseBranch?.trim() || undefined;View on GitHub (pinned to 0773b97458)
Solutions
- Remove the conflicting worktree-lane flag(s); adoption decides the lane itself.
- If you need explicit control over branch/base, don't use `--adopt` — start a normal fresh run with those flags.
Example fix
// before archon workflow start code-review --adopt run_123 --base main // after archon workflow start code-review --adopt run_123
Defensive patterns
Strategy: validation
Validate before calling
const laneFlags = ['--resume','--branch','--from','--from-branch','--base','--no-worktree'];
if (args.includes('--adopt') && args.some(a => laneFlags.includes(a))) {
throw new Error('--adopt resolves its own worktree lane; remove the conflicting flag.');
} Prevention
- Treat --adopt as a self-contained lane selector.
- Only combine --adopt with flags unrelated to worktree/branch selection.
When it happens
Trigger: `archon workflow start <name> --adopt <runId>` combined with any of `--resume`, `--branch`, `--from`, `--base`, or `--no-worktree`.
Common situations: Templated scripts that append standard worktree flags to every invocation; trying to steer the adopted run's branch with `--branch` or `--base`.
Understand the failure class
Background: "mutually exclusive" flag errors: what "can't supply both nx and xx", "--raw is not compatible with -i" and "cannot be used with" mean, and how to fix them — this error's family across 29 libraries.
Related errors
- --base has no effect with --no-worktree. Remove --base or dr
- --resume and --branch are mutually exclusive. --resume reu
- Workflow '${workflow.name}' sets worktree.enabled: false (ru
- Workflow '${workflow.name}' sets worktree.enabled: false (ru
- Workflow '${workflow.name}' sets worktree.enabled: false (ru
AI-assisted analysis of coleam00/Archon@0773b97458 (2026-09-01).
Data as JSON: /api/errors/03d1c9869bd2190c.
Report an issue: GitHub.