diff --git a/go/nix/nixstore/remotestore.go b/go/nix/nixstore/remotestore.go index 04734c316d..250f489ca9 100644 --- a/go/nix/nixstore/remotestore.go +++ b/go/nix/nixstore/remotestore.go @@ -62,6 +62,9 @@ func (d *Daemon) NARInfo(storePath string) (*narinfo.NarInfo, error) { return nil, fmt.Errorf("reading deriver: %w", err) } ni.Deriver = path.Base(ni.Deriver) + if ni.Deriver == "." { + ni.Deriver = "" + } hashStr, err := d.r.ReadString() if err != nil { diff --git a/go/nix/nixstore/sqlitestore.go b/go/nix/nixstore/sqlitestore.go index e605824e68..3e409df1d3 100644 --- a/go/nix/nixstore/sqlitestore.go +++ b/go/nix/nixstore/sqlitestore.go @@ -64,6 +64,9 @@ WHERE 1=1 if deriverStr != nil { ni.Deriver = path.Base(*deriverStr) } + if ni.Deriver == "." { + ni.Deriver = "" + } if sigsStr != nil { sigsBits := strings.Fields(*sigsStr)