← Back to Blog

Shell Chain v0.22.0 — Stability, Observability, and STARK Hardening

·Shell Chain Team
releasestarkproverobservability

Shell Chain v0.22.0

Shell-Chain v0.22.0 is a focused stability release that makes STARK settlement durable across node restarts, adds structured proof data decoding to the RPC, and surfaces new prover liveness metrics. This release completes the v0.21 STARK/reward work with production-grade hardening.


What's New

Durable STARK Settlement Index

Previously, the set of accepted (layer, source_hash) pairs that guard against duplicate STARK settlements was rebuilt by scanning the full chain on every node restart. This is now replaced with a persistent SettledSourceIndex (stored at ss/ prefix in the KV store):

  • Fast-path startup: if the index is populated, settled sources are loaded directly — no chain scan needed.
  • Slow-path / repair: if the index is empty (first run or corruption), the node scans the chain once and backfills the index automatically.
  • Durable rejection: duplicate settlement attempts are rejected even after a restart, preserving protocol integrity without requiring a full chain rescan.

O(3) Compression Layer Lookup

The compression_layer_for_source() function previously performed an O(n) linear scan over all settled sources. It now checks layers 3, 2, 1 in reverse order — constant cost regardless of settled set size. The current protocol supports up to 3 compression layers.

Proof Input Decoding on the RPC

eth_getTransactionByHash for starkReward system transactions now includes a decodedInput field with the structured proof amendment payload:

{
  "layer": 1,
  "blockNumber": 58,
  "startBlock": 0,
  "endBlock": 58,
  "nSigs": 120,
  "compressedSize": 1024,
  "originalSize": 4096,
  "settlementTxHash": "0xabcdef01…"
}

This makes proof settlement data directly readable from the RPC without custom binary decoding. The Shell Explorer tx-detail page shows this as a formatted Input Data Decode panel and adds a Compression Ratio row.

Prover Liveness Metrics

Three new Prometheus metrics are registered:

Metric Description
stark_settlements_accepted Counter: proof amendment settlements accepted
stark_settlements_rejected Counter: settlements rejected (duplicate, wrong layer, etc.)
stark_frontier_lag Gauge: gap between the last settled source and current chain head

These integrate into existing /metrics endpoint and dashboards.


Ecosystem Updates

Package Version Change
shell-chain 0.22.0 Durable index, O(3) scan, proof decode, metrics
shell-sdk 0.8.0 ShellDecodedProofInput type; decodedInput on ShellRpcTransaction
shell-explorer (latest) Structured proof input decode panel, compression ratio row
shella-chrome-wallet (latest) decodedInput field in WalletTxRecord

Upgrade Guide

Node operators

No configuration changes required. The node automatically builds the SettledSourceIndex on first startup after upgrading — expect a one-time chain scan that may take a few seconds on large chains.

# Update and restart
git pull && cargo build --release
systemctl restart shell-node

SDK users

npm install shell-sdk@0.8.0

The new ShellDecodedProofInput type and decodedInput field on ShellRpcTransaction are available once you upgrade.


Compatibility Matrix

shell-chain shell-sdk shell-explorer shella-chrome-wallet
v0.22.0 v0.8.0 v0.22+ v0.22+
v0.21.x v0.7.1 v0.21+ v0.21+

The decodedInput field is optional — SDK v0.8.0 and explorer/wallet v0.22+ work correctly with older nodes (the field is simply absent/null).


What's Next

v0.23.0 will focus on additional consensus hardening, extended RPC history completeness, and testnet operations tooling.