From 3f864fa0cee015c732f8588984ebce7e87befd6b Mon Sep 17 00:00:00 2001 From: dudong2 Date: Tue, 25 Oct 2022 02:23:57 +0900 Subject: [PATCH 1/2] docs: add govmint to x/foundation specification --- CHANGELOG.md | 1 + x/foundation/README.md | 22 +++++++++++++++++++++- 2 files changed, 22 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 43b86a943c..d1ef6107b4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -143,3 +143,4 @@ Ref: https://keepachangelog.com/en/1.0.0/ * (docs) [\#490](https://github.com/line/lbm-sdk/pull/490) update documents on x/consortium * (docs) [\#602](https://github.com/line/lbm-sdk/pull/602) update outdated events in specs * (docs) [\#721](https://github.com/line/lbm-sdk/pull/721) update x/foundation specification +* (docs) [\#748](https://github.com/line/lbm-sdk/pull/748) add `govmint` to x/foundation specification diff --git a/x/foundation/README.md b/x/foundation/README.md index 16c17b437d..674bb1d7c8 100644 --- a/x/foundation/README.md +++ b/x/foundation/README.md @@ -31,6 +31,7 @@ back these foundation-specific functionalities. * [Msg/Revoke](#msgrevoke) * [Msg/FundTreasury](#msgfundtreasury) * [Msg/WithdrawFromTreasury](#msgwithdrawfromtreasury) + * [Msg/GovMint](#msggovmint) * [Events](#events) * [EventUpdateFoundationParams](#eventupdatefoundationparams) * [EventUpdateDecisionPolicy](#eventupdatedecisionpolicy) @@ -44,6 +45,7 @@ back these foundation-specific functionalities. * [EventRevoke](#eventrevoke) * [EventFundTreasury](#eventfundedtreasury) * [EventWithdrawFromTreasury](#eventwithdrawedfromtreasury) + * [EventGovMint](#eventgovmint) * [Client](#client) * [CLI](#cli) * [gRPC](#grpc) @@ -476,7 +478,7 @@ Anyone can fund treasury with `MsgFundTreasury`. +++ https://github.com/line/lbm-sdk/blob/392277a33519d289154e8da27f05f9a6788ab076/proto/lbm/foundation/v1/tx.proto#L76-L81 -## Msg/WithdrawFromTresury +## Msg/WithdrawFromTreasury The foundation can withdraw coins from the treasury with `MsgWithdrawFromTreasury`. @@ -489,6 +491,16 @@ The message handling should fail if: * the address which receives the coins has no authorization of `ReceiveFromTreasuryAuthorization`. +## Msg/GovMint + +Massive minting is possible through 'msggovmint' up to 1 time after the chain is started. + ++++ https://github.com/line/lbm-sdk/blob/66988a235a0e01f7a1ee76d719d585ff35f0d176/proto/lbm/foundation/v1/tx.proto#L221-L225 + +The message handling should fail if: + +* The remaining left count is 0. + # Events ## EventUpdateFoundationParams @@ -598,6 +610,14 @@ the treasury. | to | {toAddress} | | amount | {amount} | +## EventGovMint + +`EventGovMint` is an event emitted when coins are minted by proposal + +| Attribute Key | Attribute Value | +|---------------|-----------------| +| amount | {amount} | + # Client ## CLI From 3740e12d204b88c0ed70ac5d1aa44b9f1c00fe2e Mon Sep 17 00:00:00 2001 From: dudong2 Date: Tue, 25 Oct 2022 21:12:41 +0900 Subject: [PATCH 2/2] docs: apply pr review --- CHANGELOG.md | 2 +- x/foundation/README.md | 11 +++++++++-- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index d1ef6107b4..56617abc91 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -143,4 +143,4 @@ Ref: https://keepachangelog.com/en/1.0.0/ * (docs) [\#490](https://github.com/line/lbm-sdk/pull/490) update documents on x/consortium * (docs) [\#602](https://github.com/line/lbm-sdk/pull/602) update outdated events in specs * (docs) [\#721](https://github.com/line/lbm-sdk/pull/721) update x/foundation specification -* (docs) [\#748](https://github.com/line/lbm-sdk/pull/748) add `govmint` to x/foundation specification +* (docs) [\#748](https://github.com/line/lbm-sdk/pull/748) add `GovMint` to x/foundation specification diff --git a/x/foundation/README.md b/x/foundation/README.md index 674bb1d7c8..1f5c69a1a1 100644 --- a/x/foundation/README.md +++ b/x/foundation/README.md @@ -264,6 +264,12 @@ sending the message `Msg/WithdrawFromTreasury`. value again (irreversible), which means you must set it to a non-zero value in the genesis to make it work. +## GovMint + +When the chain is first started, it may be necessary to mint a large amount of +coins at most once for initial validators or for specific purposes. Newly minted +coins are transferred to the treasury pool. + # State ## Params @@ -493,12 +499,13 @@ The message handling should fail if: ## Msg/GovMint -Massive minting is possible through 'msggovmint' up to 1 time after the chain is started. +Massive minting is possible through 'MsgGovMint' up to 1 time after the chain is started. +++ https://github.com/line/lbm-sdk/blob/66988a235a0e01f7a1ee76d719d585ff35f0d176/proto/lbm/foundation/v1/tx.proto#L221-L225 The message handling should fail if: +* the authority is not the module's authority. * The remaining left count is 0. # Events @@ -612,7 +619,7 @@ the treasury. ## EventGovMint -`EventGovMint` is an event emitted when coins are minted by proposal +`EventGovMint` is an event emitted when coins are minted. | Attribute Key | Attribute Value | |---------------|-----------------|