Skip to content

Commit f9e621f

Browse files
tac0turtlegithub-actions[bot]
authored andcommitted
chore: Sync docs from cosmos-sdk/docs
1 parent ee7ad59 commit f9e621f

File tree

148 files changed

+902
-868
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

148 files changed

+902
-868
lines changed

docs/build/abci/00-introduction.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ The 5 methods introduced in ABCI 2.0 are:
1919

2020
Based on validator voting power, CometBFT chooses a block proposer and calls `PrepareProposal` on the block proposer's application (Cosmos SDK). The selected block proposer is responsible for collecting outstanding transactions from the mempool, adhering to the application's specifications. The application can enforce custom transaction ordering and incorporate additional transactions, potentially generated from vote extensions in the previous block.
2121

22-
To perform this manipulation on the application side, a custom handler must be implemented. By default, the Cosmos SDK provides `PrepareProposalHandler`, used in conjunction with an application specific mempool. A custom handler can be written by application developer, if a noop handler provided, all transactions are considered valid.
22+
To perform this manipulation on the application side, a custom handler must be implemented. By default, the Cosmos SDK provides `PrepareProposalHandler`, used in conjunction with an application specific mempool. A custom handler can be written by an application developer, if a noop handler is provided, all transactions are considered valid.
2323

2424
Please note that vote extensions will only be available on the following height in which vote extensions are enabled. More information about vote extensions can be found [here](https://docs.cosmos.network/main/build/abci/vote-extensions).
2525

@@ -39,7 +39,7 @@ These methods allow applications to extend the voting process by requiring valid
3939

4040
If vote extensions are enabled, `ExtendVote` will be called on every validator and each one will return its vote extension which is in practice a bunch of bytes. As mentioned above this data (vote extension) can only be retrieved in the next block height during `PrepareProposal`. Additionally, this data can be arbitrary, but in the provided tutorials, it serves as an oracle or proof of transactions in the mempool. Essentially, vote extensions are processed and injected as transactions. Examples of use-cases for vote extensions include prices for a price oracle or encryption shares for an encrypted transaction mempool. `ExtendVote` CAN be non-deterministic.
4141

42-
`VerifyVoteExtensions` is performed on every validator multiple times in order to verify other validators' vote extensions. This check is submitted to validate the integrity and validity of the vote extensions preventing malicious or invalid vote extensions.
42+
`VerifyVoteExtensions` is performed on every validator multiple times in order to verify other validators' vote extensions. This check is performed to validate the integrity and validity of the vote extensions preventing malicious or invalid vote extensions.
4343

4444
Additionally, applications must keep the vote extension data concise as it can degrade the performance of their chain, see testing results [here](https://docs.cometbft.com/v0.38/qa/cometbft-qa-38#vote-extensions-testbed).
4545

docs/build/abci/02-process-proposal.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ default implementation of `PrepareProposal` runs basic validity checks on each
77
transaction.
88

99
Note, `ProcessProposal` MUST be deterministic. Non-deterministic behaviors will cause apphash mismatches.
10-
This means if `ProcessProposal` panics or fails and we reject, all honest validator
10+
This means that if `ProcessProposal` panics or fails and we reject, all honest validator
1111
processes should reject (i.e., prevote nil). If so, CometBFT will start a new round with a new block proposal and the same cycle will happen with `PrepareProposal`
1212
and `ProcessProposal` for the new proposal.
1313

docs/build/abci/03-vote-extensions.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ ABCI 2.0 (colloquially called ABCI++) allows an application to extend a pre-comm
1111
validator process. The Cosmos SDK defines [`baseapp.ExtendVoteHandler`](https://github.com/cosmos/cosmos-sdk/blob/v0.53.0/types/abci.go#L32):
1212

1313
```go
14-
type ExtendVoteHandler func(Context, *abci.RequestExtendVote) (*abci.ResponseExtendVote, error)
14+
type ExtendVoteHandler func(Context, *abci.ExtendVoteRequest) (*abci.ExtendVoteResponse, error)
1515
```
1616

1717
An application can set this handler in `app.go` via the `baseapp.SetExtendVoteHandler`
@@ -38,7 +38,7 @@ other validators when validating their pre-commits. For a given vote extension,
3838
this process MUST be deterministic. The Cosmos SDK defines [`sdk.VerifyVoteExtensionHandler`](https://github.com/cosmos/cosmos-sdk/blob/v0.50.1/types/abci.go#L29-L31):
3939

4040
```go
41-
type VerifyVoteExtensionHandler func(Context, *abci.RequestVerifyVoteExtension) (*abci.ResponseVerifyVoteExtension, error)
41+
type VerifyVoteExtensionHandler func(Context, *abci.VerifyVoteExtensionRequest) (*abci.VerifyVoteExtensionResponse, error)
4242
```
4343

4444
An application can set this handler in `app.go` via the `baseapp.SetVerifyVoteExtensionHandler`
@@ -78,7 +78,7 @@ will be available to the application during the subsequent `FinalizeBlock` call.
7878
An example of how a pre-FinalizeBlock hook could look like is shown below:
7979

8080
```go
81-
app.SetPreBlocker(func(ctx sdk.Context, req *abci.RequestFinalizeBlock) error {
81+
app.SetPreBlocker(func(ctx sdk.Context, req *abci.FinalizeBlockRequest) error {
8282
allVEs := []VE{} // store all parsed vote extensions here
8383
for _, tx := range req.Txs {
8484
// define a custom function that tries to parse the tx as a vote extension

docs/build/architecture/PROCESS.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99
## What is an ADR?
1010

11-
An ADR is a document to document an implementation and design that may or may not have been discussed in an RFC. While an RFC is meant to replace synchronous communication in a distributed environment, an ADR is meant to document an already made decision. An ADR won't come with much of a communication overhead because the discussion was recorded in an RFC or a synchronous discussion. If the consensus came from a synchronous discussion, then a short excerpt should be added to the ADR to explain the goals.
11+
An ADR is a document that documents an implementation and design that may or may not have been discussed in an RFC. While an RFC is meant to replace synchronous communication in a distributed environment, an ADR is meant to document an already made decision. An ADR won't come with much of a communication overhead because the discussion was recorded in an RFC or a synchronous discussion. If the consensus came from a synchronous discussion, then a short excerpt should be added to the ADR to explain the goals.
1212

1313
## ADR life cycle
1414

@@ -20,7 +20,7 @@ ADR creation is an **iterative** process. Instead of having a high amount of com
2020

2121
3. If a _proposed_ ADR is merged, then it should clearly document outstanding issues either in ADR document notes or in a GitHub Issue.
2222

23-
4. The PR SHOULD always be merged. In the case of a faulty ADR, we still prefer to merge it with a _rejected_ status. The only time the ADR SHOULD NOT be merged is if the author abandons it.
23+
4. The PR SHOULD always be merged. In the case of a faulty ADR, we still prefer to merge it with a _rejected_ status. The only time the ADR SHOULD NOT be merged is if the author abandons it.
2424

2525
5. Merged ADRs SHOULD NOT be pruned.
2626

@@ -44,15 +44,15 @@ DRAFT -> PROPOSED -> LAST CALL yyyy-mm-dd -> ACCEPTED | REJECTED -> SUPERSEDED b
4444
ABANDONED
4545
```
4646

47-
* `DRAFT`: [optional] an ADR which is a work in progress, not being ready for a general review. This is to present an early work and get early feedback in a Draft Pull Request form.
47+
* `DRAFT`: [optional] an ADR which is a work in progress, not ready for a general review. This is to present an early work and get early feedback in a Draft Pull Request form.
4848
* `PROPOSED`: an ADR covering a full solution architecture and still in the review - project stakeholders haven't reached an agreement yet.
4949
* `LAST CALL <date for the last call>`: [optional] Notify that we are close to accepting updates. Changing a status to `LAST CALL` means that social consensus (of Cosmos SDK maintainers) has been reached, and we still want to give it a time to let the community react or analyze.
50-
* `ACCEPTED`: ADR which will represent a currently implemented or to be implemented architecture design.
50+
* `ACCEPTED`: an ADR that represents a currently implemented or to be implemented architecture design.
5151
* `REJECTED`: ADR can go from PROPOSED or ACCEPTED to rejected if the consensus among project stakeholders will decide so.
52-
* `SUPERSEDED by ADR-xxx`: ADR which has been superseded by a new ADR.
52+
* `SUPERSEDED by ADR-xxx`: an ADR that has been superseded by a new ADR.
5353
* `ABANDONED`: the ADR is no longer pursued by the original authors.
5454

5555
## Language used in ADR
5656

5757
* The context/background should be written in the present tense.
58-
* Avoid using a first, personal form.
58+
* Avoid using the first person.

docs/build/architecture/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ This is a location to record all high-level architecture decisions in the Cosmos
88

99
An Architectural Decision (**AD**) is a software design choice that addresses a functional or non-functional requirement that is architecturally significant.
1010
An Architecturally Significant Requirement (**ASR**) is a requirement that has a measurable effect on a software system’s architecture and quality.
11-
An Architectural Decision Record (**ADR**) captures a single AD, such as often done when writing personal notes or meeting minutes; the collection of ADRs created and maintained in a project constitute its decision log. All these are within the topic of Architectural Knowledge Management (AKM).
11+
An Architectural Decision Record (**ADR**) captures a single AD, such as is often done when writing personal notes or meeting minutes; the collection of ADRs created and maintained in a project constitute its decision log. All these are within the topic of Architectural Knowledge Management (AKM).
1212

1313
You can read more about the ADR concept in this [blog post](https://product.reverb.com/documenting-architecture-decisions-the-reverb-way-a3563bb24bd0#.78xhdix6t).
1414

@@ -25,12 +25,12 @@ An ADR should provide:
2525

2626
Note the distinction between an ADR and a spec. The ADR provides the context, intuition, reasoning, and
2727
justification for a change in architecture, or for the architecture of something
28-
new. The spec is much more compressed and streamlined summary of everything as
28+
new. The spec is a much more compressed and streamlined summary of everything as
2929
it stands today.
3030

3131
If recorded decisions turned out to be lacking, convene a discussion, record the new decisions here, and then modify the code to match.
3232

33-
## Creating new ADR
33+
## Creating a new ADR
3434

3535
Read about the [PROCESS](./PROCESS.md).
3636

docs/build/architecture/adr-004-split-denomination-keys.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ This will result in the balances being indexed by the byte representation of
7474

7575
`DelegateCoins()` and `UndelegateCoins()` will be altered to only load each individual
7676
account balance by denomination found in the (un)delegation amount. As a result,
77-
any mutations to the account balance by will made by denomination.
77+
any mutations to the account balance will be made by denomination.
7878

7979
`SubtractCoins()` and `AddCoins()` will be altered to read & write the balances
8080
directly instead of calling `GetCoins()` / `SetCoins()` (which no longer exist).

docs/build/architecture/adr-006-secret-store-replacement.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ We are seeking solution that provides a common abstraction layer to the many dif
2121

2222
We recommend replacing the current Keybase backend based on LevelDB with [Keyring](https://github.com/99designs/keyring) by 99 designs. This application is designed to provide a common abstraction and uniform interface between many secret stores and is used by AWS Vault application by 99-designs application.
2323

24-
This appears to fulfill the requirement of protecting both key material and metadata from rouge software on a user’s machine.
24+
This appears to fulfill the requirement of protecting both key material and metadata from rogue software on a user’s machine.
2525

2626
## Status
2727

docs/build/architecture/adr-007-specialization-groups.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ the members already in a specialization group to internally elect new members,
5151
or maybe the community may assign a permission to a particular specialization
5252
group to appoint members to other 3rd party groups. The sky is really the limit
5353
as to how membership admittance can be structured. We attempt to capture
54-
some of these possiblities in a common interface dubbed the `Electionator`. For
54+
some of these possibilities in a common interface dubbed the `Electionator`. For
5555
its initial implementation as a part of this ADR we recommend that the general
5656
election abstraction (`Electionator`) is provided as well as a basic
5757
implementation of that abstraction which allows for a continuous election of

docs/build/architecture/adr-008-dCERT-group.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ they should all be severely slashed.
151151

152152
## Status
153153

154-
> Proposed
154+
Proposed
155155

156156
## Consequences
157157

docs/build/architecture/adr-010-modular-antehandler.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ type ModuleManager struct {
142142
}
143143

144144
func (mm ModuleManager) GetAnteHandler() AnteHandler {
145-
retun Chainer(mm.AnteHandlerOrder)
145+
return Chainer(mm.AnteHandlerOrder)
146146
}
147147
```
148148

0 commit comments

Comments
 (0)