chore: delete code no binary or test reaches

This commit is contained in:
sam committed 2026-10-17 10:14:26 +11:00
1 parent 7986ccb3f7
commit 01acb97f96
34 files changed
+1 -1483

No files matched your search

-18
View File
@@ -51,24 +51,6 @@ type Plan struct {
ContextSources []spec.ContextSource
}
// DecodePublished reads the descriptor from an image's manifest annotations
// and holds it to the published form: strict decoding, full validation, and
// no unexpanded build-phase args.
func DecodePublished(annotations map[string]string) (*spec.Descriptor, error) {
raw, ok := annotations[spec.AnnotationDescriptor]
if !ok {
return nil, fmt.Errorf("image is not a kit: no %s annotation", spec.AnnotationDescriptor)
}
d, err := spec.Decode([]byte(raw))
if err != nil {
return nil, err
}
if _, err := spec.ValidatePublished([]byte(raw), d); err != nil {
return nil, err
}
return d, nil
}
// SelectCapability applies Archie's runtime policy before composition.
func SelectCapability(_ context.Context, _ spec.Descriptor, c spec.Capability) spec.CapabilityDecision {
reason, err := refusalReason(c)