Skip to content

Conversation

@arajasek
Copy link
Contributor

@arajasek arajasek commented Jan 15, 2026

Describe your changes and provide context

This PR supports running a Giga node, in consensus with other non-Giga nodes. It only supports sequential execution for Giga, falling back to the v2 logic for cosmos and interop transactions.

TODO:

Testing performed to validate your change

  • tests pass
  • devnet runs with 1/4 nodes using giga, and both evm and cosmos txs hurled at the chain

@github-actions
Copy link

github-actions bot commented Jan 15, 2026

The latest Buf updates on your PR. Results from workflow Buf / buf (pull_request).

BuildFormatLintBreakingUpdated (UTC)
✅ passed✅ passed✅ passed✅ passedJan 26, 2026, 5:04 PM

@codecov
Copy link

codecov bot commented Jan 15, 2026

Codecov Report

❌ Patch coverage is 45.39007% with 77 lines in your changes missing coverage. Please review.
✅ Project coverage is 47.17%. Comparing base (77cc04e) to head (0c84786).

Files with missing lines Patch % Lines
app/app.go 58.88% 32 Missing and 5 partials ⚠️
sei-tendermint/internal/state/execution.go 0.00% 28 Missing ⚠️
giga/executor/utils/errors.go 0.00% 5 Missing ⚠️
giga/executor/precompiles/failfast.go 0.00% 4 Missing ⚠️
giga/deps/xbank/keeper/view.go 66.66% 1 Missing and 1 partial ⚠️
giga/deps/xbank/keeper/keeper.go 80.00% 1 Missing ⚠️

❗ There is a different number of reports uploaded between BASE (77cc04e) and HEAD (0c84786). Click for more details.

HEAD has 1 upload less than BASE
Flag BASE (77cc04e) HEAD (0c84786)
sei-tendermint 1 0
Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #2708      +/-   ##
==========================================
- Coverage   57.00%   47.17%   -9.84%     
==========================================
  Files        2004     1936      -68     
  Lines      164603   159019    -5584     
==========================================
- Hits        93838    75015   -18823     
- Misses      62560    77505   +14945     
+ Partials     8205     6499    -1706     
Flag Coverage Δ
sei-chain 41.71% <45.39%> (-0.08%) ⬇️
sei-cosmos 48.03% <ø> (ø)
sei-db 68.72% <ø> (ø)
sei-tendermint ?

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
giga/deps/xbank/keeper/send.go 85.28% <100.00%> (ø)
giga/deps/xbank/keeper/keeper.go 44.12% <80.00%> (ø)
giga/deps/xbank/keeper/view.go 87.23% <66.66%> (-3.47%) ⬇️
giga/executor/precompiles/failfast.go 27.27% <0.00%> (-15.59%) ⬇️
giga/executor/utils/errors.go 0.00% <0.00%> (ø)
sei-tendermint/internal/state/execution.go 0.00% <0.00%> (-80.13%) ⬇️
app/app.go 71.10% <58.88%> (-3.51%) ⬇️

... and 313 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

}

func (app *App) ProcessTxsSynchronousGiga(ctx sdk.Context, txs [][]byte, typedTxs []sdk.Tx, absoluteTxIndices []int) []*abci.ExecTxResult {
defer metrics.BlockProcessLatency(time.Now(), metrics.SYNCHRONOUS)

Check warning

Code scanning / CodeQL

Calling the system time Warning

Calling the system time may be a possible source of non-determinism
@arajasek arajasek force-pushed the asr/rpc-giga branch 12 times, most recently from b8763f8 to 130c3e5 Compare January 20, 2026 15:18
@arajasek arajasek marked this pull request as ready for review January 20, 2026 20:51
@arajasek arajasek changed the title WIP: Giga RPC node feat: Giga RPC node (sequential execution) Jan 21, 2026
@arajasek arajasek force-pushed the asr/rpc-giga branch 2 times, most recently from 5547872 to 9ff6ef2 Compare January 23, 2026 15:31
}
continue
}

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

would need to call ctx.GigaMultiStore().WriteGiga() here since giga cache isn't visible to v2 executor so need flushing

arajasek and others added 6 commits January 26, 2026 11:56
Fixed critical issues causing `LastResultsHash` mismatch between the
standard and giga executors, which was causing consensus failures when
running nodes with `GIGA_EXECUTOR` enabled.

The `LastResultsHash` is computed from only 4 deterministic fields of
each `ExecTxResult` (defined in `deterministicExecTxResult` in
`sei-tendermint/abci/types/types.go`):
- `Code`
- `Data`
- `GasWanted`
- `GasUsed`

The giga executor was producing different values for two of these
fields.

The giga executor was not setting `GasWanted` (defaulted to 0), while
the standard executor sets it to the transaction's gas limit.

```go
// Before: GasWanted not set (defaults to 0)
// After:
gasWanted := int64(ethTx.Gas())
```

The giga executor was putting raw receipt bytes in the `Data` field,
while the standard executor wraps `MsgEVMTransactionResponse` in
`TxMsgData`:

```go
// Before: Data = receiptBytes (raw marshaled receipt)

// After: Matches standard executor format
evmResponse := &evmtypes.MsgEVMTransactionResponse{
    GasUsed:    execResult.UsedGas,
    VmError:    vmError,
    ReturnData: execResult.ReturnData,
    Hash:       ethTx.Hash().Hex(),
    Logs:       evmtypes.NewLogsFromEth(stateDB.GetAllLogs()),
}
txMsgData := &sdk.TxMsgData{Data: []*sdk.MsgData{{MsgType: msgTypeURL, Data: evmResponseBytes}}}
// Data = marshaled txMsgData
```

Added logging to aid future debugging of consensus issues:

| Level | Location | What's Logged |
|-------|----------|---------------|
| **Error** | `ValidateBlock` on mismatch | Expected vs got hash, block
height, numTxs, blockHash |
| **Info** | `ApplyBlock` after hash computation | Computed hash,
height, txCount |
| **Debug** | `ApplyBlock` per-tx | Code, GasWanted, GasUsed, dataLen
for each tx |

- `app/app.go` - Fixed giga executor `GasWanted` and `Data` field format
- `sei-tendermint/internal/state/execution.go` - Added LastResultsHash
debugging logs

Run a multi-node cluster with one node using `GIGA_EXECUTOR=true` and
verify blocks reach consensus without `LastResultsHash` mismatch errors.
- Set the txIndex correctly (ProcessBlock already does this)
- Return ABCI codes
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants