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

code-climate: add default severity #3294

Merged
merged 3 commits into from Oct 20, 2022

Conversation

sinkcup
Copy link
Contributor

@sinkcup sinkcup commented Oct 15, 2022

when I output code climate format report, GitLab CI code quality report can show the report, but GitLab MR code quality widget can not.

MR: https://jihulab.com/premium-plan/features/04Verify/code-quality-report/golang/-/merge_requests/1

golangci-lint run --enable-all --out-format code-climate:gl-code-quality-report.json
image image

I try to add those required columns in the docs: https://github.com/codeclimate/platform/blob/master/spec/analyzers/SPEC.md#data-types

add type is useless: https://jihulab.com/premium-plan/features/04Verify/code-quality-report/golang/-/merge_requests/3

golangci-lint run --enable-all --out-format code-climate:report.json
cat report.json | jq '.[] += { type: "issue" }' > gl-code-quality-report.json

add severity is usefull: https://jihulab.com/premium-plan/features/04Verify/code-quality-report/golang/-/merge_requests/4

golangci-lint run --enable-all --out-format code-climate:report.json
cat report.json | jq '.[] += { severity: "critical" }' > gl-code-quality-report.json
image

so I create this PR to add severity default value.

@boring-cyborg
Copy link

boring-cyborg bot commented Oct 15, 2022

Hey, thank you for opening your first Pull Request !

@CLAassistant
Copy link

CLAassistant commented Oct 15, 2022

CLA assistant check
All committers have signed the CLA.

@sinkcup sinkcup changed the title fix: code climate report need severity fix: code climate GitLab MR widget need severity Oct 15, 2022
@ldez ldez changed the title fix: code climate GitLab MR widget need severity code-climate: GitLab MR widget need severity Oct 15, 2022
@ldez ldez added the enhancement New feature or improvement label Oct 15, 2022
@ldez ldez force-pushed the fix-code-climate-report-severity branch from 15003f9 to 1c6caf1 Compare October 20, 2022 13:35
@ldez ldez self-requested a review October 20, 2022 13:36
@ldez ldez changed the title code-climate: GitLab MR widget need severity code-climate: add default severity Oct 20, 2022
@ldez ldez added the area: output Related to issue output label Oct 20, 2022
Copy link
Member

@ldez ldez left a comment

Choose a reason for hiding this comment

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

LGTM

@ldez ldez enabled auto-merge (squash) October 20, 2022 21:08
@ldez ldez merged commit 6740559 into golangci:master Oct 20, 2022
@sinkcup sinkcup deleted the fix-code-climate-report-severity branch October 21, 2022 01:53
SeigeC pushed a commit to SeigeC/golangci-lint that referenced this pull request Apr 4, 2023
Co-authored-by: Fernandez Ludovic <ldez@users.noreply.github.com>
@ldez ldez added this to the v1.50 milestone Mar 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: output Related to issue output area: severity enhancement New feature or improvement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants