Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.stablenet.network/llms.txt

Use this file to discover all available pages before exploring further.

StableNet preserves the go-ethereum core (EVM, StateDB, TxPool) and adds Anzeon WBFT consensus and five governance system contracts on top.

Transaction flow

When you call eth_sendRawTransaction, a transaction passes through four stages before it is final:
1. RPC submission → txpool validation
2. Mining candidate selection
3. EVM execution → state change
4. Block seal → Anzeon WBFT consensus → finality

1. Submission and pool validation

The transaction pool (txpool) validates every incoming transaction before accepting it:
  • Fee fields are well-formed (maxFeePerGasmaxPriorityFeePerGas)
  • Nonce matches the sender’s current on-chain nonce (or is queued)
  • For type 0x16, both sender and fee payer signatures are present
  • Gas tip meets the GovValidator-enforced minimum
Transactions that pass enter the pending pool. Those with nonce gaps or fee issues wait in the queued pool.

2. Block building

The miner worker selects pending transactions for the next block. Selection filters by:
  • baseFee from the block header
  • Governance gas tip from GovValidator
Transactions are ordered by effective gas price (highest first).

3. EVM execution and state transitions

Each transaction is applied to a StateDB snapshot:
  • Sender balance decremented by gasLimit × gasPrice
  • EVM executes the transaction
  • Storage and balance changes are journaled
  • On success: state changes are committed; unused gas refunded to the payer
  • On revert: state rolls back to pre-execution snapshot; gas is still consumed

4. Block finality

StableNet uses Anzeon WBFT consensus. Blocks proceed through PREPARE → COMMIT → FINALIZATION. Once a block is committed by a quorum of validators, it is final — no reorgs occur under normal operation.

State model

Every account in StableNet has five fields:
FieldDescription
nonceTransaction count
balanceWKRC balance in wei (same value as WKRC.balanceOf())
codeHashContract bytecode hash (zero for EOAs)
storageRootRoot of the account’s storage trie
extraStableNet policy flags (blacklist, authorized)
State is stored as a Merkle Patricia Trie. The state root in each block header commits to the entire chain state at that point.

Key developer implications

  • 1-second finality: you do not need to wait for multiple confirmations. One block = final.
  • Fee payer is invisible: for type 0x16 transactions, tx.origin is always the sender. Contracts cannot detect that fee delegation was used.
  • WKRC gas = WKRC balance: the same token balance used to pay gas is the ERC-20 balance. Holding WKRC for gas and for transfers is the same thing.
  • Nonce management: pending transactions block later nonces. If a transaction is stuck, later transactions from the same address also wait.

Developer benefits

  • 1-second finality removes the need for confirmation polling in most use cases
  • Standard Ethereum tooling (ethers.js, viem, Hardhat, Foundry) works without modification
  • balanceOf() and gas balance are always in sync — no separate token bridging needed