Skip to content

Commit

Permalink
docs: add govmint to x/foundation specification (#748)
Browse files Browse the repository at this point in the history
* docs: add govmint to x/foundation specification

* docs: apply pr review
  • Loading branch information
dudong2 committed Oct 26, 2022
1 parent 715a8f5 commit d0bc22b
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -145,3 +145,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
29 changes: 28 additions & 1 deletion x/foundation/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -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)
Expand All @@ -44,6 +45,7 @@ back these foundation-specific functionalities.
* [EventRevoke](#eventrevoke)
* [EventFundTreasury](#eventfundedtreasury)
* [EventWithdrawFromTreasury](#eventwithdrawedfromtreasury)
* [EventGovMint](#eventgovmint)
* [Client](#client)
* [CLI](#cli)
* [gRPC](#grpc)
Expand Down Expand Up @@ -262,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
Expand Down Expand Up @@ -476,7 +484,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`.
Expand All @@ -489,6 +497,17 @@ 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 authority is not the module's authority.
* The remaining left count is 0.

# Events

## EventUpdateFoundationParams
Expand Down Expand Up @@ -598,6 +617,14 @@ the treasury.
| to | {toAddress} |
| amount | {amount} |

## EventGovMint

`EventGovMint` is an event emitted when coins are minted.

| Attribute Key | Attribute Value |
|---------------|-----------------|
| amount | {amount} |

# Client

## CLI
Expand Down

0 comments on commit d0bc22b

Please sign in to comment.