• Joshua Gutow's avatar
    Op Node: Fix one reorg bug (#2956) · 3855d105
    Joshua Gutow authored
    The `unsafeHead` or `l2Head` is state managed between two separate
    processes: the driver state loop and the derivation pipeline. It
    is updated during a reorg, during block creation, or during p2p
    payload insertion. What happened is that during block creation
    the state loop would inform the derivation pipeline of the new
    unsafe L2 head; however it was using an old value. This would
    cause the communication back from the pipeline to use an old
    unsafe head during the setting inside the state loop. Then
    the state loop would create a new L2 block with the same L2 parent
    thus causing an inadvertent chain reorganization.
    
    This commit also reverts the very significant increase in sequencer
    drift to a more reasonable value.
    Co-authored-by: default avatarmergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
    3855d105
devnetL1.ts 1.75 KB