about summary refs log tree commit diff
diff options
context:
space:
mode:
authorGriffin Smith <grfn@gws.fyi>2020-11-27T19·51-0500
committerglittershark <grfn@gws.fyi>2020-11-27T20·10+0000
commitbbfc47e96dcef901588e989a57a9d608eadafb26 (patch)
treef1444495281a545caef1741349ed27400301c3c6
parent39f96c4d9f5799aad1c064ef80c6fb1aed45f4e3 (diff)
feat(tvix): Write build logs to LOG(INFO) in buildDerivation r/1942
This was referencing a nonexistent note in buildPaths, for one, but for
another let's get log outputs when calling this RPC.

Change-Id: Ic9d17834b356ea84d69692ccc0249d09777e833b
Reviewed-on: https://cl.tvl.fyi/c/depot/+/2173
Tested-by: BuildkiteCI
Reviewed-by: kanepyork <rikingcoding@gmail.com>
-rw-r--r--third_party/nix/src/libstore/rpc-store.cc5
1 files changed, 1 insertions, 4 deletions
diff --git a/third_party/nix/src/libstore/rpc-store.cc b/third_party/nix/src/libstore/rpc-store.cc
index 6bf58747d0..afaeca4a66 100644
--- a/third_party/nix/src/libstore/rpc-store.cc
+++ b/third_party/nix/src/libstore/rpc-store.cc
@@ -384,9 +384,6 @@ BuildResult RpcStore::buildDerivation(const Path& drvPath,
   *request.mutable_derivation() = proto_drv;
   request.set_build_mode(BuildModeToProto(buildMode));
 
-  // Same note as in ::buildPaths ...
-  std::ostream discard_logs = DiscardLogsSink();
-
   std::unique_ptr<grpc::ClientReader<proto::BuildEvent>> reader =
       stub_->BuildDerivation(&ctx, request);
 
@@ -395,7 +392,7 @@ BuildResult RpcStore::buildDerivation(const Path& drvPath,
   proto::BuildEvent event;
   while (reader->Read(&event)) {
     if (event.has_build_log()) {
-      discard_logs << event.build_log().line();
+      LOG(INFO) << event.build_log().line();
     } else if (event.has_result()) {
       result = BuildResult::FromProto(event.result());
     }