ruvnet/RuView · error · RangeError

Unsupported verification profile: ${profile}

Error message

Unsupported verification profile: ${profile}

What it means

runVerification maps args.profile to the PROFILE_COMMANDS table, which defines exactly core, wasm, and hap, plus the special-cased 'full' that concatenates all three. Any other value returns undefined commands and throws this RangeError. Omitting profile is safe (defaults to 'core').

Source

Thrown at harness/homecore/src/tools.js:185

      cargo: executableOnPath('cargo'),
      rustc: executableOnPath('rustc'),
      codex: executableOnPath('codex'),
      claude: executableOnPath('claude'),
    },
  };
}

function commandsForProfile(profile) {
  if (profile === 'full') {
    return [...PROFILE_COMMANDS.core, ...PROFILE_COMMANDS.wasm, ...PROFILE_COMMANDS.hap];
  }
  return PROFILE_COMMANDS[profile];
}

export async function runVerification(args = {}, context = {}) {
  const profile = args.profile || 'core';
  const commands = commandsForProfile(profile);
  if (!commands) throw new RangeError(`Unsupported verification profile: ${profile}`);
  const root = resolveRepo(args.repo, context);
  if (!root) throw new Error('A trusted RuView checkout is required; pass repo.');
  const timeoutMs = args.timeout_ms || 900_000;
  const runner = context.runner || runProcess;
  const results = [];
  for (const commandArgs of commands) {
    const result = await runner('cargo', commandArgs, {
      cwd: root,
      timeoutMs,
      signal: context.signal,
      maxOutputBytes: 2_097_152,
    });
    results.push({
      command: ['cargo', ...commandArgs],
      code: result.code,
      stdout: result.stdout,
      stderr: result.stderr,
      truncated: result.truncated,

View on GitHub (pinned to 4685618388)

Solutions

  1. Use one of: core, wasm, hap, or full
  2. Omit --profile entirely to get the default 'core' profile
  3. Validate against the allowlist before invoking: ['core','wasm','hap','full'].includes(profile)

Example fix

// before
await runVerification({ profile: 'all' });

// after
await runVerification({ profile: 'full' });
Defensive patterns

Strategy: type-guard

Validate before calling

const VERIFICATION_PROFILES = new Set(['core', 'wasm', 'hap', 'full']);
function normalizeProfile(value) {
  const p = typeof value === 'string' ? value.toLowerCase() : 'core';
  return VERIFICATION_PROFILES.has(p) ? p : null;
}
// use: const profile = normalizeProfile(args.profile); if (!profile) failFast();

Type guard

/** @param {unknown} v @returns {v is 'core'|'wasm'|'hap'|'full'} */
function isVerificationProfile(v) {
  return v === 'core' || v === 'wasm' || v === 'hap' || v === 'full';
}

Prevention

When it happens

Trigger: verify --profile all, --profile rust, --profile Core (capital C), or any profile string read from env/config that is not one of core|wasm|hap|full.

Common situations: Guessing profile names from other tools ('all', 'default', 'quick'), stale scripts from older harness versions, profile names copied from CI workflow identifiers.

Related errors


AI-assisted analysis of ruvnet/RuView@4685618388 (2026-08-16). Data as JSON: /api/errors/e9a4274306d6bb0a. Report an issue: GitHub.