{"record":{"id":"ec754645dee1493b","repo":"affaan-m/ECC","slug":"unknown-install-profile-profileid","errorCode":null,"errorMessage":"Unknown install profile: ${profileId}","messagePattern":"Unknown install profile: (.+?)","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"scripts/lib/install-manifests.js","lineNumber":550,"sourceCode":"      `Unknown install target: ${target}. Expected one of ${SUPPORTED_INSTALL_TARGETS.join(', ')}`\n    );\n  }\n\n  const shouldUseTargetDefaultProfile = !requestedProfileId\n    && explicitModuleIds.length === 0\n    && includedComponentIds.length === 0;\n  const targetDefaultProfileId = shouldUseTargetDefaultProfile\n    ? getTargetDefaultProfileId(target, manifests)\n    : null;\n  const profileId = requestedProfileId || targetDefaultProfileId;\n  const targetDefaultExclusions = targetDefaultProfileId\n    ? getTargetDefaultExclusions(target, manifests)\n    : [];\n\n  if (profileId) {\n    const profile = manifests.profiles[profileId];\n    if (!profile) {\n      throw new Error(`Unknown install profile: ${profileId}`);\n    }\n    requestedModuleIds.push(...profile.modules);\n  }\n\n  requestedModuleIds.push(...explicitModuleIds);\n  requestedModuleIds.push(...expandComponentIdsToModuleIds(includedComponentIds, manifests));\n\n  const excludedModuleIds = expandComponentIdsToModuleIds(excludedComponentIds, manifests);\n  const excludedModuleOwners = new Map();\n  for (const componentId of excludedComponentIds) {\n    const component = manifests.componentsById.get(componentId);\n    if (!component) {\n      throw new Error(`Unknown install component: ${componentId}`);\n    }\n    for (const moduleId of component.modules) {\n      const owners = excludedModuleOwners.get(moduleId) || [];\n      owners.push(componentId);\n      excludedModuleOwners.set(moduleId, owners);","sourceCodeStart":532,"sourceCodeEnd":568,"githubUrl":"https://github.com/affaan-m/ECC/blob/01e15490f04e29cfefe3896951f43db46994d8ee/scripts/lib/install-manifests.js#L532-L568","documentation":"Thrown by resolveInstallPlan() when profileId resolves to a value (either options.profileId or the target-default profile id) but manifests.profiles[profileId] is undefined. The profiles object is built from manifests/install-profiles.json — a miss means the profile was renamed, removed, or misspelled.","triggerScenarios":"Passing options.profileId = 'standard' when the file only defines 'baseline'; passing a profile from a different ECC version; passing the profile description text instead of the id; target's default profile id is stale because install-profiles.json was edited.","commonSituations":"A wrapper script hardcodes a profile name that drifted; the user typed the human description ('Standard install') instead of the id ('standard'); profiles JSON is corrupt and was parsed to an empty object.","solutions":["Call listInstallProfiles() and use one of the returned ids.","Verify manifests/install-profiles.json exists and is valid JSON at the configured repoRoot.","If you want a target-default profile, pass only target and let resolveInstallPlan compute it.","Drop profileId and pass moduleIds / includeComponentIds directly for a custom selection."],"exampleFix":"// before\nresolveInstallPlan({ target: 'claude', profileId: 'standard' });\n// after\nconst profiles = listInstallProfiles().map(p => p.id);\nconst profileId = profiles.includes('standard') ? 'standard' : undefined;\nresolveInstallPlan({ target: 'claude', profileId });","handlingStrategy":"validation","validationCode":"const profiles = listInstallProfiles().map(p => p.id);\nif (!profiles.includes(profileId)) {\n  throw new Error(`Unknown profileId: ${profileId}. Valid: ${profiles.join(', ')}`);\n}\nresolveInstallPlan({ target, profileId });","typeGuard":null,"tryCatchPattern":"try {\n  return resolveInstallPlan({ target, profileId });\n} catch (err) {\n  if (/^Unknown install profile:/.test(err.message)) {\n    return resolveInstallPlan({ target }); // fall back to target-default\n  }\n  throw err;\n}","preventionTips":["Cache listInstallProfiles() output for the duration of a CLI invocation.","Let the target-default profile work by omitting profileId entirely."],"tags":["install","validation","profile","manifest","lookup"],"backgroundTag":null,"analyzedSha":"01e15490f04e29cfefe3896951f43db46994d8ee","analyzedAt":"2026-08-13T00:31:08.655Z","schemaVersion":2},"datasetVersion":"2026-08-13T04:17:16.726Z"}