Skip to content

test: check error-channel receives (golangci-lint v2.15 errcheck) - #551

Open
almeidapaulopt wants to merge 1 commit into
mainfrom
fix/errcheck-v2.15-base
Open

almeidapaulopt wants to merge 1 commit into
mainfrom
fix/errcheck-v2.15-base

Conversation

@almeidapaulopt

Copy link
Copy Markdown
Owner

Why

The build workflow runs golangci-lint latest, which rolled to v2.15.0 on Oct 19. v2.15.0's errcheck now flags unchecked receives from chan error — and main carries 6 such sites in test files, so every fresh PR build fails at Lint (first seen on #548, which only touches web/package.json/bun.lock — the failure is base drift, not that bump).

What

Bind and handle (or explicitly discard with a rationale comment) every chan error receive:

  • internal/proxyproviders/tailscale/service_proxy_test.go — 2× <-startDone after unblocking Start(): now asserts the error
  • internal/targetproviders/docker/docker_test.go — case <-errChan: now includes the error in the Fatal message
  • internal/proxymanager/port_test.go — 4 sites: 2× <-errCh after close (now assert), 1× cancellation-expected select (bound + discarded), 1× shutdown-error select (bound + discarded)
  • internal/proxymanager/concurrency_test.go — case <-restartDone now includes the error in the Fatal message

Note: golangci-lint's default max-same-issues: 3 hid the second wave; this fixes all sites, verified with a full-repo run.

Verification

  • golangci-lint run ./... @ v2.15.0 (CI parity): 0 issues
  • go test ./...: 25/25 packages ok

Unblocks #548 (rebase/re-run after this lands) and restores the lint gate for all open PRs.

golangci-lint v2.15.0 flags unchecked receives from chan error. Bind and
handle (or explicitly discard with rationale) at all sites, unblocking
the build workflow for every open PR (incl. #548).

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant