From 3ed6fac961d742f42d7f629d26b1c4509bdf8ebf Mon Sep 17 00:00:00 2001 From: Sai Kumar Date: Thu, 30 Jan 2025 17:35:43 +0530 Subject: [PATCH] fix the lint --- .golangci.yml | 10 +++++----- app/upgrades.go | 2 ++ x/oracle/client/tests/suite.go | 8 -------- 3 files changed, 7 insertions(+), 13 deletions(-) diff --git a/.golangci.yml b/.golangci.yml index cab9995a51..2bd1c15eb4 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -1,9 +1,5 @@ run: tests: false - skip-dirs: - - tests/e2e - - tests/simulation - govet: # Enable analyzers by name (in addition to default). # Run `go tool vet help` to see all analyzers. @@ -24,7 +20,7 @@ linters: # - depguard - dogsled - errcheck - - exportloopref + - copyloopvar - goconst - gocritic - gofmt @@ -49,6 +45,10 @@ linters: - usestdlibvars issues: + exclude-dirs: + - tests/e2e + - tests/simulation + exclude-rules: - path: _test\.go linters: diff --git a/app/upgrades.go b/app/upgrades.go index fe6c840e07..ad28997ab9 100644 --- a/app/upgrades.go +++ b/app/upgrades.go @@ -256,6 +256,8 @@ func (app *UmeeApp) storeUpgrade(planName string, ui upgradetypes.Plan, stores s // registerUpgrade sets an upgrade handler which only runs module migrations // and adds new storages storages +// +//nolint:unparam func (app *UmeeApp) registerUpgrade(planName string, upgradeInfo upgradetypes.Plan, newStores []string, deletedStores []string, renamedStores []storetypes.StoreRename) { app.UpgradeKeeper.SetUpgradeHandler(planName, onlyModuleMigrations(app, planName)) diff --git a/x/oracle/client/tests/suite.go b/x/oracle/client/tests/suite.go index 88c73750a8..f84ef0eaeb 100644 --- a/x/oracle/client/tests/suite.go +++ b/x/oracle/client/tests/suite.go @@ -91,8 +91,6 @@ func (s *IntegrationTestSuite) TestDelegateFeedConsent() { } for _, tc := range testCases { - tc := tc - s.Run(tc.name, func() { clientCtx := val.ClientCtx @@ -148,8 +146,6 @@ func (s *IntegrationTestSuite) TestQueryFeedDelegate() { } for _, tc := range testCases { - tc := tc - s.Run(tc.name, func() { tc.args = append(tc.args, fmt.Sprintf("--%s=json", tmcli.OutputFlag)) out, err := clitestutil.ExecTestCLICmd(clientCtx, cli.QueryFeederDelegation(), tc.args) @@ -219,8 +215,6 @@ func (s *IntegrationTestSuite) TestQueryExchangeRate() { } for _, tc := range testCases { - tc := tc - s.Run(tc.name, func() { out, err := clitestutil.ExecTestCLICmd(clientCtx, cli.QueryExchangeRate(), tc.args) if tc.expectErr { @@ -272,8 +266,6 @@ func (s *IntegrationTestSuite) TestQueryExchangeRateWithTimestamp() { } for _, tc := range testCases { - tc := tc - s.Run(tc.name, func() { out, err := clitestutil.ExecTestCLICmd(clientCtx, cli.QueryExchangeRatesWithTimestamp(), tc.args) if tc.expectErr {