From 4c0a860417feeb61f787f74c9e84deef0f6528ba Mon Sep 17 00:00:00 2001 From: Jordan Krage Date: Thu, 4 Apr 2024 18:05:39 -0500 Subject: [PATCH] support cosmos as LOOP Plugin --- core/scripts/go.mod | 2 +- core/scripts/go.sum | 4 ++-- .../plugins/ccip/testhelpers/testhelpers_1_4_0/chainlink.go | 4 ++-- core/services/pg/locked_db.go | 2 +- deployment/go.mod | 2 +- deployment/go.sum | 4 ++-- go.mod | 2 +- go.sum | 4 ++-- integration-tests/go.mod | 2 +- integration-tests/go.sum | 4 ++-- integration-tests/load/go.mod | 2 +- integration-tests/load/go.sum | 4 ++-- plugins/loop_registry_test.go | 1 + 13 files changed, 19 insertions(+), 18 deletions(-) diff --git a/core/scripts/go.mod b/core/scripts/go.mod index 8d27b34a408..9d753e8c9e6 100644 --- a/core/scripts/go.mod +++ b/core/scripts/go.mod @@ -317,7 +317,7 @@ require ( github.com/smartcontractkit/chain-selectors v1.0.36 // indirect github.com/smartcontractkit/chainlink-ccip v0.0.0-20250120130359-cc025272bbff // indirect github.com/smartcontractkit/chainlink-ccip/chains/solana v0.0.0-20250103152858-8973fd0c912b // indirect - github.com/smartcontractkit/chainlink-cosmos v0.5.2-0.20241202195413-82468150ac1e // indirect + github.com/smartcontractkit/chainlink-cosmos v0.5.2-0.20250121004409-173751e0df94 // indirect github.com/smartcontractkit/chainlink-feeds v0.1.1 // indirect github.com/smartcontractkit/chainlink-framework/multinode v0.0.0-20250115203616-a2ea5e50b260 // indirect github.com/smartcontractkit/chainlink-protos/job-distributor v0.6.0 // indirect diff --git a/core/scripts/go.sum b/core/scripts/go.sum index ea7caabf6bc..e32e99b6c2d 100644 --- a/core/scripts/go.sum +++ b/core/scripts/go.sum @@ -1174,8 +1174,8 @@ github.com/smartcontractkit/chainlink-ccip/chains/solana v0.0.0-20250103152858-8 github.com/smartcontractkit/chainlink-ccip/chains/solana v0.0.0-20250103152858-8973fd0c912b/go.mod h1:Bmwq4lNb5tE47sydN0TKetcLEGbgl+VxHEWp4S0LI60= github.com/smartcontractkit/chainlink-common v0.4.2-0.20250120234027-b107f5b7f03d h1:GVLCIxZDTwrxYoKq4NBZ8pMKlKtY1q/N9s15Qu4Kuio= github.com/smartcontractkit/chainlink-common v0.4.2-0.20250120234027-b107f5b7f03d/go.mod h1:V3BHfvLnQNBUoZ4bGjD29ZPhyzPE++DkYkhvPb9tcRs= -github.com/smartcontractkit/chainlink-cosmos v0.5.2-0.20241202195413-82468150ac1e h1:PRoeby6ZlTuTkv2f+7tVU4+zboTfRzI+beECynF4JQ0= -github.com/smartcontractkit/chainlink-cosmos v0.5.2-0.20241202195413-82468150ac1e/go.mod h1:mUh5/woemsVaHgTorA080hrYmO3syBCmPdnWc/5dOqk= +github.com/smartcontractkit/chainlink-cosmos v0.5.2-0.20250121004409-173751e0df94 h1:yHtfNM+btEBfhqQCYG8hYj3R7bMCmSnAiZ7kzKMVa/U= +github.com/smartcontractkit/chainlink-cosmos v0.5.2-0.20250121004409-173751e0df94/go.mod h1:w2mT+MIiZ2w9d/yb2GfsDKgOuF1kmMcFZ18NTtGECnE= github.com/smartcontractkit/chainlink-data-streams v0.1.1-0.20250115135646-ac859d85e7e3 h1:GcPYNVFYjB065CNq0h8nK/VeU08nUkHgBX0cJIEpuHY= github.com/smartcontractkit/chainlink-data-streams v0.1.1-0.20250115135646-ac859d85e7e3/go.mod h1:pDZagSGjs9U+l4YIFhveDznMHqxuuz+5vRxvVgpbdr8= github.com/smartcontractkit/chainlink-feeds v0.1.1 h1:JzvUOM/OgGQA1sOqTXXl52R6AnNt+Wg64sVG+XSA49c= diff --git a/core/services/ocr2/plugins/ccip/testhelpers/testhelpers_1_4_0/chainlink.go b/core/services/ocr2/plugins/ccip/testhelpers/testhelpers_1_4_0/chainlink.go index cec58136b5c..91592000420 100644 --- a/core/services/ocr2/plugins/ccip/testhelpers/testhelpers_1_4_0/chainlink.go +++ b/core/services/ocr2/plugins/ccip/testhelpers/testhelpers_1_4_0/chainlink.go @@ -460,7 +460,7 @@ func setupNodeCCIP( }, CSAETHKeystore: simEthKeyStore, } - loopRegistry := plugins.NewLoopRegistry(lggr.Named("LoopRegistry"), config.Tracing(), config.Telemetry(), nil, "") + loopRegistry := plugins.NewLoopRegistry(lggr.Named("LoopRegistry"), config.Database(), config.Tracing(), config.Telemetry(), nil, "") relayerFactory := chainlink.RelayerFactory{ Logger: lggr, LoopRegistry: loopRegistry, @@ -490,7 +490,7 @@ func setupNodeCCIP( RestrictedHTTPClient: &http.Client{}, AuditLogger: audit.NoopLogger, MailMon: mailMon, - LoopRegistry: plugins.NewLoopRegistry(lggr, config.Tracing(), config.Telemetry(), nil, ""), + LoopRegistry: plugins.NewLoopRegistry(lggr, config.Database(), config.Tracing(), config.Telemetry(), nil, ""), }) ctx := testutils.Context(t) require.NoError(t, err) diff --git a/core/services/pg/locked_db.go b/core/services/pg/locked_db.go index a3101f7385b..4bbca963770 100644 --- a/core/services/pg/locked_db.go +++ b/core/services/pg/locked_db.go @@ -71,7 +71,7 @@ func (l *lockedDb) Open(ctx context.Context) (err error) { } revert := func() { // Let Open() return the actual error, while l.Close() error is just logged. - if err2 := l.close(); err2 != nil { + if err2 := l.Close(); err2 != nil { l.lggr.Errorf("failed to cleanup LockedDB: %v", err2) } } diff --git a/deployment/go.mod b/deployment/go.mod index bc6890de4c5..ede1cc872ba 100644 --- a/deployment/go.mod +++ b/deployment/go.mod @@ -418,7 +418,7 @@ require ( github.com/shopspring/decimal v1.4.0 // indirect github.com/sirupsen/logrus v1.9.3 // indirect github.com/smartcontractkit/chainlink-automation v0.8.1 // indirect - github.com/smartcontractkit/chainlink-cosmos v0.5.2-0.20241202195413-82468150ac1e // indirect + github.com/smartcontractkit/chainlink-cosmos v0.5.2-0.20250121004409-173751e0df94 // indirect github.com/smartcontractkit/chainlink-data-streams v0.1.1-0.20250115135646-ac859d85e7e3 // indirect github.com/smartcontractkit/chainlink-feeds v0.1.1 // indirect github.com/smartcontractkit/chainlink-framework/multinode v0.0.0-20250115203616-a2ea5e50b260 // indirect diff --git a/deployment/go.sum b/deployment/go.sum index b6a9571ad79..413b91d615e 100644 --- a/deployment/go.sum +++ b/deployment/go.sum @@ -1400,8 +1400,8 @@ github.com/smartcontractkit/chainlink-ccip/chains/solana v0.0.0-20250103152858-8 github.com/smartcontractkit/chainlink-ccip/chains/solana v0.0.0-20250103152858-8973fd0c912b/go.mod h1:Bmwq4lNb5tE47sydN0TKetcLEGbgl+VxHEWp4S0LI60= github.com/smartcontractkit/chainlink-common v0.4.2-0.20250120234027-b107f5b7f03d h1:GVLCIxZDTwrxYoKq4NBZ8pMKlKtY1q/N9s15Qu4Kuio= github.com/smartcontractkit/chainlink-common v0.4.2-0.20250120234027-b107f5b7f03d/go.mod h1:V3BHfvLnQNBUoZ4bGjD29ZPhyzPE++DkYkhvPb9tcRs= -github.com/smartcontractkit/chainlink-cosmos v0.5.2-0.20241202195413-82468150ac1e h1:PRoeby6ZlTuTkv2f+7tVU4+zboTfRzI+beECynF4JQ0= -github.com/smartcontractkit/chainlink-cosmos v0.5.2-0.20241202195413-82468150ac1e/go.mod h1:mUh5/woemsVaHgTorA080hrYmO3syBCmPdnWc/5dOqk= +github.com/smartcontractkit/chainlink-cosmos v0.5.2-0.20250121004409-173751e0df94 h1:yHtfNM+btEBfhqQCYG8hYj3R7bMCmSnAiZ7kzKMVa/U= +github.com/smartcontractkit/chainlink-cosmos v0.5.2-0.20250121004409-173751e0df94/go.mod h1:w2mT+MIiZ2w9d/yb2GfsDKgOuF1kmMcFZ18NTtGECnE= github.com/smartcontractkit/chainlink-data-streams v0.1.1-0.20250115135646-ac859d85e7e3 h1:GcPYNVFYjB065CNq0h8nK/VeU08nUkHgBX0cJIEpuHY= github.com/smartcontractkit/chainlink-data-streams v0.1.1-0.20250115135646-ac859d85e7e3/go.mod h1:pDZagSGjs9U+l4YIFhveDznMHqxuuz+5vRxvVgpbdr8= github.com/smartcontractkit/chainlink-feeds v0.1.1 h1:JzvUOM/OgGQA1sOqTXXl52R6AnNt+Wg64sVG+XSA49c= diff --git a/go.mod b/go.mod index 69b8db8a69d..5aec21679df 100644 --- a/go.mod +++ b/go.mod @@ -80,7 +80,7 @@ require ( github.com/smartcontractkit/chainlink-automation v0.8.1 github.com/smartcontractkit/chainlink-ccip v0.0.0-20250120130359-cc025272bbff github.com/smartcontractkit/chainlink-common v0.4.2-0.20250120234027-b107f5b7f03d - github.com/smartcontractkit/chainlink-cosmos v0.5.2-0.20241202195413-82468150ac1e + github.com/smartcontractkit/chainlink-cosmos v0.5.2-0.20250121004409-173751e0df94 github.com/smartcontractkit/chainlink-data-streams v0.1.1-0.20250115135646-ac859d85e7e3 github.com/smartcontractkit/chainlink-feeds v0.1.1 github.com/smartcontractkit/chainlink-framework/multinode v0.0.0-20250115203616-a2ea5e50b260 diff --git a/go.sum b/go.sum index ccf1da6291d..2f693bd0a92 100644 --- a/go.sum +++ b/go.sum @@ -1156,8 +1156,8 @@ github.com/smartcontractkit/chainlink-ccip v0.0.0-20250120130359-cc025272bbff h1 github.com/smartcontractkit/chainlink-ccip v0.0.0-20250120130359-cc025272bbff/go.mod h1:JJZMCB75aVSAiPNW032F9WUKTlLztTd8bbQB5MEaZa4= github.com/smartcontractkit/chainlink-common v0.4.2-0.20250120234027-b107f5b7f03d h1:GVLCIxZDTwrxYoKq4NBZ8pMKlKtY1q/N9s15Qu4Kuio= github.com/smartcontractkit/chainlink-common v0.4.2-0.20250120234027-b107f5b7f03d/go.mod h1:V3BHfvLnQNBUoZ4bGjD29ZPhyzPE++DkYkhvPb9tcRs= -github.com/smartcontractkit/chainlink-cosmos v0.5.2-0.20241202195413-82468150ac1e h1:PRoeby6ZlTuTkv2f+7tVU4+zboTfRzI+beECynF4JQ0= -github.com/smartcontractkit/chainlink-cosmos v0.5.2-0.20241202195413-82468150ac1e/go.mod h1:mUh5/woemsVaHgTorA080hrYmO3syBCmPdnWc/5dOqk= +github.com/smartcontractkit/chainlink-cosmos v0.5.2-0.20250121004409-173751e0df94 h1:yHtfNM+btEBfhqQCYG8hYj3R7bMCmSnAiZ7kzKMVa/U= +github.com/smartcontractkit/chainlink-cosmos v0.5.2-0.20250121004409-173751e0df94/go.mod h1:w2mT+MIiZ2w9d/yb2GfsDKgOuF1kmMcFZ18NTtGECnE= github.com/smartcontractkit/chainlink-data-streams v0.1.1-0.20250115135646-ac859d85e7e3 h1:GcPYNVFYjB065CNq0h8nK/VeU08nUkHgBX0cJIEpuHY= github.com/smartcontractkit/chainlink-data-streams v0.1.1-0.20250115135646-ac859d85e7e3/go.mod h1:pDZagSGjs9U+l4YIFhveDznMHqxuuz+5vRxvVgpbdr8= github.com/smartcontractkit/chainlink-feeds v0.1.1 h1:JzvUOM/OgGQA1sOqTXXl52R6AnNt+Wg64sVG+XSA49c= diff --git a/integration-tests/go.mod b/integration-tests/go.mod index 9c70e07c240..3b38bf7c0a4 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -433,7 +433,7 @@ require ( github.com/sirupsen/logrus v1.9.3 // indirect github.com/smartcontractkit/ccip-owner-contracts v0.0.0-salt-fix // indirect github.com/smartcontractkit/chainlink-ccip/chains/solana v0.0.0-20250103152858-8973fd0c912b // indirect - github.com/smartcontractkit/chainlink-cosmos v0.5.2-0.20241202195413-82468150ac1e // indirect + github.com/smartcontractkit/chainlink-cosmos v0.5.2-0.20250121004409-173751e0df94 // indirect github.com/smartcontractkit/chainlink-data-streams v0.1.1-0.20250115135646-ac859d85e7e3 // indirect github.com/smartcontractkit/chainlink-feeds v0.1.1 // indirect github.com/smartcontractkit/chainlink-framework/multinode v0.0.0-20250115203616-a2ea5e50b260 // indirect diff --git a/integration-tests/go.sum b/integration-tests/go.sum index c3450663276..ec9c779525b 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -1424,8 +1424,8 @@ github.com/smartcontractkit/chainlink-ccip/chains/solana v0.0.0-20250103152858-8 github.com/smartcontractkit/chainlink-ccip/chains/solana v0.0.0-20250103152858-8973fd0c912b/go.mod h1:Bmwq4lNb5tE47sydN0TKetcLEGbgl+VxHEWp4S0LI60= github.com/smartcontractkit/chainlink-common v0.4.2-0.20250120234027-b107f5b7f03d h1:GVLCIxZDTwrxYoKq4NBZ8pMKlKtY1q/N9s15Qu4Kuio= github.com/smartcontractkit/chainlink-common v0.4.2-0.20250120234027-b107f5b7f03d/go.mod h1:V3BHfvLnQNBUoZ4bGjD29ZPhyzPE++DkYkhvPb9tcRs= -github.com/smartcontractkit/chainlink-cosmos v0.5.2-0.20241202195413-82468150ac1e h1:PRoeby6ZlTuTkv2f+7tVU4+zboTfRzI+beECynF4JQ0= -github.com/smartcontractkit/chainlink-cosmos v0.5.2-0.20241202195413-82468150ac1e/go.mod h1:mUh5/woemsVaHgTorA080hrYmO3syBCmPdnWc/5dOqk= +github.com/smartcontractkit/chainlink-cosmos v0.5.2-0.20250121004409-173751e0df94 h1:yHtfNM+btEBfhqQCYG8hYj3R7bMCmSnAiZ7kzKMVa/U= +github.com/smartcontractkit/chainlink-cosmos v0.5.2-0.20250121004409-173751e0df94/go.mod h1:w2mT+MIiZ2w9d/yb2GfsDKgOuF1kmMcFZ18NTtGECnE= github.com/smartcontractkit/chainlink-data-streams v0.1.1-0.20250115135646-ac859d85e7e3 h1:GcPYNVFYjB065CNq0h8nK/VeU08nUkHgBX0cJIEpuHY= github.com/smartcontractkit/chainlink-data-streams v0.1.1-0.20250115135646-ac859d85e7e3/go.mod h1:pDZagSGjs9U+l4YIFhveDznMHqxuuz+5vRxvVgpbdr8= github.com/smartcontractkit/chainlink-feeds v0.1.1 h1:JzvUOM/OgGQA1sOqTXXl52R6AnNt+Wg64sVG+XSA49c= diff --git a/integration-tests/load/go.mod b/integration-tests/load/go.mod index d57568a17a7..5f8360b3705 100644 --- a/integration-tests/load/go.mod +++ b/integration-tests/load/go.mod @@ -416,7 +416,7 @@ require ( github.com/smartcontractkit/chain-selectors v1.0.36 // indirect github.com/smartcontractkit/chainlink-automation v0.8.1 // indirect github.com/smartcontractkit/chainlink-ccip v0.0.0-20250120130359-cc025272bbff // indirect - github.com/smartcontractkit/chainlink-cosmos v0.5.2-0.20241202195413-82468150ac1e // indirect + github.com/smartcontractkit/chainlink-cosmos v0.5.2-0.20250121004409-173751e0df94 // indirect github.com/smartcontractkit/chainlink-data-streams v0.1.1-0.20250115135646-ac859d85e7e3 // indirect github.com/smartcontractkit/chainlink-feeds v0.1.1 // indirect github.com/smartcontractkit/chainlink-framework/multinode v0.0.0-20250115203616-a2ea5e50b260 // indirect diff --git a/integration-tests/load/go.sum b/integration-tests/load/go.sum index b1f241af5ee..9b19f57d793 100644 --- a/integration-tests/load/go.sum +++ b/integration-tests/load/go.sum @@ -1409,8 +1409,8 @@ github.com/smartcontractkit/chainlink-ccip v0.0.0-20250120130359-cc025272bbff h1 github.com/smartcontractkit/chainlink-ccip v0.0.0-20250120130359-cc025272bbff/go.mod h1:JJZMCB75aVSAiPNW032F9WUKTlLztTd8bbQB5MEaZa4= github.com/smartcontractkit/chainlink-common v0.4.2-0.20250120234027-b107f5b7f03d h1:GVLCIxZDTwrxYoKq4NBZ8pMKlKtY1q/N9s15Qu4Kuio= github.com/smartcontractkit/chainlink-common v0.4.2-0.20250120234027-b107f5b7f03d/go.mod h1:V3BHfvLnQNBUoZ4bGjD29ZPhyzPE++DkYkhvPb9tcRs= -github.com/smartcontractkit/chainlink-cosmos v0.5.2-0.20241202195413-82468150ac1e h1:PRoeby6ZlTuTkv2f+7tVU4+zboTfRzI+beECynF4JQ0= -github.com/smartcontractkit/chainlink-cosmos v0.5.2-0.20241202195413-82468150ac1e/go.mod h1:mUh5/woemsVaHgTorA080hrYmO3syBCmPdnWc/5dOqk= +github.com/smartcontractkit/chainlink-cosmos v0.5.2-0.20250121004409-173751e0df94 h1:yHtfNM+btEBfhqQCYG8hYj3R7bMCmSnAiZ7kzKMVa/U= +github.com/smartcontractkit/chainlink-cosmos v0.5.2-0.20250121004409-173751e0df94/go.mod h1:w2mT+MIiZ2w9d/yb2GfsDKgOuF1kmMcFZ18NTtGECnE= github.com/smartcontractkit/chainlink-data-streams v0.1.1-0.20250115135646-ac859d85e7e3 h1:GcPYNVFYjB065CNq0h8nK/VeU08nUkHgBX0cJIEpuHY= github.com/smartcontractkit/chainlink-data-streams v0.1.1-0.20250115135646-ac859d85e7e3/go.mod h1:pDZagSGjs9U+l4YIFhveDznMHqxuuz+5vRxvVgpbdr8= github.com/smartcontractkit/chainlink-feeds v0.1.1 h1:JzvUOM/OgGQA1sOqTXXl52R6AnNt+Wg64sVG+XSA49c= diff --git a/plugins/loop_registry_test.go b/plugins/loop_registry_test.go index f78f2d8c9c2..e814b268ac1 100644 --- a/plugins/loop_registry_test.go +++ b/plugins/loop_registry_test.go @@ -8,6 +8,7 @@ import ( "github.com/stretchr/testify/require" "github.com/smartcontractkit/chainlink-common/pkg/loop" + "github.com/smartcontractkit/chainlink/v2/core/config" "github.com/smartcontractkit/chainlink/v2/core/logger" )