{"record":{"id":"64a80d6735c12b3e","repo":"affaan-m/ECC","slug":"no-install-profile-module-ids-included-component","errorCode":null,"errorMessage":"No install profile, module IDs, included components, or legacy languages were provided","messagePattern":"No install profile, module IDs, included components, or legacy languages were provided","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"scripts/lib/install/request.js","lineNumber":147,"sourceCode":"  const hookConsent = resolveHookConsentFlags(options);\n  if (hookConsent === 'declined' && moduleIds.includes('hooks-runtime')) {\n    throw new Error('--no-hooks cannot be combined with an explicit hooks-runtime module selection');\n  }\n  const hasManifestBaseSelection = Boolean(profileId) || moduleIds.length > 0 || includeComponentIds.length > 0;\n  const hasNonLocaleManifestSelection = Boolean(profileId)\n    || moduleIds.length > 0\n    || requestedIncludeComponentIds.length > 0\n    || excludeComponentIds.length > 0;\n  const usingManifestMode = hasManifestBaseSelection || excludeComponentIds.length > 0;\n\n  if (hasNonLocaleManifestSelection && legacyLanguages.length > 0) {\n    throw new Error(\n      'Legacy language arguments cannot be combined with --profile, --modules, --with, --without, or manifest config selections'\n    );\n  }\n\n  if (!options.help && !hasManifestBaseSelection && legacyLanguages.length === 0) {\n    throw new Error('No install profile, module IDs, included components, or legacy languages were provided');\n  }\n\n  return {\n    mode: legacyLanguages.length > 0\n      ? 'legacy-compat'\n      : (usingManifestMode ? 'manifest' : 'legacy-compat'),\n    target,\n    profileId,\n    moduleIds,\n    includeComponentIds,\n    excludeComponentIds,\n    legacyLanguages,\n    hookConsent,\n    configPath: config?.path || options.configPath || null,\n  };\n}\n\nmodule.exports = {","sourceCodeStart":129,"sourceCodeEnd":165,"githubUrl":"https://github.com/affaan-m/ECC/blob/8321021c54d670126ce3b2969d5deb880b4b0c2a/scripts/lib/install/request.js#L129-L165","documentation":"normalizeInstallRequest requires at least one selection to know what to install. When the caller neither selected a manifest base (profile/modules/with/without/exclusions) nor any legacy languages, and did not pass --help, there is nothing actionable, so the request is rejected.","triggerScenarios":"Calling normalizeInstallRequest (or request()) with an options object that has no profile, no module IDs, no included/excluded component IDs, no legacy languages, and options.help is falsy.","commonSituations":"Running the install CLI with no arguments; programmatically building an empty options object; a script where all flags were conditionally dropped (e.g. empty variable expansion) leaving no selections.","solutions":["Provide an install profile, e.g. --profile standard.","Provide module IDs via --modules.","Provide legacy language arguments if using the legacy syntax.","Pass --help to see available options instead of attempting an empty install."],"exampleFix":"// before\nawait request({})\n// after\nawait request({ profile: 'standard' })","handlingStrategy":"validation","validationCode":"const hasSelection = Boolean(opts.profile) || (opts.modules?.length > 0) || (opts.with?.length > 0) || (opts.without?.length > 0) || (opts.languages?.length > 0)\nif (!opts.help && !hasSelection) throw new Error('Provide a profile, modules, components, or legacy languages')","typeGuard":"function hasInstallSelection(opts) {\n  return Boolean(opts?.help) || Boolean(opts?.profile) ||\n    (Array.isArray(opts?.modules) && opts.modules.length > 0) ||\n    (Array.isArray(opts?.languages) && opts.languages.length > 0)\n}","tryCatchPattern":"try {\n  const req = normalizeInstallRequest(options)\n} catch (err) {\n  if (err.message.startsWith('No install profile')) {\n    console.error('Nothing to install: pass --profile, --modules, or language args (see --help)')\n  } else throw err\n}","preventionTips":["Always pass at least one selection flag to the installer.","Avoid building options objects conditionally such that all flags can drop out.","Default to a known profile when no flags are given in wrapper scripts.","Run with --help interactively to explore options instead of invoking empty."],"tags":["cli","install","validation","empty-input"],"backgroundTag":"missing-required-argument","analyzedSha":"8321021c54d670126ce3b2969d5deb880b4b0c2a","analyzedAt":"2026-09-16T10:08:13.343Z","contentChangedAt":"2026-09-16T10:08:13.343Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}