Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: celestiaorg/celestia-core
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v1.44.0-tm-v0.34.35
Choose a base ref
...
head repository: celestiaorg/celestia-core
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: v1.44.1-tm-v0.34.35
Choose a head ref
  • 5 commits
  • 9 files changed
  • 5 contributors

Commits on Nov 27, 2024

  1. Fix typos in documentation (#1542)

    ## Description
    
    This PR introduces fixes for typos in documentation files:
    
    1. **First Commit:**
       - **File:** `spec.md`
       - **Change:** Fixed the typo `transcation` to `transaction`.
    - **Importance:** Ensures accuracy and clarity in describing
    transaction-related processes.
    
    2. **Second Commit:**
       - **File:** `README.md`
       - **Change:** Fixed the typo `separate` to `separated`.
    - **Importance:** Maintains consistency in terminology and avoids
    confusion in the explanation.
    
    These changes improve documentation accuracy and clarity, which is
    essential for better understanding and avoiding potential
    misinterpretations by developers.
    
    ---
    
    #### PR checklist
    
    - [x] Tests written/updated (N/A for documentation-only updates)
    - [x] Changelog entry added in `.changelog` (we use
    [unclog](https://github.com/informalsystems/unclog) to manage our
    changelog)
    - [x] Updated relevant documentation (`docs/` or `spec/`) and code
    comments
    sky-coderay authored Nov 27, 2024

    Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature.
    Copy the full SHA
    dc04af0 View commit details

Commits on Nov 29, 2024

  1. ci: remove mergify (#1540)

    Closes #1539
    Motivation
    #1539 (comment)
    rootulp authored Nov 29, 2024

    Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature.
    Copy the full SHA
    a9cdcda View commit details

Commits on Dec 4, 2024

  1. fix: typos and article usage in various documentation files (#1547)

    This PR addresses multiple typos and fixes article usage errors across
    several documentation files. The following changes were made:
    - Replaced "an" with "a" where the following word does not start with a
    vowel sound (e.g., "a user" instead of "an user").
    - Added hyphen to "above-mentioned" to maintain proper spelling.
    - Fixed phrasing for consistency and clarity in multiple sections.
    
    Files updated:
    - `adr-001-block-propagation.md`
    - `adr-006-row-propagation.md`
    - `adr-template.md`
    - `pex.md`
    
    These changes aim to improve readability and correctness in the
    documentation.
    Dimitrolito authored Dec 4, 2024

    Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature.
    Copy the full SHA
    9a514ad View commit details

Commits on Dec 10, 2024

  1. chore: deprecate timeout_commit and timeout_propose config (#1551)

    Closes #1550
    
    ## Testing
    
    In celestia-app I replaced celestia-core with this repo. Then created a
    new config file and observed:
    
    ```toml
    # How long we wait for a proposal block before prevoting nil
    # Deprecated: timeout_commit is overridden by the state machine in app version >= 3.
    # Therefore, the value set in this config will be ignored.
    timeout_propose = "3.5s"
    
    # How long we wait after committing a block, before starting on the new
    # height (this gives us a chance to receive some more precommits, even
    # though we already have +2/3).
    # Deprecated: timeout_commit is overridden by the state machine in app version >= 3.
    # Therefore, the value set in this config will be ignored.
    timeout_commit = "4.2s"
    ```
    
    ---------
    
    Co-authored-by: CHAMI Rachid <[email protected]>
    rootulp and rach-id authored Dec 10, 2024

    Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature.
    Copy the full SHA
    890a59b View commit details

Commits on Dec 12, 2024

  1. fix: remove go routines for RecheckTx (#1553)

    Closes: #1552
    cmwaters authored Dec 12, 2024

    Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature.
    Copy the full SHA
    d51978e View commit details
19 changes: 0 additions & 19 deletions .github/mergify.yml

This file was deleted.

4 changes: 4 additions & 0 deletions config/toml.go
Original file line number Diff line number Diff line change
@@ -480,6 +480,8 @@ only_internal_wal = "{{ .Consensus.OnlyInternalWal }}"
wal_file = "{{ js .Consensus.WalPath }}"
# How long we wait for a proposal block before prevoting nil
# Deprecated: timeout_commit is overridden by the state machine in app version >= 3.
# Therefore, the value set in this config will be ignored.
timeout_propose = "{{ .Consensus.TimeoutPropose }}"
# How much timeout_propose increases with each round
timeout_propose_delta = "{{ .Consensus.TimeoutProposeDelta }}"
@@ -494,6 +496,8 @@ timeout_precommit_delta = "{{ .Consensus.TimeoutPrecommitDelta }}"
# How long we wait after committing a block, before starting on the new
# height (this gives us a chance to receive some more precommits, even
# though we already have +2/3).
# Deprecated: timeout_commit is overridden by the state machine in app version >= 3.
# Therefore, the value set in this config will be ignored.
timeout_commit = "{{ .Consensus.TimeoutCommit }}"
# How many blocks to look back to check existence of the node's consensus votes before joining consensus
2 changes: 1 addition & 1 deletion docs/celestia-architecture/adr-001-block-propagation.md
Original file line number Diff line number Diff line change
@@ -102,7 +102,7 @@ When a user requests a block from the LL node, the request will be set to the IP

![user request flow](./assets/user-request.png)

The goal is to not change the public interface for RPC's. It is yet to be seen if this possible. This means that CIDs will need to be set and loaded from the store in order to get all the related block information an user requires.
The goal is to not change the public interface for RPC's. It is yet to be seen if this possible. This means that CIDs will need to be set and loaded from the store in order to get all the related block information a user requires.

## Status

4 changes: 2 additions & 2 deletions docs/celestia-architecture/adr-006-row-propagation.md
Original file line number Diff line number Diff line change
@@ -69,7 +69,7 @@ decrease the number of required changes. Below, implementation semantics are pre
// Row represents a blob of multiple ExtendedDataSquare shares.
// Practically, it is half of an extended row, as other half can be recomputed.
type Row struct {
// Index is an top-to-bottom index of a Row in ExtendedDataSquare.
// Index is a top-to-bottom index of a Row in ExtendedDataSquare.
// NOTE: Row Index is unnecessary, as we can determine it's Index by hash from DAHeader. However, Index removal
// would bring more changes to Consensus Reactor with arguable pros of less bandwidth usage.
Index int
@@ -199,4 +199,4 @@ Proposed
comparison. The actual data size in such a case for the Row would be 128x256(shares_per_row*share_size)=32KiB, which
is exactly two times smaller than a Part.
* Gossiped chunks are no longer constant size. Instead, their size is proportional to the size of Block's data.
* Another step back from original Tendermint's codebases
* Another step back from original Tendermint's codebases
2 changes: 1 addition & 1 deletion docs/celestia-architecture/adr-template.md
Original file line number Diff line number Diff line change
@@ -10,7 +10,7 @@
## Alternative Approaches

> This section contains information around alternative options that are considered before making a decision. It should contain a explanation on why the alternative approach(es) were not chosen.
> This section contains information around alternative options that are considered before making a decision. It should contain an explanation on why the alternative approach(es) were not chosen.
## Decision

46 changes: 19 additions & 27 deletions mempool/cat/pool.go
Original file line number Diff line number Diff line change
@@ -3,13 +3,10 @@ package cat
import (
"errors"
"fmt"
"runtime"
"sort"
"sync"
"time"

"github.com/creachadair/taskgroup"

abci "github.com/tendermint/tendermint/abci/types"
"github.com/tendermint/tendermint/config"
"github.com/tendermint/tendermint/libs/log"
@@ -672,36 +669,31 @@ func (txmp *TxPool) recheckTransactions() {
)

// Collect transactions currently in the mempool requiring recheck.
// TODO: we are iterating over a map, which may scramble the order of transactions
// such that they are not in order, dictated by nonce and then priority. This may
// cause transactions to needlessly be kicked out in RecheckTx
wtxs := txmp.store.getAllTxs()

// Issue CheckTx calls for each remaining transaction, and when all the
// rechecks are complete signal watchers that transactions may be available.
go func() {
g, start := taskgroup.New(nil).Limit(2 * runtime.NumCPU())

for _, wtx := range wtxs {
wtx := wtx
start(func() error {
// The response for this CheckTx is handled by the default recheckTxCallback.
rsp, err := txmp.proxyAppConn.CheckTxSync(abci.RequestCheckTx{
Tx: wtx.tx,
Type: abci.CheckTxType_Recheck,
})
if err != nil {
txmp.logger.Error("failed to execute CheckTx during recheck",
"err", err, "key", fmt.Sprintf("%x", wtx.key))
} else {
txmp.handleRecheckResult(wtx, rsp)
}
return nil
})
for _, wtx := range wtxs {
wtx := wtx
// The response for this CheckTx is handled by the default recheckTxCallback.
rsp, err := txmp.proxyAppConn.CheckTxSync(abci.RequestCheckTx{
Tx: wtx.tx,
Type: abci.CheckTxType_Recheck,
})
if err != nil {
txmp.logger.Error("failed to execute CheckTx during recheck",
"err", err, "key", fmt.Sprintf("%x", wtx.key))
} else {
txmp.handleRecheckResult(wtx, rsp)
}
_ = txmp.proxyAppConn.FlushAsync()
}
_ = txmp.proxyAppConn.FlushAsync()

// When recheck is complete, trigger a notification for more transactions.
_ = g.Wait()
txmp.notifyTxsAvailable()
}()
// When recheck is complete, trigger a notification for more transactions.
txmp.notifyTxsAvailable()
}

// availableBytes returns the number of bytes available in the mempool.
2 changes: 1 addition & 1 deletion mempool/cat/spec.md
Original file line number Diff line number Diff line change
@@ -60,7 +60,7 @@ Given this criteria, it is feasible, yet unlikely that a node receives two `Seen

A `SeenTx` MAY be sent for each transaction currently in the transaction pool when a connection with a peer is first established. This acts as a mechanism for syncing pool state across peers.

The `SeenTx` message MUST only be broadcasted after validation and storage. Although it is possible that a node later drops a transaction under load shedding, a `SeenTx` should give as strong guarantees as possible that the node can be relied upon by others that don't yet have the transcation to obtain it.
The `SeenTx` message MUST only be broadcasted after validation and storage. Although it is possible that a node later drops a transaction under load shedding, a `SeenTx` should give as strong guarantees as possible that the node can be relied upon by others that don't yet have the transaction to obtain it.

> **Note:**
> Inbound transactions submitted via the RPC do not trigger a `SeenTx` message as it is assumed that the node is the first to see the transaction and by gossiping it to others it is implied that the node has seen the transaction.
46 changes: 15 additions & 31 deletions mempool/v1/mempool.go
Original file line number Diff line number Diff line change
@@ -2,14 +2,11 @@ package v1

import (
"fmt"
"runtime"
"sort"
"sync"
"sync/atomic"
"time"

"github.com/creachadair/taskgroup"

abci "github.com/tendermint/tendermint/abci/types"
"github.com/tendermint/tendermint/config"
"github.com/tendermint/tendermint/libs/clist"
@@ -650,8 +647,6 @@ func (txmp *TxMempool) insertTx(wtx *WrappedTx) {
// that case is handled by addNewTransaction instead.
func (txmp *TxMempool) handleRecheckResult(tx types.Tx, checkTxRes *abci.ResponseCheckTx) {
txmp.metrics.RecheckTimes.Add(1)
txmp.mtx.Lock()
defer txmp.mtx.Unlock()

// Find the transaction reported by the ABCI callback. It is possible the
// transaction was evicted during the recheck, in which case the transaction
@@ -713,34 +708,23 @@ func (txmp *TxMempool) recheckTransactions() {

// Issue CheckTx calls for each remaining transaction, and when all the
// rechecks are complete signal watchers that transactions may be available.
go func() {
g, start := taskgroup.New(nil).Limit(2 * runtime.NumCPU())

for _, wtx := range wtxs {
wtx := wtx
start(func() error {
// The response for this CheckTx is handled by the default recheckTxCallback.
rsp, err := txmp.proxyAppConn.CheckTxSync(abci.RequestCheckTx{
Tx: wtx.tx,
Type: abci.CheckTxType_Recheck,
})
if err != nil {
txmp.logger.Error("failed to execute CheckTx during recheck",
"err", err, "hash", fmt.Sprintf("%x", wtx.tx.Hash()))
} else {
txmp.handleRecheckResult(wtx.tx, rsp)
}
return nil
})
for _, wtx := range wtxs {
wtx := wtx
// The response for this CheckTx is handled by the default recheckTxCallback.
rsp, err := txmp.proxyAppConn.CheckTxSync(abci.RequestCheckTx{
Tx: wtx.tx,
Type: abci.CheckTxType_Recheck,
})
if err != nil {
txmp.logger.Error("failed to execute CheckTx during recheck",
"err", err, "hash", fmt.Sprintf("%x", wtx.tx.Hash()))
} else {
txmp.handleRecheckResult(wtx.tx, rsp)
}
_ = txmp.proxyAppConn.FlushAsync()
}
_ = txmp.proxyAppConn.FlushAsync()

// When recheck is complete, trigger a notification for more transactions.
_ = g.Wait()
txmp.mtx.Lock()
defer txmp.mtx.Unlock()
txmp.notifyTxsAvailable()
}()
txmp.notifyTxsAvailable()
}

// canAddTx returns an error if we cannot insert the provided *WrappedTx into
2 changes: 1 addition & 1 deletion pkg/trace/README.md
Original file line number Diff line number Diff line change
@@ -15,7 +15,7 @@ trace_push_batch_size = 1000

# The list of tables that are updated when tracing. All available tables and
# their schema can be found in the pkg/trace/schema package. It is represented as a
# comma separate string. For example: "consensus_round_state,mempool_tx".
# comma separated string. For example: "consensus_round_state,mempool_tx".
tracing_tables = "consensus_round_state,mempool_tx"
```