Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
3a9cb99
add whole sdk docs unedited
Cordtus Oct 15, 2025
351203f
restore full sdk docs
Cordtus Oct 15, 2025
4e29965
..
Cordtus Oct 15, 2025
a02037f
unignore ./build
Cordtus Oct 15, 2025
b668cef
add build dirs
Cordtus Oct 15, 2025
d2bfbe6
Merge remote-tracking branch 'origin/v0.5.0-integration' into neil/ad…
Cordtus Oct 16, 2025
ab533d2
prep for Neil
Cordtus Oct 16, 2025
431c3e6
Merge pull request #108 from cosmos/main
Cordtus Oct 21, 2025
7ba67e6
add missing steps + overview of chain build process
Cordtus Oct 16, 2025
e0a476e
improve wording
Cordtus Oct 16, 2025
32cf70f
improve copy on main overview
Cordtus Oct 16, 2025
6e89d6c
remove redundant info
Cordtus Oct 17, 2025
6c5802d
condense / optimize overall size of config pages
Cordtus Oct 17, 2025
020cfa3
clean up and condense all chain build guides
Cordtus Oct 17, 2025
962a63d
tweak title
Cordtus Oct 17, 2025
0a6bfee
slight wording changes
Cordtus Oct 17, 2025
830e106
remove temp files
Cordtus Oct 20, 2025
a4155de
further refine build a chain docs
Cordtus Oct 20, 2025
0c7a77b
port 0.4>0.5 migration doc from repo, add missing notes to 0.3>0.4 mi…
Cordtus Oct 20, 2025
fc6e91f
add preliminary release notes for v0.5.0
Cordtus Oct 20, 2025
b1e0221
update other release notes -- unrelated
Cordtus Oct 20, 2025
d2dc8ec
update versions metadata
Cordtus Oct 20, 2025
f028073
finalizing build-chain overview page
Cordtus Oct 21, 2025
4dca4a0
setup guide tweak
Cordtus Oct 21, 2025
3577848
improve initial-setup
Cordtus Oct 21, 2025
0e3d72b
fix: convert relative ADR links to absolute paths for Mintlify compat…
Cordtus Oct 21, 2025
ee45167
fix: convert additional relative links to absolute paths
Cordtus Oct 21, 2025
372d7c8
fix: convert /v0.XX/ and /sdk/ prefix links to absolute paths
Cordtus Oct 21, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
10 changes: 0 additions & 10 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -63,16 +63,6 @@ schema.json
docs/logs/
logs/
dist/
build/

# --- allow SDK docs build/ dirs (override rule above) ---
!docs/sdk/v0.53/build/
!docs/sdk/v0.53/build/**
!docs/sdk/v0.50/build/
!docs/sdk/v0.50/build/**
!docs/sdk/v0.47/build/
!docs/sdk/v0.47/build/**
# --------------------------------------------------------

.yarn/
# Keep most scripts ignored, but include versioning tools
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
5 changes: 5 additions & 0 deletions copy-of-sdk-docs/build/_category_.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"label": "Build",
"position": 0,
"link": null
}
51 changes: 51 additions & 0 deletions copy-of-sdk-docs/build/abci/00-introduction.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
# Introduction

## What is ABCI?

ABCI, Application Blockchain Interface is the interface between CometBFT and the application. More information about ABCI can be found [here](https://docs.cometbft.com/v0.38/spec/abci/). CometBFT version 0.38 included a new version of ABCI (called ABCI 2.0) which added several new methods.

The 5 methods introduced in ABCI 2.0 are:

* `PrepareProposal`
* `ProcessProposal`
* `ExtendVote`
* `VerifyVoteExtension`
* `FinalizeBlock`


## The Flow

## PrepareProposal

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.

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.

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).

After creating the proposal, the proposer returns it to CometBFT.

PrepareProposal CAN be non-deterministic.

## ProcessProposal

This method allows validators to perform application-specific checks on the block proposal and is called on all validators. This is an important step in the consensus process, as it ensures that the block is valid and meets the requirements of the application. For example, validators could check that the block contains all the required transactions or that the block does not create any invalid state transitions.

The implementation of `ProcessProposal` MUST be deterministic.

## ExtendVote and VerifyVoteExtensions

These methods allow applications to extend the voting process by requiring validators to perform additional actions beyond simply validating blocks.

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.

`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.

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).

`VerifyVoteExtensions` MUST be deterministic.


## FinalizeBlock

`FinalizeBlock` is then called and is responsible for updating the state of the blockchain and making the block available to users.
45 changes: 45 additions & 0 deletions copy-of-sdk-docs/build/abci/01-prepare-proposal.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
# Prepare Proposal

`PrepareProposal` handles construction of the block, meaning that when a proposer
is preparing to propose a block, it requests the application to evaluate a
`RequestPrepareProposal`, which contains a series of transactions from CometBFT's
mempool. At this point, the application has complete control over the proposal.
It can modify, delete, and inject transactions from its own app-side mempool into
the proposal or even ignore all the transactions altogether. What the application
does with the transactions provided to it by `RequestPrepareProposal` has no
effect on CometBFT's mempool.

Note, that the application defines the semantics of the `PrepareProposal` and it
MAY be non-deterministic and is only executed by the current block proposer.

Now, reading mempool twice in the previous sentence is confusing, lets break it down.
CometBFT has a mempool that handles gossiping transactions to other nodes
in the network. The order of these transactions is determined by CometBFT's mempool,
using FIFO as the sole ordering mechanism. It's worth noting that the priority mempool
in Comet was removed or deprecated.
However, since the application is able to fully inspect
all transactions, it can provide greater control over transaction ordering.
Allowing the application to handle ordering enables the application to define how
it would like the block constructed.

The Cosmos SDK defines the `DefaultProposalHandler` type, which provides applications with
`PrepareProposal` and `ProcessProposal` handlers. If you decide to implement your
own `PrepareProposal` handler, you must ensure that the transactions
selected DO NOT exceed the maximum block gas (if set) and the maximum bytes provided
by `req.MaxBytes`.

```go reference
https://github.com/cosmos/cosmos-sdk/blob/v0.53.0/baseapp/abci_utils.go
```

This default implementation can be overridden by the application developer in
favor of a custom implementation in [`app_di.go`](../building-apps/01-app-go-di.md):

```go
prepareOpt := func(app *baseapp.BaseApp) {
abciPropHandler := baseapp.NewDefaultProposalHandler(mempool, app)
app.SetPrepareProposal(abciPropHandler.PrepareProposalHandler())
}

baseAppOptions = append(baseAppOptions, prepareOpt)
```
Loading