Skip to content

lint: gosec leaves the backlog - #89

Merged
closer-claudio merged 1 commit into
mainfrom
claudio/20261115-lint-gosec
Nov 16, 2026
Merged

closer-claudio merged 1 commit into
mainfrom
claudio/20261115-lint-gosec

Conversation

@closer-claudio

Copy link
Copy Markdown

🎯 Why

gosec was exempted in git/commits.go when the repository came under the lint baseline, for eight launches of git with arguments that are not constants (#37). The package has since come to launch git in one place, command, and that is the one finding left: G204, a subprocess launched with a variable.

🛠️ What

  • .lint-go.yaml: gosec leaves the backlog.
  • git/commits.go: the finding is right as it is, and is silenced inline, by its rule, with the reason. The program is the constant git. Its arguments are the subcommands this file writes, the commits git itself named, and the range the operator gave: by --range, or by the variables of their CI that the command reads (TRAVIS_COMMIT_RANGE, TRAVIS_COMMIT, GITHUB_SHA). It reaches git as it would if they had typed it there.

🧪 How

  1. No behaviour changes.

V: just lint and just test green on the branch (62 tests).

📝 Notes

For #37.

gosec was exempted in git/commits.go at enrolment, for eight launches
of git with arguments that are not constants. The package has since
come to launch git in one place, command, and that is the one finding
left: G204, a subprocess launched with a variable.

It is right as it is. The program is the constant git. Its arguments
are the subcommands this file writes, the commits git itself named,
and the range the operator gave: by --range, or by the variables of
their CI that the command reads (TRAVIS_COMMIT_RANGE, TRAVIS_COMMIT,
GITHUB_SHA). It reaches git as it would if they had typed it there.
The finding is silenced inline, by its rule, saying so.

No behaviour changes.

For #37.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Signed-off-by: closer-claudio <claudio@farcloser.world>
@closer-claudio closer-claudio added the internal Changes nothing for a consumer: tooling, CI, maintainers' docs; left out of the notes label Nov 16, 2026
@closer-claudio

Copy link
Copy Markdown
Author

Reviewed at 1d6ec9b

1 similar comment
@closer-claudio

Copy link
Copy Markdown
Author

Reviewed at 1d6ec9b

@closer-claudio
closer-claudio merged commit 9f8c8ed into main Nov 16, 2026
14 checks passed
@closer-claudio
closer-claudio deleted the claudio/20261115-lint-gosec branch November 16, 2026 02:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

internal Changes nothing for a consumer: tooling, CI, maintainers' docs; left out of the notes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants