scaffolding the Txin and TxinVoter data types and msg#1
Conversation
Txin correspond to user deposit event; TxinVoter is Txin reported by each validator with signature Once >2/3 TxinVoter is included in blocks, MetaCore will consider the Txin accepted.
use ctx to get accNum and accSeq instead of REST API. can now get rid of the REST API of MetaCore completely. Every interaction is through the gRPC.
which can be used to track application level "consensus" for an external Event (indexed by its txHash. Crucially, only one such Event can present in a single tx).
to keep track of the validator set. This message is supposed to create a NodeAccount, which will be introduced in later commit.
cmd: starport scaffold map NodeAccount nodeAddress pubkeySet nodeStatus --no-message
In the future, bond needs to be checked.
| Bech32PrefixConsAddr = "metac" | ||
| Bech32PrefixConsPub = "metacpub" | ||
| DenomRegex = `[a-zA-Z][a-zA-Z0-9:\\/\\\-\\_\\.]{2,127}` | ||
| METAChainCoinType uint32 = 933 |
There was a problem hiding this comment.
Placeholder. We’ll need to register here https://github.com/satoshilabs/slips/blob/master/slip-0044.md
| MainNet | ||
| // MockNet network for main net | ||
| MockNet | ||
| ) |
There was a problem hiding this comment.
Yes mocknet generally refers to local net mode, not even testnet
| } | ||
| return bech32.Encode(hrp, converted) | ||
| } | ||
|
|
There was a problem hiding this comment.
What is pubkeyset used for and why are we commenting it out?
There was a problem hiding this comment.
It will be used as part of validator node identity. The validator use ed25519 key for validation and secp256k1 key for node identify. We’ll need this when we deal with validator change, or voters logic
| require ( | ||
| github.com/btcsuite/btcd v0.21.0-beta | ||
| github.com/btcsuite/btcutil v1.0.2 | ||
| github.com/cosmos/cosmos-sdk v0.42.6 |
There was a problem hiding this comment.
Maybe not. Let me check. Sometimes we may need their cryptography library
| sourceAmount: | ||
| type: string | ||
| format: uint64 | ||
| mBurnt: |
There was a problem hiding this comment.
What is the purpose of this change?
There was a problem hiding this comment.
This is auto generated for web API. In response to refining data types of protobuf. When starport scaffold everyhing is string. I then change datatype to more refined ones.
| return "", err | ||
| } | ||
| builder.SetGasLimit(200000000) | ||
| fmt.Printf("signing from name: %s\n", ctx.GetFromName()) |
There was a problem hiding this comment.
What is this gas limit for?
There was a problem hiding this comment.
Our meta blockchain also use gas to limit tx size and computation...
| @@ -0,0 +1,14 @@ | |||
| syntax = "proto3"; | |||
| package MetaProtocol.metacore.metacore; | |||
|
|
|||
There was a problem hiding this comment.
What does node account represent?
There was a problem hiding this comment.
A validator node, keys, ip, rewards, status, etc
|
+1 |
Txin, TxinVoter, MetaBridge
Txin, TxinVoter, MetaBridge
No description provided.