Fix bd-437: Use addDependencyUnchecked during collision resolution
When remapping dependencies during collision resolution, skip semantic validation (like parent-child direction checks) since we're just updating IDs on existing dependencies that were already validated. Fixes parent-child validation error during import --resolve-collisions.
This commit is contained in:
@@ -474,7 +474,9 @@ func updateDependencyReferences(ctx context.Context, s *SQLiteStorage, idMapping
|
||||
}
|
||||
|
||||
// Add new dependency with updated IDs
|
||||
if err := s.AddDependency(ctx, update.newDep, "import-remap"); err != nil {
|
||||
// Use addDependencyUnchecked to skip semantic validation (like parent-child direction)
|
||||
// since we're just remapping existing dependencies that were already validated
|
||||
if err := s.addDependencyUnchecked(ctx, update.newDep, "import-remap"); err != nil {
|
||||
return fmt.Errorf("failed to add updated dependency %s -> %s: %w",
|
||||
update.newDep.IssueID, update.newDep.DependsOnID, err)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user