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

Fix golangci-lint config and apply tagalign #2323

Closed
wants to merge 9 commits into from
Closed

Conversation

ykadowak
Copy link
Contributor

@ykadowak ykadowak commented Feb 7, 2024

Description:

  • Fixed .golangci-lint.yaml for updated style.
  • Apply tagalign to fix all the warnings

Related Issue:

Versions:

  • Go Version: 1.21.6
  • Docker Version: 20.10.8
  • Kubernetes Version: v1.29.1
  • NGT Version: 2.1.6

Checklist:

Special notes for your reviewer:

@vdaas-ci
Copy link
Collaborator

vdaas-ci commented Feb 7, 2024

[CHATOPS:HELP] ChatOps commands.

  • 🙆‍♀️ /approve - approve
  • 🍱 /format - format codes and add licenses
  • /gen-test - generate test codes
  • 🏷️ /label - add labels
  • 🔚 2️⃣ 🔚 /label actions/e2e-deploy - run E2E deploy & integration test

Copy link

cloudflare-pages bot commented Feb 7, 2024

Deploying with  Cloudflare Pages  Cloudflare Pages

Latest commit: dccec0b
Status: ✅  Deploy successful!
Preview URL: https://bec7c3c7.vald.pages.dev
Branch Preview URL: https://feature-lint-update.vald.pages.dev

View logs

@vdaas-ci
Copy link
Collaborator

vdaas-ci commented Feb 7, 2024

[WARNING:INTCFG] Changes in interal/config may require you to change Helm charts. Please check.

@@ -46,6 +48,12 @@ import (
"github.com/vdaas/vald/internal/sync/errgroup"
"github.com/vdaas/vald/pkg/agent/internal/kvs"
"github.com/vdaas/vald/pkg/agent/internal/metadata"

Copy link
Contributor

Choose a reason for hiding this comment

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

🚫 [golangci] reported by reviewdog 🐶
File is not gofumpt-ed (gofumpt)

"k8s.io/apimachinery/pkg/apis/meta/v1/unstructured"
"k8s.io/apimachinery/pkg/fields"
kruntime "k8s.io/apimachinery/pkg/runtime"
applycorev1 "k8s.io/client-go/applyconfigurations/core/v1"
"github.com/vdaas/vald/pkg/agent/internal/vqueue"
Copy link
Contributor

Choose a reason for hiding this comment

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

🚫 [golangci] reported by reviewdog 🐶
File is not gofumpt-ed (gofumpt)

metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/labels"
"k8s.io/apimachinery/pkg/runtime"
"k8s.io/apimachinery/pkg/selection"
"k8s.io/apimachinery/pkg/watch"
clientgoscheme "k8s.io/client-go/kubernetes/scheme"
"k8s.io/utils/pointer"
Copy link
Contributor

Choose a reason for hiding this comment

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

🚫 [golangci] reported by reviewdog 🐶
SA1019: "k8s.io/utils/pointer" is deprecated: Use functions in k8s.io/utils/ptr instead: ptr.To to obtain a pointer, ptr.Deref to dereference a pointer, ptr.Equal to compare dereferenced pointers. (staticcheck)

metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/labels"
"k8s.io/apimachinery/pkg/runtime"
"k8s.io/apimachinery/pkg/selection"
"k8s.io/apimachinery/pkg/watch"
clientgoscheme "k8s.io/client-go/kubernetes/scheme"
"k8s.io/utils/pointer"
Copy link
Contributor

Choose a reason for hiding this comment

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

🚫 [golangci] reported by reviewdog 🐶
SA1019: "k8s.io/utils/pointer" is deprecated: Use functions in k8s.io/utils/ptr instead: ptr.To to obtain a pointer, ptr.Deref to dereference a pointer, ptr.Equal to compare dereferenced pointers. (staticcheck)

Copy link

codecov bot commented Feb 7, 2024

Codecov Report

Attention: 136 lines in your changes are missing coverage. Please review.

Comparison is base (88efc1a) 30.30% compared to head (dccec0b) 28.72%.
Report is 2 commits behind head on main.

Files Patch % Lines
pkg/agent/core/ngt/service/ngt.go 2.20% 133 Missing ⚠️
internal/k8s/client/client.go 0.00% 2 Missing ⚠️
...kg/index/job/readreplica/rotate/service/rotator.go 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2323      +/-   ##
==========================================
- Coverage   30.30%   28.72%   -1.58%     
==========================================
  Files         393      383      -10     
  Lines       40954    38610    -2344     
==========================================
- Hits        12410    11090    -1320     
+ Misses      27879    27016     -863     
+ Partials      665      504     -161     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

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.

None yet

3 participants