From b25c06532f1dc9aeb57db51b8fe74d8a4b3a304f Mon Sep 17 00:00:00 2001 From: Jim Fasarakis-Hilliard Date: Tue, 22 Aug 2023 17:22:11 +0300 Subject: [PATCH] Bump golangci for callbacks, fix complaints from unparam. (#4417) --- .github/workflows/callbacks.yml | 2 +- modules/apps/callbacks/ibc_middleware_test.go | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/callbacks.yml b/.github/workflows/callbacks.yml index b09c640da01..55d2a4698f2 100644 --- a/.github/workflows/callbacks.yml +++ b/.github/workflows/callbacks.yml @@ -18,7 +18,7 @@ jobs: - uses: actions/checkout@v3 - uses: golangci/golangci-lint-action@v3.7.0 with: - version: v1.53.3 + version: v1.54.2 args: --timeout 5m working-directory: modules/apps/callbacks diff --git a/modules/apps/callbacks/ibc_middleware_test.go b/modules/apps/callbacks/ibc_middleware_test.go index c995450ce50..cb8174b9f15 100644 --- a/modules/apps/callbacks/ibc_middleware_test.go +++ b/modules/apps/callbacks/ibc_middleware_test.go @@ -774,7 +774,7 @@ func (s *CallbacksTestSuite) TestProcessCallback() { func() { executionGas := callbackData.ExecutionGasLimit expGasConsumed = executionGas - callbackExecutor = func(cachedCtx sdk.Context) error { + callbackExecutor = func(cachedCtx sdk.Context) error { //nolint:unparam cachedCtx.GasMeter().ConsumeGas(expGasConsumed+1, "callbackExecutor gas consumption") return nil } @@ -811,7 +811,7 @@ func (s *CallbacksTestSuite) TestProcessCallback() { executionGas := callbackData.ExecutionGasLimit callbackData.CommitGasLimit = executionGas + 1 expGasConsumed = executionGas - callbackExecutor = func(cachedCtx sdk.Context) error { + callbackExecutor = func(cachedCtx sdk.Context) error { //nolint:unparam cachedCtx.GasMeter().ConsumeGas(executionGas+1, "callbackExecutor oog panic") return nil } @@ -843,7 +843,7 @@ func (s *CallbacksTestSuite) TestProcessCallback() { ctx = s.chainB.GetContext() // set a callback executor that will always succeed after consuming expGasConsumed - callbackExecutor = func(cachedCtx sdk.Context) error { + callbackExecutor = func(cachedCtx sdk.Context) error { //nolint:unparam cachedCtx.GasMeter().ConsumeGas(expGasConsumed, "callbackExecutor gas consumption") return nil }