From 9fcacd0f86c1ed7e39ee2ee4ce8f158b2805670c Mon Sep 17 00:00:00 2001 From: Dwi Siswanto <25837540+dwisiswant0@users.noreply.github.com> Date: Sat, 16 Aug 2025 13:20:09 +0700 Subject: [PATCH] ci(tests): migrate to golangci-lint v2 (#6380) * chore: satisfy lints Signed-off-by: Dwi Siswanto * ci(tests): migrate to golangci-lint v2 Signed-off-by: Dwi Siswanto --------- Signed-off-by: Dwi Siswanto --- .github/workflows/tests.yaml | 2 +- pkg/protocols/headless/engine/engine.go | 2 +- pkg/reporting/trackers/linear/linear.go | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/tests.yaml b/.github/workflows/tests.yaml index dce907afb..f8297c107 100644 --- a/.github/workflows/tests.yaml +++ b/.github/workflows/tests.yaml @@ -24,7 +24,7 @@ jobs: steps: - uses: actions/checkout@v4 - uses: projectdiscovery/actions/setup/go@v1 - - uses: projectdiscovery/actions/golangci-lint@v1 + - uses: projectdiscovery/actions/golangci-lint/v2@v1 tests: name: "Tests" diff --git a/pkg/protocols/headless/engine/engine.go b/pkg/protocols/headless/engine/engine.go index 998850237..c045580d6 100644 --- a/pkg/protocols/headless/engine/engine.go +++ b/pkg/protocols/headless/engine/engine.go @@ -181,6 +181,6 @@ func (b *Browser) getHTTPClient() (*http.Client, error) { func (b *Browser) Close() { _ = b.engine.Close() b.launcher.Kill() - os.RemoveAll(b.tempDir) + _ = os.RemoveAll(b.tempDir) processutil.CloseProcesses(processutil.IsChromeProcess, b.previousPIDs) } diff --git a/pkg/reporting/trackers/linear/linear.go b/pkg/reporting/trackers/linear/linear.go index be8723368..75619c140 100644 --- a/pkg/reporting/trackers/linear/linear.go +++ b/pkg/reporting/trackers/linear/linear.go @@ -54,7 +54,7 @@ type Options struct { // New creates a new issue tracker integration client based on options. func New(options *Options) (*Integration, error) { - var transport http.RoundTripper = http.DefaultTransport + var transport = http.DefaultTransport if options.HttpClient != nil && options.HttpClient.HTTPClient.Transport != nil { transport = options.HttpClient.HTTPClient.Transport }