{"record":{"id":"628880ad5a98548f","repo":"angular/angular-cli","slug":"could-not-find-the-implementation-for-builder","errorCode":null,"errorMessage":"Could not find the implementation for builder ","messagePattern":"Could not find the implementation for builder ","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"packages/angular_devkit/architect/node/node-modules-architect-host.ts","lineNumber":193,"sourceCode":"    // Attempt to locate an entry for the specified builder by name\n    const builder = buildersManifest.builders?.[builderName];\n    if (!builder) {\n      throw new Error(`Cannot find builder ${JSON.stringify(builderStr)}.`);\n    }\n\n    // Resolve alias reference if entry is a string\n    if (typeof builder === 'string') {\n      return this.resolveBuilder(\n        builder,\n        path.dirname(packageJsonPath),\n        (seenBuilders ?? new Set()).add(builderStr),\n      );\n    }\n\n    // Determine builder implementation path (relative within package only)\n    const implementationPath = builder.implementation && path.normalize(builder.implementation);\n    if (!implementationPath) {\n      throw new Error('Could not find the implementation for builder ' + builderStr);\n    }\n    if (path.isAbsolute(implementationPath) || implementationPath.startsWith('..')) {\n      throw new Error(\n        `Package \"${packageName}\" has an invalid builder implementation path: \"${builderName}\" --> \"${builder.implementation}\"`,\n      );\n    }\n\n    // Determine builder option schema path (relative within package only)\n    let schemaPath = builder.schema;\n    if (!schemaPath) {\n      throw new Error('Could not find the schema for builder ' + builderStr);\n    }\n    if (path.isAbsolute(schemaPath) || path.normalize(schemaPath).startsWith('..')) {\n      throw new Error(\n        `Package \"${packageName}\" has an invalid builder schema path: \"${builderName}\" --> \"${builder.schema}\"`,\n      );\n    }\n","sourceCodeStart":175,"sourceCodeEnd":211,"githubUrl":"https://github.com/angular/angular-cli/blob/bb72145f9ab45aee29f523236b3a25cd0813a841/packages/angular_devkit/architect/node/node-modules-architect-host.ts#L175-L211","documentation":"A manifest entry for a builder must specify an 'implementation' path (the JS module implementing the builder). resolveBuilder throws when the entry lacks one, so no builder function could be loaded.","triggerScenarios":"A builders.json entry like {\"schema\": \"./schema.json\"} with no 'implementation' key, and code resolves that builder.","commonSituations":"Authoring a custom builder and forgetting the implementation field; a manifest entry left partially written; string alias chains resolving to an incomplete object entry.","solutions":["Add the 'implementation' field pointing to the builder's JS module in the builders.json entry.","Publish a corrected version of the builder package.","Use a different builder that is fully defined."],"exampleFix":"// before (builders.json)\n\"my-builder\": {\"schema\": \"./schema.json\"}\n// after\n\"my-builder\": {\"implementation\": \"./my-builder.impl\", \"schema\": \"./schema.json\"}","handlingStrategy":"validation","validationCode":"const entry = require(`${packageName}/builders.json`).builders?.[builderName];\nif (typeof entry === 'object' && !entry.implementation) throw new Error(`Builder \"${packageName}:${builderName}\" is missing an implementation path.`);","typeGuard":"const hasImplementation = (b) => typeof b === 'object' && b !== null && typeof b.implementation === 'string' && b.implementation.length > 0;","tryCatchPattern":"try { await host.resolveBuilder(builderStr); } catch (e) { if (String(e.message).includes('Could not find the implementation for builder')) { /* fix the manifest entry's 'implementation' field */ } else throw e; }","preventionTips":["Validate builder manifests against the BuilderSchema in CI.","Include implementation, schema, and description in every manifest entry.","Test `ng builder` discovery locally before publishing."],"tags":["angular","builder","manifest"],"backgroundTag":"incomplete-builder-manifest-entry","analyzedSha":"bb72145f9ab45aee29f523236b3a25cd0813a841","analyzedAt":"2026-08-30T02:47:34.745Z","schemaVersion":2},"datasetVersion":"2026-08-30T03:17:51.788Z"}