Advanced

Rollups: Optimistic vs ZK Internals — Hands-on lab

Understand scaling choices.

Developer Advanced
6/8 — Rollups: Optimistic vs ZK Internals — Hands-on lab

SimulateWalk through a deposit, batch publish, proof post, and withdrawal with a challenge timer. Flip flags to mimic censorship or DA loss.

ObserveEmit events for batches, proofs, and exits to mirror what explorers show.

Steps
  1. Simulate an optimistic withdrawal:Publish batch → start timer → attempt exit before/after timer.
  2. Simulate a fraud proof:During challenge, post proof and ensure exit is blocked/reverted.
  3. Simulate DA loss:Mark dataUnavailable and block exits until resolved.
  4. Toggle sequencer pause and:Ensure deposits/withdrawals respect it.
  5. Optional:Swap to “validity” mode where proofVerified gates exits immediately.
← Previous section
Next section →