Hello Tobias! Tobias Geerinckx-Rice <m...@tobias.gr> writes:
> Guix, > > I saw this reported by jlicht on #guix but I'm pretty sure that > it's been reported a few times. > > Here's the error, with channel: > > (channel > (name 'guix) (url "https://git.savannah.gnu.org/git/guix.git") > (branch "core-updates-frozen") > (introduction > (make-channel-introduction > "9edb3f66fd807b096b48283debdcddccfea34bad" > (openpgp-fingerprint > "BBB0 2DDF 2CEA F6A8 0D1D E643 A2A0 6DF2 A33A 54FA")))) > > And patch: > > From: Tobias Geerinckx-Rice <m...@tobias.gr> > Date: Fri, 19 Nov 2021 17:37:44 +0100 > Subject: [PATCH] daemon: Print the line whence we expect an > integer. > > * nix/libstore/local-store.cc > (LocalStore::getLineFromSubstituter): > Include the malformed substituter stream line in the error > message. > > --- > nix/libstore/local-store.cc | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/nix/libstore/local-store.cc > b/nix/libstore/local-store.cc > index 675d1ba66f..83b6681122 100644 > --- a/nix/libstore/local-store.cc > +++ b/nix/libstore/local-store.cc > @@ -839,7 +839,8 @@ template<class T> T > LocalStore::getIntLineFromSubstituter(Agent & run) > { > string s = getLineFromSubstituter(run); > T res; > - if (!string2Int(s, res)) throw Error("integer expected from > stream"); > + if (!string2Int(s, res)) > + throw Error(format("integer expected from stream: %1%") % > s); > return res; > } I just stumbled on this. LGTM! Maxim