From 9e611636eec4c8b78416975721835f144061f2e3 Mon Sep 17 00:00:00 2001 From: Joost Jager Date: Tue, 18 Dec 2018 13:49:57 +0100 Subject: [PATCH] lnrpc: update github.com/golang/protobuf to v1.2.0 Update is necessary to get protoc to generate files in the right directory when using modules outside the gopath. The old version of this dependency did not support paths=source_relative. This commit also fixes a build error in lnd_test.go because of a slight difference in generated code. --- lnd_test.go | 4 ++-- lnrpc/README.md | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/lnd_test.go b/lnd_test.go index 9489b4f4f..f07cde4a3 100644 --- a/lnd_test.go +++ b/lnd_test.go @@ -12194,7 +12194,7 @@ func testRouteFeeCutoff(net *lntest.NetworkHarness, t *harnessTest) { // route using Carol as an intermediate hop is 10% of the payment's // amount, we'll use a lower percentage in order to invalid that route. feeLimitPercent := &lnrpc.FeeLimit{ - &lnrpc.FeeLimit_Percent{baseFee/1000 - 1}, + Limit: &lnrpc.FeeLimit_Percent{baseFee/1000 - 1}, } testFeeCutoff(feeLimitPercent) @@ -12202,7 +12202,7 @@ func testRouteFeeCutoff(net *lntest.NetworkHarness, t *harnessTest) { // fee for the route using Carol as an intermediate hop earlier, we can // use a smaller value in order to invalidate that route. feeLimitFixed := &lnrpc.FeeLimit{ - &lnrpc.FeeLimit_Fixed{int64(carolFee.ToSatoshis()) - 1}, + Limit: &lnrpc.FeeLimit_Fixed{int64(carolFee.ToSatoshis()) - 1}, } testFeeCutoff(feeLimitFixed) diff --git a/lnrpc/README.md b/lnrpc/README.md index 63757a5db..26089dbcd 100644 --- a/lnrpc/README.md +++ b/lnrpc/README.md @@ -149,11 +149,11 @@ $ unzip protoc-3.4.0-osx-x86_64.zip -d protoc $ export PATH=$PWD/protoc/bin:$PATH ``` -2. Install `golang/protobuf` at commit `bbd03ef6da3a115852eaf24c8a1c46aeb39aa175`. +2. Install `golang/protobuf` at commit `aa810b61a9c79d51363740d207bb46cf8e620ed5` (v1.2.0). ```bash $ git clone https://github.com/golang/protobuf $GOPATH/src/github.com/golang/protobuf $ cd $GOPATH/src/github.com/golang/protobuf -$ git reset --hard bbd03ef6da3a115852eaf24c8a1c46aeb39aa175 +$ git reset --hard aa810b61a9c79d51363740d207bb46cf8e620ed5 $ make ```