From 01e08a0bf1c3cecbce1b304b9b3f70df5f3283d2 Mon Sep 17 00:00:00 2001 From: 0xFloki Date: Mon, 15 Dec 2025 19:31:46 +0100 Subject: [PATCH] Update filter_system_test.go --- eth/filters/filter_system_test.go | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/eth/filters/filter_system_test.go b/eth/filters/filter_system_test.go index e5a1a2b25f..cf1cf69c02 100644 --- a/eth/filters/filter_system_test.go +++ b/eth/filters/filter_system_test.go @@ -169,7 +169,7 @@ func (b *testBackend) NewMatcherBackend() filtermaps.MatcherBackend { return b.fm.NewMatcherBackend() } -func (b *testBackend) startFilterMaps(history uint64, disabled bool, params filtermaps.Params) { +func (b *testBackend) startFilterMaps(history uint64, disabled bool, params filtermaps.Params) error { head := b.CurrentBlock() chainView := filtermaps.NewChainView(b, head.Number.Uint64(), head.Hash()) config := filtermaps.Config{ @@ -177,9 +177,14 @@ func (b *testBackend) startFilterMaps(history uint64, disabled bool, params filt Disabled: disabled, ExportFileName: "", } - b.fm, _ = filtermaps.NewFilterMaps(b.db, chainView, 0, 0, params, config) + fm, err := filtermaps.NewFilterMaps(b.db, chainView, 0, 0, params, config) + if err != nil { + return err + } + b.fm = fm b.fm.Start() b.fm.WaitIdle() + return nil } func (b *testBackend) stopFilterMaps() { @@ -563,7 +568,9 @@ func TestExceedLogQueryLimit(t *testing.T) { t.Fatal(err) } - backend.startFilterMaps(200, false, filtermaps.RangeTestParams) + if err := backend.startFilterMaps(200, false, filtermaps.RangeTestParams); err != nil { + t.Fatalf("failed to start filter maps: %v", err) + } defer backend.stopFilterMaps() addresses := make([]common.Address, 6)