Skip to content

Commit

Permalink
implement
Browse files Browse the repository at this point in the history
  • Loading branch information
0xmountaintop committed Apr 8, 2024
1 parent b4dac7a commit 122cffe
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions rollup/internal/controller/relayer/l2_relayer.go
Original file line number Diff line number Diff line change
Expand Up @@ -461,6 +461,12 @@ func (r *Layer2Relayer) ProcessCommittedBatches() {
}
}

if r.cfg.EnableTestEnvSamplingFeature && ((batch.Index % 100) >= r.cfg.SamplingPercentage) {
if err := r.finalizeBatch(batch, false); err != nil {
log.Error("Failed to finalize skipped batch without proof", "index", batch.Index, "hash", batch.Hash, "err", err)
}
}

case types.ProvingTaskVerified:
log.Info("Start to roll up zk proof", "hash", batch.Hash)
r.metrics.rollupL2RelayerProcessCommittedBatchesFinalizedTotal.Inc()
Expand Down

0 comments on commit 122cffe

Please sign in to comment.