Skip to content

Commit 04515e6

Browse files
committed
core/services/ocr2/plugins/ocr2keeper/evmregistry/upkeepstate: fix test race; bump common to expose more races
1 parent added7d commit 04515e6

15 files changed

Lines changed: 28 additions & 22 deletions

File tree

core/scripts/go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ require (
4646
github.com/smartcontractkit/chain-selectors v1.0.98
4747
github.com/smartcontractkit/chainlink-automation v0.8.1
4848
github.com/smartcontractkit/chainlink-ccip/chains/evm v0.0.0-20260415165642-49f23e4d76cc
49-
github.com/smartcontractkit/chainlink-common v0.11.2-0.20260417145954-cd522c53ee6e
49+
github.com/smartcontractkit/chainlink-common v0.11.2-0.20260420165928-c51b9c4d2148
5050
github.com/smartcontractkit/chainlink-common/keystore v1.0.2
5151
github.com/smartcontractkit/chainlink-data-streams v0.1.13
5252
github.com/smartcontractkit/chainlink-deployments-framework v0.95.0

core/scripts/go.sum

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

core/services/ocr2/plugins/ocr2keeper/evmregistry/v21/upkeepstate/store_test.go

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -364,7 +364,7 @@ func TestUpkeepStateStore_SetSelectIntegration(t *testing.T) {
364364
}
365365

366366
// empty the cache before doing selects to force a db lookup
367-
store.cache = make(map[string]*upkeepStateRecord)
367+
store.clearCache()
368368

369369
states, err := store.SelectByWorkIDs(ctx, test.queryIDs...)
370370

@@ -379,6 +379,12 @@ func TestUpkeepStateStore_SetSelectIntegration(t *testing.T) {
379379
}
380380
}
381381

382+
func (u *upkeepStateStore) clearCache() {
383+
u.mu.Lock()
384+
defer u.mu.Unlock()
385+
u.cache = make(map[string]*upkeepStateRecord)
386+
}
387+
382388
func TestUpkeepStateStore_emptyDB(t *testing.T) {
383389
t.Run("querying non-stored workIDs on empty db returns unknown state results", func(t *testing.T) {
384390
lggr, observedLogs := logger.TestLoggerObserved(t, zapcore.ErrorLevel)

deployment/go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ require (
4343
github.com/smartcontractkit/chainlink-ccip/chains/solana v0.0.0-20260415165642-49f23e4d76cc
4444
github.com/smartcontractkit/chainlink-ccip/chains/solana/gobindings v0.0.0-20260415165642-49f23e4d76cc
4545
github.com/smartcontractkit/chainlink-ccip/deployment v0.0.0-20260415165642-49f23e4d76cc
46-
github.com/smartcontractkit/chainlink-common v0.11.2-0.20260417145954-cd522c53ee6e
46+
github.com/smartcontractkit/chainlink-common v0.11.2-0.20260420165928-c51b9c4d2148
4747
github.com/smartcontractkit/chainlink-common/keystore v1.0.2
4848
github.com/smartcontractkit/chainlink-deployments-framework v0.95.0
4949
github.com/smartcontractkit/chainlink-evm v0.3.4-0.20260416173445-80f6efde0a03

deployment/go.sum

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ require (
8686
github.com/smartcontractkit/chainlink-ccip/chains/solana v0.0.0-20260415165642-49f23e4d76cc
8787
github.com/smartcontractkit/chainlink-ccip/chains/solana/gobindings v0.0.0-20260415165642-49f23e4d76cc
8888
github.com/smartcontractkit/chainlink-ccv v0.0.0-20260408181529-b5080e662563
89-
github.com/smartcontractkit/chainlink-common v0.11.2-0.20260417145954-cd522c53ee6e
89+
github.com/smartcontractkit/chainlink-common v0.11.2-0.20260420165928-c51b9c4d2148
9090
github.com/smartcontractkit/chainlink-common/keystore v1.0.2
9191
github.com/smartcontractkit/chainlink-common/pkg/chipingress v0.0.10
9292
github.com/smartcontractkit/chainlink-data-streams v0.1.13

go.sum

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

integration-tests/go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ require (
3232
github.com/smartcontractkit/chainlink-ccip/chains/evm v0.0.0-20260415165642-49f23e4d76cc
3333
github.com/smartcontractkit/chainlink-ccip/chains/solana v0.0.0-20260415165642-49f23e4d76cc
3434
github.com/smartcontractkit/chainlink-ccip/chains/solana/gobindings v0.0.0-20260415165642-49f23e4d76cc
35-
github.com/smartcontractkit/chainlink-common v0.11.2-0.20260417145954-cd522c53ee6e
35+
github.com/smartcontractkit/chainlink-common v0.11.2-0.20260420165928-c51b9c4d2148
3636
github.com/smartcontractkit/chainlink-common/keystore v1.0.2
3737
github.com/smartcontractkit/chainlink-deployments-framework v0.95.0
3838
github.com/smartcontractkit/chainlink-evm v0.3.4-0.20260416173445-80f6efde0a03

integration-tests/go.sum

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

integration-tests/load/go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ require (
2020
github.com/smartcontractkit/chainlink-ccip/chains/evm v0.0.0-20260415165642-49f23e4d76cc
2121
github.com/smartcontractkit/chainlink-ccip/chains/solana v0.0.0-20260415165642-49f23e4d76cc
2222
github.com/smartcontractkit/chainlink-ccip/chains/solana/gobindings v0.0.0-20260415165642-49f23e4d76cc
23-
github.com/smartcontractkit/chainlink-common v0.11.2-0.20260417145954-cd522c53ee6e
23+
github.com/smartcontractkit/chainlink-common v0.11.2-0.20260420165928-c51b9c4d2148
2424
github.com/smartcontractkit/chainlink-deployments-framework v0.95.0
2525
github.com/smartcontractkit/chainlink-evm v0.3.4-0.20260416173445-80f6efde0a03
2626
github.com/smartcontractkit/chainlink-testing-framework/framework v0.15.16

0 commit comments

Comments
 (0)