{"record":{"id":"5f385a0fcc8b6ab2","repo":"paperclipai/paperclip","slug":"source-and-target-paperclip-configs-are-the-same-5f385a","errorCode":null,"errorMessage":"Source and target Paperclip configs are the same. Choose different --from/--to values.","messagePattern":"Source and target Paperclip configs are the same\\. Choose different --from/--to values\\.","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"cli/src/commands/worktree.ts","lineNumber":3410,"sourceCode":"  } finally {\n    await targetHandle.stop();\n    await sourceHandle.stop();\n  }\n}\n\nasync function runWorktreeReseed(opts: WorktreeReseedOptions): Promise<void> {\n  const seedMode = opts.seedMode ?? \"full\";\n  if (!isWorktreeSeedMode(seedMode)) {\n    throw new Error(`Unsupported seed mode \"${seedMode}\". Expected one of: minimal, full.`);\n  }\n\n  const targetEndpoint = opts.to\n    ? resolveWorktreeEndpointFromSelector(opts.to, { allowCurrent: true })\n    : resolveCurrentWorktreeEndpoint();\n  const source = resolveWorktreeReseedSource(opts);\n\n  if (path.resolve(source.configPath) === path.resolve(targetEndpoint.configPath)) {\n    throw new Error(\"Source and target Paperclip configs are the same. Choose different --from/--to values.\");\n  }\n  if (!existsSync(source.configPath)) {\n    throw new Error(`Source config not found at ${source.configPath}.`);\n  }\n\n  const targetConfig = readConfig(targetEndpoint.configPath);\n  if (!targetConfig) {\n    throw new Error(`Target config not found at ${targetEndpoint.configPath}.`);\n  }\n  const sourceConfig = readConfig(source.configPath);\n  if (!sourceConfig) {\n    throw new Error(`Source config not found at ${source.configPath}.`);\n  }\n\n  const targetPaths = resolveWorktreeReseedTargetPaths({\n    configPath: targetEndpoint.configPath,\n    rootPath: targetEndpoint.rootPath,\n  });","sourceCodeStart":3392,"sourceCodeEnd":3428,"githubUrl":"https://github.com/paperclipai/paperclip/blob/67001ec6eb96ae601aa27bc91d9b2415d665334a/cli/src/commands/worktree.ts#L3392-L3428","documentation":"Thrown by runWorktreeReseed after resolving source and target when both config paths are identical. Reseeding an instance from itself is destructive and pointless, so it is rejected. Distinct from the merge-history variant (245) because reseed accepts --from-config/--from-data-dir/--from-instance in addition to --from, so the message references '--from/--to values' broadly.","triggerScenarios":"Calling `worktree reseed` where the resolved source config path equals the resolved target config path: e.g. --from current --to current, or --from-config pointing at the target's own config.json, or --from-instance default where the target IS the default instance.","commonSituations":"A developer runs reseed without flags from inside the only instance (both default to current). Or they pass --from-config with a path that, after resolution, is the target config.","solutions":["Point --from / --from-config / --from-data-dir / --from-instance at a different source instance.","Set --to explicitly to the worktree you want to overwrite, distinct from the source."],"exampleFix":"// before\npaperclipai worktree reseed\n// after\npaperclipai worktree reseed --from-config ~/.paperclip/instances/default/config.json --to /path/to/worktree --seed-mode full","handlingStrategy":"validation","validationCode":"import path from \"node:path\";\n\nfunction validateReseedDistinct(sourceConfigPath: string, targetConfigPath: string): void {\n  if (path.resolve(sourceConfigPath) === path.resolve(targetConfigPath)) {\n    throw new Error(\"Source and target Paperclip configs are the same. Choose different --from/--to values.\");\n  }\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Always specify --to explicitly when running reseed from inside the source instance.","Derive --from-config from a different instance id than the target's PAPERCLIP_INSTANCE_ID."],"tags":["worktree","cli","reseed","validation"],"backgroundTag":null,"analyzedSha":"67001ec6eb96ae601aa27bc91d9b2415d665334a","analyzedAt":"2026-08-12T12:05:45.408Z","schemaVersion":2},"datasetVersion":"2026-08-12T18:17:37.767Z"}