fix(reference): retain unverified symlink target provenance

Keep the observed target path and failed directory in the unreadable-link diagnostic without promoting either to proven graph identity. Verify the retained path through the importer boundary.

Refs: #4013, #4053
This commit is contained in:
morluto committed 2026-10-16 04:52:19 +08:00
1 parent 921fa03fca
commit 25c22222ab
2 files changed
+2 -1

No files matched your search

+1 -1
View File
@@ -147,7 +147,7 @@ export const reconcileUnobservedSymlinkTargets = (
kind: "symlink",
path: entry.path,
code: ancestor.code,
message: `Symbolic link target is inside a directory that could not be enumerated: ${ancestor.message}`,
message: `Symbolic link target ${JSON.stringify(entry.target)} was not inventoried because directory ${JSON.stringify(ancestor.path)} could not be enumerated: ${ancestor.message}`,
};
}
};
@@ -108,6 +108,7 @@ describe("reference source native unreadable directories", () => {
kind: "symlink",
target: null,
target_state: "unreadable",
limitations: [expect.stringContaining('"hidden/target.txt"')],
}),
);
} finally {