From f7124667145d1f7c614d9fc644bc07bb6174454a Mon Sep 17 00:00:00 2001 From: Ophestra Date: Fri, 9 Jan 2026 01:51:39 +0900 Subject: internal/pkg: move dependency flooding to cache This imposes a hard upper limit to concurrency during dependency satisfaction and moves all dependency-related code out of individual implementations of Artifact. This change also includes ctx and msg as part of Cache. Signed-off-by: Ophestra --- internal/pkg/file.go | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) (limited to 'internal/pkg/file.go') diff --git a/internal/pkg/file.go b/internal/pkg/file.go index d7ac933f..50a161a4 100644 --- a/internal/pkg/file.go +++ b/internal/pkg/file.go @@ -2,7 +2,6 @@ package pkg import ( "crypto/sha512" - "syscall" ) // A fileArtifact is an [Artifact] that cures into data known ahead of time. @@ -31,10 +30,5 @@ func (a fileArtifact) Checksum() Checksum { return Checksum(h.Sum(nil)) } -// Data returns the caller-supplied data. -func (a fileArtifact) Data() ([]byte, error) { return a, nil } - -// Cure returns syscall.ENOTSUP. Callers should use Data instead. -func (a fileArtifact) Cure(*CureContext) (err error) { - return syscall.ENOTSUP -} +// Cure returns the caller-supplied data. +func (a fileArtifact) Cure() ([]byte, error) { return a, nil } -- cgit v1.3.1