Skip to content

chore: adjust lint rules and set timeout#2123

Merged
google-oss-prow[bot] merged 1 commit intoGoogleContainerTools:mainfrom
tiffanny29631:lint
Apr 8, 2026
Merged

chore: adjust lint rules and set timeout#2123
google-oss-prow[bot] merged 1 commit intoGoogleContainerTools:mainfrom
tiffanny29631:lint

Conversation

@tiffanny29631
Copy link
Copy Markdown
Contributor

No description provided.

@tiffanny29631 tiffanny29631 requested a review from Camila-B April 8, 2026 22:51
@google-oss-prow google-oss-prow Bot requested a review from janetkuo April 8, 2026 22:51
Copy link
Copy Markdown
Contributor

@Camila-B Camila-B left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

@google-oss-prow
Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: Camila-B

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request reorganizes linting targets in the Makefile and updates the Go linting script to include a 10-minute timeout and support for additional arguments. Feedback suggests moving hardcoded flags from the script to the .golangci.yaml configuration file to adhere to the project's style guide and improve maintainability.

Comment thread scripts/lint-go.sh

echo "Running golangci-lint: "
if ! OUT="$(golangci-lint run --exclude-use-default=false)"; then
if ! OUT="$(golangci-lint run --exclude-use-default=false --timeout=10m "$@")"; then
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

The --timeout and --exclude-use-default flags are hardcoded in this script. According to the repository style guide (line 102), linting configuration should ideally be managed in the .golangci.yaml file. Moving these settings to the configuration file would improve maintainability and ensure consistency across different ways of running the linter (e.g., via IDEs or direct CLI calls).

References
  1. Linting is done with golangci-lint (config in .golangci.yaml, run via make lint-go). (link)

@google-oss-prow google-oss-prow Bot merged commit 11682ae into GoogleContainerTools:main Apr 8, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants