{"record":{"id":"2e6dfd7784262f82","repo":"coleam00/Archon","slug":"failed-to-clone-projectpath-sanitized","errorCode":null,"errorMessage":"Failed to clone ${projectPath}: ${sanitized}","messagePattern":"Failed to clone (.+?): (.+?)","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"packages/adapters/src/community/forge/gitlab/adapter.ts","lineNumber":517,"sourceCode":"      if (typeof errRecord.stderr === 'string') sanitizedError.stderr = sanitize(errRecord.stderr);\n\n      getLog().error({ projectPath, repoPath, error: sanitizedError }, 'gitlab.repo_clone_failed');\n\n      if (msg.includes('not found') || msg.includes('404')) {\n        throw new Error(\n          `Repository ${projectPath} not found or is private. Check repository access.`\n        );\n      }\n      if (\n        msg.includes('authentication failed') ||\n        msg.includes('could not read') ||\n        msg.includes('403')\n      ) {\n        throw new Error(\n          `Authentication failed for ${projectPath}. Check GITLAB_TOKEN permissions.`\n        );\n      }\n      throw new Error(`Failed to clone ${projectPath}: ${sanitized}`);\n    }\n\n    await addSafeDirectory(toRepoPath(repoPath));\n  }\n\n  private async autoDetectAndLoadCommands(repoPath: string, codebaseId: string): Promise<void> {\n    const commandFolders = getCommandFolderSearchPaths();\n\n    for (const folder of commandFolders) {\n      try {\n        const fullPath = join(repoPath, folder);\n        await access(fullPath);\n\n        const files = (await readdir(fullPath)).filter(f => f.endsWith('.md'));\n        if (files.length === 0) continue;\n\n        const commands = await codebaseDb.getCodebaseCommands(codebaseId);\n        files.forEach(file => {","sourceCodeStart":499,"sourceCodeEnd":535,"githubUrl":"https://github.com/coleam00/Archon/blob/0773b9745896ef0612e709c80845a0f7db315b19/packages/adapters/src/community/forge/gitlab/adapter.ts#L499-L535","documentation":"Error \"Failed to clone ${projectPath}: ${sanitized}\" thrown in coleam00/Archon.","triggerScenarios":"Thrown at packages/adapters/src/community/forge/gitlab/adapter.ts:517 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":"0773b9745896ef0612e709c80845a0f7db315b19","analyzedAt":"2026-09-01T02:28:07.064Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-08T05:18:18.240Z"}