From 1b519dde434639bccbebd679a745e421fb190173 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=96mer=20Faruk=20Irmak?= Date: Tue, 28 May 2024 12:18:29 +0300 Subject: [PATCH 1/2] fix: make sure building of pending blocks don't have any lasting side affects --- miner/scroll_worker.go | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/miner/scroll_worker.go b/miner/scroll_worker.go index 9b7a1b63a6a..bb8da0658c2 100644 --- a/miner/scroll_worker.go +++ b/miner/scroll_worker.go @@ -556,6 +556,14 @@ func (w *worker) startNewPipeline(timestamp int64) { } func (w *worker) handlePipelineResult(res *pipeline.Result) error { + if !w.isRunning() { + if res != nil && res.FinalBlock != nil { + w.updateSnapshot(res.FinalBlock) + } + w.currentPipeline = nil + return nil + } + if res != nil && res.OverflowingTx != nil { if res.FinalBlock == nil { // first txn overflowed the circuit, skip @@ -602,14 +610,6 @@ func (w *worker) handlePipelineResult(res *pipeline.Result) error { } } - if !w.isRunning() { - if res != nil && res.FinalBlock != nil { - w.updateSnapshot(res.FinalBlock) - } - w.currentPipeline = nil - return nil - } - var commitError error if res != nil && res.FinalBlock != nil { if commitError = w.commit(res); commitError == nil { @@ -747,6 +747,10 @@ func (w *worker) postSideBlock(event core.ChainSideEvent) { } func (w *worker) onTxFailingInPipeline(txIndex int, tx *types.Transaction, err error) bool { + if !w.isRunning() { + return false + } + writeTrace := func() { var trace *types.BlockTrace var errWithTrace *pipeline.ErrorWithTrace From 8adab3460592b0c4d6c5d5f20306c0a6d3b111f1 Mon Sep 17 00:00:00 2001 From: omerfirmak Date: Tue, 28 May 2024 09:26:49 +0000 Subject: [PATCH 2/2] =?UTF-8?q?chore:=20auto=20version=20bump=E2=80=89[bot?= =?UTF-8?q?]?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- params/version.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/params/version.go b/params/version.go index 9f991beae3f..4146d57d012 100644 --- a/params/version.go +++ b/params/version.go @@ -24,7 +24,7 @@ import ( const ( VersionMajor = 5 // Major version component of the current release VersionMinor = 3 // Minor version component of the current release - VersionPatch = 24 // Patch version component of the current release + VersionPatch = 25 // Patch version component of the current release VersionMeta = "mainnet" // Version metadata to append to the version string )