github NethermindEth/nethermind 2.0.0-rc2
v2.0.0-rc2

pre-release5 hours ago

Note

This sits on 2.0.0-rc. The archive layout, performance numbers, and 2.0 breaking-config list in those notes still apply. Read them first if you are coming from 1.39.x.

Release notes

A second release candidate on top of 2.0.0-rc. Flat is now the default state backend for a fresh database, windowed archive config is explicit, and a set of sync, shutdown, and JSON-RPC fixes land on the RC.

No database-format change relative to 2.0.0-rc. An existing 2.0.0-rc does not need a resync.

Highlights

  • Flat DB is the default for new state (#11931). FlatDb.Enabled defaults to true. A new node, or a resync, gets the flat backend. An existing patricia database is detected at start and stays patricia; an existing flat database stays flat. To sync a fresh node on patricia: -FlatDb.Enabled=false.
  • Explicit history-retention mode, plus SinceBlock (#13162). Windowed archive is no longer "a non-zero HistoryRetentionBlocks." The shape is FlatDb.HistoryRetention = None | Rolling | SinceBlock. SinceBlock keeps everything from a fixed height onward and never prunes; below that height, reads fail closed.
  • Historical eth_getProof on a flat archive (#13098). An unwindowed flat archive can serve eth_getProof (and proof_*) at covered historical heights. Off by default.

Fresh nodes on the default config also serve snap (Sync.SnapServingEnabled defaults on for the flat path). Set Sync.SnapServingEnabled=false if you do not want the extra outbound bandwidth. Existing patricia nodes are unaffected.

A patricia node upgraded to rc2 will still create empty flat column families on disk (the probe opens them before it notices the patricia state). Harmless extra disk and file descriptors; they are not used.

⚠️ Breaking changes (relative to 2.0.0-rc)

Everything in the 2.0.0-rc notes still applies if you are coming from 1.39.x. On top of that:

  • FlatDb.Enabled is default. Fresh / resyncing nodes get flat and snap-serving. Existing DBs are unchanged.
  • FlatDb.HistoryRetention is required whenever you set a window size or a since-block. HistoryRetentionBlocks alone fails to start. A window size without a mode, Rolling without a size, SinceBlock without a block, or both numbers at once, are all refused. That key only existed on the RC, so this is the moment to make the config honest rather than inferring forever.
  • A configured FinalTotalDifficulty is no longer treated as "TTD reached" (#12555). Custom-FTD configs that relied on that inference will wait for the real TTD.

Sync, database & state

  • Mainnet snap no longer livelocks on the last large-storage account; forced pivot updates are distance-guarded. (#13155, #13200 / #13310)
  • A stalled snap sync is visible at the default log level. (#13248 / #13257)
  • A malformed header response no longer stalls fast-headers. (#13019)
  • Receipt bodies are looked up by number and hash. (#13139)
  • In-flight sync dispatch is drained before the database is torn down, so a graceful restart of a syncing node no longer SIGSEGVs. (#13154 / #13309)
  • Warmer misses no longer escape through shared trie children. (#13272)
  • Compacted snapshots are released after base conversion; finalized forks are pruned from persisted snapshots. (#13223, #13230)
  • Full-pruning snapshot trigger is measured from the pruning boundary. (#13199 / #13308)

JSON-RPC & Engine API

  • Streamed trace_* keeps the module rented until the result is written. Concurrent traces no longer collide on the overridable world scope. (#13095)
  • Unauthenticated input no longer produces empty HTTP 500s, leaked stack traces in error.data, or a WARN flood of 32602s. A chunk-size ≥ 0x80000000 is HTTP 400. Deep recursive eth_estimateGas no longer answers 32603 "Stack empty." (#13194, #13195, #13197, #13198, #13156 / #13251)
  • A missing-argument marker on a required parameter is rejected as 32602, not an NRE. (#13235)
  • Out-of-memory on the RPC path is logged without formatting the request. (#13225)
  • The chainspec-misconfiguration warning no longer fires as a false positive; JSON-RPC logs when it actually opens. (#13202, #13203 / #13255)
  • eth_maxPriorityFeePerGas returned a gas price; it now returns a priority fee. (#13129)
  • Each engine_getPayload response is built from a single block candidate; the improvement context of a replaced payload is disposed. (#13093, #13206)

Txpool, networking & other

  • Corrupt light-blob records are skipped on pool restore instead of aborting it; blob persistence after revalidation is atomic. (#13032, #13045)
  • Undersized ECIES ciphertexts throw controlled exceptions. (#13135)
  • Kademlia discovery traffic is reduced on a healthy table. (#13124)
  • Rlp/TxDecoder type-initializer cycle broken. (#13158)

Upgrade checklist

From 2.0.0-rc

  1. Stop the node. No resync.
  2. If your config sets FlatDb.HistoryRetentionBlocks, add FlatDb.HistoryRetention=Rolling or the process will exit on start.
  3. Leave FlatDb.Enabled alone unless you are starting a new datadir and you want patricia (false).
  4. Fresh nodes will serve snap. Turn it off with Sync.SnapServingEnabled=false if that is not what you want.
  5. Start and confirm 2.0.0-rc2 in the startup logs. A patricia node should log that an existing patricia state was detected.

From 1.39.x

Do the 2.0.0-rc checklist first (Db.FlushOnExit bool→enum, unsigned numerics, Receipt.TxLookupLimit: -1, rename Blocks.PreWarmStateOnBlockProcessing). Then the five steps above. A 1.39 patricia DB stays patricia.

Do not set --FlatDb.Enabled=false on an existing flat datadir. The node does not refuse; it discards the flat state and full-resyncs. The inverse (patricia DB + default flat) is detected and protected. (#13428)

What's Changed

  • Reduce Kademlia discovery traffic on healthy tables by @flcl42 in #13124
  • Exercise block downloader tests with flat and trie state backends by @asdacap in #13328
  • feat(flat): explicit flat-history retention mode, with SinceBlock by @svlachakis in #13162
  • fix(flatdb): release compacted snapshots after base conversion by @benaadams in #13223
  • fix(flat): prevent warmer misses escaping through shared trie children by @benaadams in #13272
  • fix(rpc): reject a missing-argument marker on a required parameter by @Matgothmog in #13235
  • fix(jsonrpc): do not format the request when logging an OutOfMemoryException by @benaadams in #13225
  • fix(rpc): stop unauthenticated input causing unhandled exceptions, empty 500s, leaked traces and WARN floods by @stdevMac in #13251
  • feat(sync): make a stalled snap sync visible at default log level by @stdevMac in #13257
  • test(jsonrpc): make Nethermind.JsonRpc.Test safe to run twice at once by @stdevMac in #13256
  • fix(rpc): drop the chainspec-misconfiguration false positive, and say when JSON-RPC opens by @stdevMac in #13255
  • fix(pruning): measure the full-pruning snapshot trigger from the pruning boundary by @stdevMac in #13308
  • fix(sync): drain in-flight sync dispatch before database teardown by @stdevMac in #13309
  • fix(snap): recover a stalled large-storage account and rate-limit the forced pivot by @stdevMac in #13310
  • Enable flat DB by default; flip CI backend coverage by @asdacap in #11931
  • feat(flat-history): historical eth_getProof from archive commitments by @svlachakis in #13098
  • fix(rpc): keep the module rented until a streamed result has been written by @kamilchodola in #13095
  • fix: eth_maxPriorityFeePerGas returned a gas price by @MysticRyuujin in #13129
  • fix(rlp): break the Rlp/TxDecoder type initializer cycle by @LukaszRozmej in #13158
  • fix(sync): stop a malformed header response from stalling fast-headers sync by @dipkakwani in #13019
  • fix(flatdb): prune finalized forks from persisted snapshots by @benaadams in #13230
  • fix(engine): build each getPayload response from a single block candidate by @dipkakwani in #13093
  • fix: dispose the improvement context that replaces a retrieved payload by @LukaszRozmej in #13206
  • ci: capture a dump when a test host hangs by @LukaszRozmej in #13149
  • fix(sync): look up receipt bodies by number and hash by @LukaszRozmej in #13139
  • Reject undersized ECIES ciphertexts with controlled exceptions by @flcl42 in #13135
  • Don't treat configured FinalTotalDifficulty as TTD reached by @kamilchodola in #12555
  • Fix PoSSwitcher genesis nullability build error by @benaadams in #13367
  • Fix atomic blob transaction persistence after revalidation by @benaadams in #13045
  • fix: skip corrupt light blob tx records instead of aborting pool restore by @Marchhill in #13032

Full Changelog: 2.0.0-rc...2.0.0-rc2

Build signatures

The packages are signed with the following OpenPGP key: AD12 7976 5093 C675 9CD8 A400 24A7 7461 6F1E 617E

Don't miss a new nethermind release

NewReleases is sending notifications on new releases.