11 Commits

Author SHA1 Message Date
moudyellaz
124bbee6c6 Merge origin/dev 2026-07-23 23:59:36 +02:00
erhant
8d09ffd733 feat(sequencer): two-tier chain state and multi-sequencer support
Decentralized-sequencing foundation: a shared chain_state crate (two-tier
head/final ChainState, apply_block, AcceptOutcome, StallReason, and the
absorbed channel-consistency machinery), turn-gated block production, the
publisher follow path for adopted/orphaned/finalized peer blocks, and
persistence that keeps disk order equal to apply order under the chain lock.

Rebased onto dev after #600/#606: chain_consistency is absorbed into
chain_state, the sequencer bootstrap's verify_and_reconstruct is re-wired
onto the two-tier ChainState (reconstruction applies channel history
through the final tier and persists via the follow-path primitives), and
test fixtures adopt the SequencerSetup builder extended with
with_bedrock_signing_key.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-23 11:43:57 +03:00
moudyellaz
72195ce09e Merge origin/dev 2026-07-23 02:43:53 +02:00
Daniil Polyakov
2d5489c04e feat(sequencer): bootstrap state from Bedrock 2026-07-21 22:46:25 +03:00
moudyellaz
e278437266 refactor(cross-zone): fund bridge-lock holdings with a real native balance 2026-07-21 18:28:04 +02:00
moudyellaz
a806ebb94a refactor(cross-zone)!: register cross-zone programs as base builtins
BREAKING CHANGE: GenesisAction::DeployProgram and IndexerConfig.deploy_programs are removed. The cross-zone programs (inbox, outbox, ping_sender, ping_receiver, bridge_lock, wrapped_token) are now base builtins in testnet_initial_state, because program bytecode exceeds the genesis block inscription limit, so they cannot be shipped through genesis transactions.
2026-07-21 10:50:41 +02:00
moudyellaz
a16e22c46c refactor!(cross-zone): deploy programs at genesis instead of builtins
Cross-zone builtin programs are no longer registered in the production
genesis. A zone that participates declares the ones it uses via a new
GenesisAction::DeployProgram (sequencer) and a matching deploy_programs
list (indexer), both resolved through CrossZoneProgram and registered
with with_programs. Cross-zone genesis accounts (inbox config,
wrapped-token config) are seeded through the state constructor for a
receiving zone, and bridge-lock holdings are seeded from their actions
regardless of receiving config, dropping V03State::insert_genesis_account.
GenesisAction amounts now use the Balance alias. Documents cross_zone as
the reference LEZ adapter and the bridge demo as not production-safe.

The sequencer's DeployProgram set and the indexer's deploy_programs are
configured separately, so both nodes now log a deterministic genesis
fingerprint (V03State::genesis_fingerprint) at startup: equal values
confirm the two genesis states agree, a mismatch flags a divergent
deploy set.

BREAKING CHANGE: the genesis state root changes (cross-zone builtins are
out of production genesis) and the sequencer/indexer configs gain the
DeployProgram / deploy_programs list that cross-zone-participating zones
must set.
2026-07-13 19:12:24 +02:00
moudyellaz
4f75e29a3c Merge origin/main
Integrates origin/main (per-program-crate refactor) and re-homes the cross-zone messaging feature onto it.

BREAKING CHANGE: Genesis state root changes. This registers six builtin programs
(cross_zone_outbox, cross_zone_inbox, ping_sender, ping_receiver, bridge_lock,
wrapped_token) and seeds their genesis accounts (the wrapped_token authorized
minter config, the per-zone inbox config, and optional bridge-lock holdings).
Building the new cores alongside the existing builtins also enables serde/alloc
for the shared programs build, regenerating every builtin program image id. All
nodes must upgrade together.
2026-07-04 00:47:20 +02:00
moudyellaz
36ed949be0 chore: some cleanup 2026-06-25 09:38:30 +02:00
moudyellaz
ff7610804a feat(cross-zone): pin peer block-signing keys and distinguish verifier lag from forgery 2026-06-25 08:21:49 +02:00
moudyellaz
4fd465b529 test(cross-zone): add lock-on-A mint-on-B bridge round trip 2026-06-24 14:51:52 +02:00