Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable gci correctly #1671

Merged
merged 1 commit into from
Feb 12, 2025
Merged

Enable gci correctly #1671

merged 1 commit into from
Feb 12, 2025

Conversation

shuheiktgw
Copy link
Contributor

What does this PR do?

Even though the gci configuration exists in .golangci.toml, GCI itself has been disabled. I believe it would be better if we could enforce some rules on import statements and automatically lint and format them.

Thanks for your review!

Motivation

Lint & sort the import statements automatically.

Checklist

  • PR has at least one valid label: bug, enhancement, refactoring, documentation, tooling, and/or dependencies
  • PR has a milestone or the qa/skip-qa label

@shuheiktgw shuheiktgw requested review from a team as code owners February 8, 2025 16:27
@shuheiktgw
Copy link
Contributor Author

I don't have permission to attach labels so could anybody help me attach appropriate labels to the PR?

@codecov-commenter
Copy link

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 49.32%. Comparing base (0300de3) to head (80e9a4c).

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##             main    #1671   +/-   ##
=======================================
  Coverage   49.32%   49.32%           
=======================================
  Files         218      218           
  Lines       21171    21171           
=======================================
  Hits        10442    10442           
  Misses      10184    10184           
  Partials      545      545           
Flag Coverage Δ
unittests 49.32% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
cmd/check-operator/main.go 0.00% <ø> (ø)
cmd/check-operator/upgrade/upgrade.go 0.00% <ø> (ø)
cmd/helpers/main.go 0.00% <ø> (ø)
cmd/helpers/secrets/secrets.go 0.00% <ø> (ø)
cmd/kubectl-datadog/agent/agent/agent.go 0.00% <ø> (ø)
cmd/kubectl-datadog/agent/check/check.go 9.22% <ø> (ø)
cmd/kubectl-datadog/agent/find/find.go 0.00% <ø> (ø)
cmd/kubectl-datadog/agent/upgrade/upgrade.go 12.64% <ø> (ø)
...-datadog/clusteragent/clusteragent/clusteragent.go 0.00% <ø> (ø)
cmd/kubectl-datadog/clusteragent/leader/leader.go 0.00% <ø> (ø)
... and 122 more

Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 0300de3...80e9a4c. Read the comment docs.

@swang392 swang392 added this to the v1.13.0 milestone Feb 10, 2025
Copy link
Contributor

@celenechang celenechang left a comment

Choose a reason for hiding this comment

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

thanks for the change, just left one comment

cmd/main.go Show resolved Hide resolved
Copy link
Contributor

@celenechang celenechang left a comment

Choose a reason for hiding this comment

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

successfully built locally

Copy link
Contributor

@gabedos gabedos left a comment

Choose a reason for hiding this comment

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

Looks good for container-platform files

Copy link
Member

@jennchenn jennchenn left a comment

Choose a reason for hiding this comment

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

lgtm for container-integrations files (only changes were import re-orders)

@celenechang celenechang merged commit 91095b8 into DataDog:main Feb 12, 2025
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants