Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore!: replace NMTProof with Proof in nmt #1432

Open
wants to merge 5 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ endif

proto-gen: check-proto-deps
@echo "Generating Protobuf files"
@go run github.com/bufbuild/buf/cmd/buf@$(BUF_VERSION) generate
@go run github.com/bufbuild/buf/cmd/buf@$(BUF_VERSION) generate --exclude-path proto/nmt
@mv ./proto/tendermint/abci/types.pb.go ./abci/types/
@cp ./proto/tendermint/rpc/grpc/types.pb.go ./rpc/grpc
.PHONY: proto-gen
Expand Down
22 changes: 22 additions & 0 deletions proto/nmt/proof.proto
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
syntax="proto3";
Eoous marked this conversation as resolved.
Show resolved Hide resolved

package nmt;

option go_package = "github.com/celestiaorg/nmt/pb";

message Proof {
// Start index of the leaves that match the queried namespace.ID.
int64 start = 1;
// End index (non-inclusive) of the leaves that match the queried
// namespace.ID.
int64 end = 2;
// Nodes hold the tree nodes necessary for the Merkle range proof.
repeated bytes nodes = 3;
// leaf_hash contains the namespace.ID if NMT does not have it and
// it should be proven. leaf_hash is necessary to prove the Absence Proof.
// This field will be empty in case of Inclusion Proof.
bytes leaf_hash = 4;
// The is_max_namespace_ignored flag influences the calculation of the
// namespace ID range for intermediate nodes in the tree.
bool is_max_namespace_ignored=5;
}
Loading
Loading