Skip to content

lint: dev-tagged files are never linted or vetted #246

Open

Description

@avi-papineni

make lint runs golangci-lint run ./... with no build tags, and .golangci.yml sets no run.build-tags, so files behind //go:build dev are never linted or vetted. Today that is cmd/innerwall/dev.go (innerwall dev seed and innerwall dev reset). CI's build job compiles the dev variant (go build -tags dev ./cmd/innerwall), so a compile error is caught, but nothing the linters enforce elsewhere (errorlint, gosec, revive's exported rule, unparam, vet's checks) reaches that file.

Possible fix: add dev to run.build-tags in the golangci-lint config, so both runDev variants are linted (the !dev stub in dev_release.go would then be the one left out; a second lint pass with the tag is the alternative if both must be covered).


Generated by Claude Code

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions