From 7ff93ca224f8128f6f3685879226a489eba64d3b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=96mer=20Faruk=20Irmak?= Date: Fri, 20 Sep 2024 17:19:50 +0300 Subject: [PATCH] fix: initialize pending block with an empty block (#1052) --- miner/scroll_worker.go | 4 ++++ params/version.go | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/miner/scroll_worker.go b/miner/scroll_worker.go index 293c4398f2..02f331bc20 100644 --- a/miner/scroll_worker.go +++ b/miner/scroll_worker.go @@ -507,6 +507,10 @@ func (w *worker) newWork(now time.Time, parentHash common.Hash, reorging bool, r reorging: reorging, reorgReason: reorgReason, } + + // initiliaze pending block with an empty block to make sure we always have + // a pending block to serve RPC requests + w.updateSnapshot() return nil } diff --git a/params/version.go b/params/version.go index ec3dfc492e..dec887edfc 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 = 7 // Minor version component of the current release - VersionPatch = 20 // Patch version component of the current release + VersionPatch = 21 // Patch version component of the current release VersionMeta = "mainnet" // Version metadata to append to the version string )