Centralize Scriptorium input source policy across config, analyze, and previous-cache

This commit is contained in:
2026-05-23 15:50:29 +00:00
parent 094b0d2532
commit 9fe44cd00d
6 changed files with 223 additions and 45 deletions

View File

@@ -229,7 +229,11 @@ func artifactRelativePathCandidates(
candidates = append(candidates, normalized)
}
sourceDescriptor, err := artifactpolicy.PreviousSessionSourceDescriptorForConfiguredKey(artifactName)
sourceID := artifactpolicy.ConfiguredSourceID(artifactName)
if err == nil {
sourceID = sourceDescriptor.ConfiguredSourceID
}
if rel, ok := manifestArtifactRelativePathBySourceID(previousManifest, sourceID); ok {
appendCandidate(rel)
base := path.Base(rel)