From ce4591437b5b828ff52dd544617166287fa4026b Mon Sep 17 00:00:00 2001 From: Oliver Gugger Date: Fri, 3 Apr 2020 10:20:38 +0200 Subject: [PATCH] docs: link to lnrpc README, remove json_name --- docs/code_contribution_guidelines.md | 25 +++++-------------------- 1 file changed, 5 insertions(+), 20 deletions(-) diff --git a/docs/code_contribution_guidelines.md b/docs/code_contribution_guidelines.md index 7c189a63..48d75489 100644 --- a/docs/code_contribution_guidelines.md +++ b/docs/code_contribution_guidelines.md @@ -452,30 +452,15 @@ _exact same_ version of `protoc`. As of the writing of this article, the `lnd` project uses [v3.4.0](https://github.com/google/protobuf/releases/tag/v3.4.0) of `protoc`. -The following commit hashes of related projects are also required in order to -generate identical compiled protos and related files: - * grpc-ecosystem/grpc-gateway: `f2862b476edcef83412c7af8687c9cd8e4097c0f` - * golang/protobuf: `ab9f9a6dab164b7d1246e0e688b0ab7b94d8553e` +The following two libraries must be installed with the exact commit hash as +described in [lnrpc README](https://github.com/lightningnetwork/lnd/blob/master/lnrpc/README.md) +otherwise the CI pipeline on Travis will fail: +- grpc-ecosystem/grpc-gateway +- golang/protobuf For detailed instructions on how to compile modifications to `lnd`'s `protobuf` definitions, check out the [lnrpc README](https://github.com/lightningnetwork/lnd/blob/master/lnrpc/README.md). -Additionally, in order to maintain a uniform display of the RPC responses -rendered by `lncli`, all added or modified `protof` definitions, _must_ attach -the proper `json_name` option for all fields. An example of such an option can -be found within the definition of the `DebugLevelResponse` struct: - -```protobuf -message DebugLevelResponse { - string sub_systems = 1 [ json_name = "sub_systems" ]; -} - -``` - -Notice how the `json_name` field option corresponds with the name of the field -itself, and uses a `snake_case` style of name formatting. All added or modified -`proto` fields should adhere to the format above. - #### 4.8. Additional Style Constraints On Top of `gofmt`