Skip to content

feat: add the errorlint check for golangci-lint#2519

Merged
ritazh merged 4 commits into
open-policy-agent:masterfrom
Fish-pro:feature/errlint
Jan 21, 2023
Merged

feat: add the errorlint check for golangci-lint#2519
ritazh merged 4 commits into
open-policy-agent:masterfrom
Fish-pro:feature/errlint

Conversation

@Fish-pro
Copy link
Copy Markdown

Signed-off-by: Fish-pro zechun.chen@daocloud.io

What this PR does / why we need it:

Adds errorlint checks to golangci-lint, standardizing the error format and error judgments

Which issue(s) this PR fixes (optional, using fixes #<issue number>(, fixes #<issue_number>, ...) format, will close the issue(s) when the PR gets merged):
Fixes #

Special notes for your reviewer:

@codecov-commenter
Copy link
Copy Markdown

codecov-commenter commented Jan 16, 2023

Codecov Report

Attention: Patch coverage is 40.00000% with 12 lines in your changes missing coverage. Please review.

Project coverage is 54.09%. Comparing base (7786db9) to head (a6bbb8b).
Report is 697 commits behind head on master.

Files with missing lines Patch % Lines
pkg/webhook/policy.go 16.66% 5 Missing ⚠️
pkg/gator/test/test.go 0.00% 4 Missing ⚠️
pkg/expansion/system.go 0.00% 2 Missing ⚠️
pkg/mutation/schema/errors.go 50.00% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #2519      +/-   ##
==========================================
+ Coverage   53.78%   54.09%   +0.31%     
==========================================
  Files         116      116              
  Lines       10286    10287       +1     
==========================================
+ Hits         5532     5565      +33     
+ Misses       4324     4301      -23     
+ Partials      430      421       -9     
Flag Coverage Δ
unittests 54.09% <40.00%> (+0.31%) ⬆️

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

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

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Copy link
Copy Markdown
Member

@sozercan sozercan left a comment

Choose a reason for hiding this comment

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

Thank you for adding this! LGTM

@sozercan sozercan requested a review from maxsmythe January 17, 2023 23:24
Signed-off-by: Fish-pro <zechun.chen@daocloud.io>
Copy link
Copy Markdown
Contributor

@maxsmythe maxsmythe left a comment

Choose a reason for hiding this comment

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

LGTM, thank you for the PR!

@ritazh ritazh merged commit 73611cc into open-policy-agent:master Jan 21, 2023
davis-haba pushed a commit to davis-haba/gatekeeper that referenced this pull request Mar 7, 2023
Add the errorlint check

Signed-off-by: Fish-pro <zechun.chen@daocloud.io>

Signed-off-by: Fish-pro <zechun.chen@daocloud.io>
Co-authored-by: Sertaç Özercan <852750+sozercan@users.noreply.github.com>
Co-authored-by: Rita Zhang <rita.z.zhang@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants