bce06b1af3
Phase 8 of multi-repository task support: surface duplicate-repository input as a clean validation error instead of letting the unique (task_id, repository_id) constraint surface mid-loop with some rows already inserted. - createTaskRepositories tracks seen repository IDs and returns "repository <id> listed more than once for the task" before any CreateTaskRepository call. - Tests cover the rejection path and confirm two distinct repos still succeed with both rows persisted in Position order. Repository discovery and per-repo cloning were already covered by Phase 1.4 (resolveAllRepoInfo loops ensureRepoCloned) and the existing repository_discovery service is repo-list aware by design. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>