Skip to content

Add review_codequality for GitLab Code Quality reports - #168

Open
SebTardif wants to merge 1 commit into
prooflinedev:mainfrom
SebTardif:feat/gitlab-code-quality
Open

SebTardif wants to merge 1 commit into
prooflinedev:mainfrom
SebTardif:feat/gitlab-code-quality

Conversation

@SebTardif

Copy link
Copy Markdown

Summary

review_codequality turns a completed code review into the JSON list a GitLab Code Quality job uploads.

  • SERIOUS maps to critical, and WARNING maps to minor.
  • A RESOLVED finding is left out.
  • A location is included only for a repository_file reference that was a verified read of the review's head commit.
  • An outcome other than COMPLETED, a missing or mismatched head, or an unknown severity raises ProoflineError. An unfinished review is not uploaded as a clean report.

The README shows writing gl-code-quality-report.json and publishing it with artifacts:reports:codequality.

Tests

pytest tests/test_codequality.py passed (8 tests). ruff check and ruff format passed on the changed Python files.

Turn a completed code review into the JSON list a GitLab Code Quality
job uploads. SERIOUS maps to critical and WARNING maps to minor.
RESOLVED findings are left out. A location is included only for a
verified repository_file read of the review head. Any other outcome
status, a missing head, or an unknown severity raises ProoflineError.

pytest tests/test_codequality.py: 8 passed. ruff check and format passed.

This branch has not been deployed

No deployments
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.

1 participant