affaan-m/ECC · error
The all/* harness selection cannot be combined with other…
Error message
The all/* harness selection cannot be combined with other selections
What it means
normalizeHarnessSelection treats 'all' and '*' as wildcards that select every guided harness, and rejects combining a wildcard with explicit harness tokens since that is ambiguous (explicit tokens would be redundant or contradictory). The error message states the constraint directly.
Solutions
- Use just 'all' (or '*') when you want every guided harness.
- List only the explicit harnesses you need, without the wildcard.
- In scripts, choose one mode: either expand 'all' yourself or pass an explicit list, not both.
- Sanitize combined inputs before calling the installer by de-duplicating: if 'all' is present, drop explicit tokens.
Example fix
// before
normalizeHarnessSelection('all,codex'); // throws
// after
const tokens = String(input).split(',').map(t => t.trim()).filter(Boolean);
const sel = tokens.includes('all') || tokens.includes('*') ? 'all' : tokens.join(',');
normalizeHarnessSelection(sel); Defensive patterns
Strategy: validation
Validate before calling
const tokens = String(selection || '').split(',').map(t => t.trim()).filter(Boolean);
const hasAll = tokens.some(t => ['all', '*'].includes(t.toLowerCase()));
if (hasAll && tokens.length > 1) {
throw new Error('Pass either "all" or an explicit harness list, not both');
} Try / catch
try {
const ids = normalizeHarnessSelection(selection);
} catch (e) {
if (/all\/\* harness selection cannot be combined/.test(e.message)) {
console.error('Use "all" alone, or list explicit harnesses without the wildcard.');
process.exitCode = 2;
return;
}
throw e;
} Prevention
- Normalize selections before invoking: if a wildcard is present, drop explicit tokens.
- Avoid building harness lists by naive string concatenation in scripts/CI.
- Document in the installer help that 'all'/'*' is exclusive of other values.
When it happens
Trigger: Calling the installer with a selection like 'all,claude-code', '*,cursor', or an array ['all', 'codex'] — any mix of wildcard and explicit tokens.
Common situations: Users trying to say 'all of these plus that one extra'; CI templates where a default 'all' is concatenated with a user-specified list; shell scripts appending flags and ending up with '--harnesses all,codex'.
Related errors
- At least one guided harness must be selected
- Legacy language arguments cannot be combined with…
- --locale can only be used with --target claude or --target…
- --no-hooks cannot be combined with an explicit…
- all overlays must be readable local files
AI-assisted analysis of affaan-m/ECC@8321021c54 (2026-09-16).
Data as JSON: /api/errors/1a42aecfad6d74fb.
Report an issue: GitHub.
Appendix: source
Thrown at scripts/lib/harness-capabilities.js:337
}
function tokenizeSelection(selection) {
const values = Array.isArray(selection) ? selection : [selection];
return values.flatMap(value => (
typeof value === 'string' ? value.split(',') : []
)).map(value => value.trim()).filter(Boolean);
}
function normalizeHarnessSelection(selection) {
const tokens = tokenizeSelection(selection);
if (tokens.length === 0 || tokens.every(token => normalizeLookupToken(token) === 'none')) {
throw new Error('At least one guided harness must be selected');
}
const allTokens = tokens.filter(token => ['all', '*'].includes(normalizeLookupToken(token)));
const explicitTokens = tokens.filter(token => !['all', '*'].includes(normalizeLookupToken(token)));
if (allTokens.length > 0 && explicitTokens.length > 0) {
throw new Error('The all/* harness selection cannot be combined with other selections');
}
if (allTokens.length > 0) {
return GUIDED_HARNESS_IDS.slice();
}
const selected = new Set();
for (const token of tokens) {
const normalizedToken = normalizeLookupToken(token);
const menuIndex = /^\d+$/.test(normalizedToken) ? Number(normalizedToken) - 1 : -1;
const harness = menuIndex >= 0
? listGuidedHarnesses()[menuIndex] || null
: getHarnessCapability(token);
if (!harness) {
throw new Error(`Unknown guided harness selection: ${token}`);
}
if (!harness.guidedReady) {
throw new Error(`${harness.label} is an advanced harness and is not guided-ready`);View on GitHub (pinned to 8321021c54)