{"record":{"id":"98332bfcc7881d04","repo":"diegosouzapw/OmniRoute","slug":"plugin-name-is-not-installed-use-install","errorCode":null,"errorMessage":"Plugin '${name}' is not installed — use install() instead","messagePattern":"Plugin '(.+?)' is not installed — use install\\(\\) instead","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"src/lib/plugins/manager.ts","lineNumber":286,"sourceCode":"        discovered = { name: result.data.name, manifest: result.data, pluginDir: sourceDir };\n      }\n    } catch {}\n\n    if (!discovered) {\n      const { plugins, errors } = await scanPluginDir(sourceDir);\n      if (plugins.length === 0) {\n        throw new Error(\n          `No valid plugin found in ${sourceDir}: ${errors.map((e) => e.error).join(\", \")}`\n        );\n      }\n      discovered = plugins[0];\n    }\n\n    const { name, manifest } = discovered;\n\n    // Must be already installed\n    if (!pluginExists(name)) {\n      throw new Error(`Plugin '${name}' is not installed — use install() instead`);\n    }\n\n    const existing = getPluginByName(name)!;\n\n    // Source must be strictly newer\n    if (compareSemver(manifest.version, existing.version) <= 0) {\n      throw new Error(\n        `Plugin '${name}' upgrade rejected: source version ${manifest.version} is not newer than installed ${existing.version}`\n      );\n    }\n\n    log.info(\"manager.upgrading\", { name, from: existing.version, to: manifest.version });\n\n    // Deactivate if active before touching files\n    if (existing.status === \"active\") {\n      await this.deactivate(name);\n    }\n","sourceCodeStart":268,"sourceCodeEnd":304,"githubUrl":"https://github.com/diegosouzapw/OmniRoute/blob/a179ffed5bb2e0b883b9ae7214ce8717b2a94c4d/src/lib/plugins/manager.ts#L268-L304","documentation":"Error \"Plugin '${name}' is not installed — use install() instead\" thrown in diegosouzapw/OmniRoute.","triggerScenarios":"Thrown at src/lib/plugins/manager.ts:286 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"a179ffed5bb2e0b883b9ae7214ce8717b2a94c4d","analyzedAt":"2026-08-25T18:35:09.898Z","schemaVersion":2},"datasetVersion":"2026-08-25T21:54:21.419Z"}