{"record":{"id":"6412c4586c863a3c","repo":"ReactiveX/rxjs","slug":"skill-content-resolves-outside-its-canonical-root","errorCode":null,"errorMessage":"Skill content resolves outside its canonical root: ${candidate}","messagePattern":"Skill content resolves outside its canonical root: (.+?)","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"packages/migrate/src/skill-integrity.ts","lineNumber":79,"sourceCode":"  const entries = await readdir(directory, { withFileTypes: true });\n  const result: string[] = [];\n  for (const entry of entries.sort((left, right) => left.name.localeCompare(right.name))) {\n    const absolutePath = resolve(directory, entry.name);\n    const localPath = relative(root, absolutePath).replaceAll(sep, '/');\n    if (localPath === skillProvenanceFileName) continue;\n    const stats = await lstat(absolutePath);\n    if (stats.isSymbolicLink()) throw new Error(`Canonical Skill content must not contain symbolic links: ${absolutePath}`);\n    if (stats.isDirectory()) result.push(...(await collectFiles(root, absolutePath)));\n    else if (stats.isFile()) result.push(localPath);\n    else throw new Error(`Canonical Skill content must contain only regular files and directories: ${absolutePath}`);\n  }\n  return result.sort();\n}\n\nfunction assertContained(root: string, candidate: string): void {\n  const localPath = relative(root, candidate);\n  if (localPath === '' || (localPath !== '..' && !localPath.startsWith(`..${sep}`))) return;\n  throw new Error(`Skill content resolves outside its canonical root: ${candidate}`);\n}\n","sourceCodeStart":61,"sourceCodeEnd":81,"githubUrl":"https://github.com/ReactiveX/rxjs/blob/54796b38a57e6309f9861e174737479bb3f63f61/packages/migrate/src/skill-integrity.ts#L61-L81","documentation":"Error \"Skill content resolves outside its canonical root: ${candidate}\" thrown in ReactiveX/rxjs.","triggerScenarios":"Thrown at packages/migrate/src/skill-integrity.ts:79 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":"54796b38a57e6309f9861e174737479bb3f63f61","analyzedAt":"2026-08-28T10:21:27.410Z","schemaVersion":2},"datasetVersion":"2026-08-28T11:17:15.048Z"}