Skip to content

gitlab: Implement ChecksByChange with per-job pipeline detail#1266

Open
ed-irl wants to merge 1 commit into
ed-irl/checks-githubfrom
ed-irl/checks-gitlab
Open

gitlab: Implement ChecksByChange with per-job pipeline detail#1266
ed-irl wants to merge 1 commit into
ed-irl/checks-githubfrom
ed-irl/checks-gitlab

Conversation

@ed-irl

@ed-irl ed-irl commented Jun 13, 2026

Copy link
Copy Markdown
Collaborator

Implements the GitLab side of the per-change checks API: rollup
state from the MR's head pipeline, per-job name/state/url from the
pipeline's job list, and the pipeline's web URL as the click target.

  • gateway: Pipeline grows ID and WebURL fields; new Job type
    (name + status + web_url); new PipelineJobsList API method
    wrapping /projects/:id/pipelines/:pipeline_id/jobs.
  • rollupFromPipelineStatus collapses GitLab's pipeline status
    enum to the upstream rollup taxonomy. Canceled/manual/skipped
    are user-initiated non-failures and roll up as passed (the
    operator's choice not to run them isn't a failure). Unknown
    statuses default to pending — GitLab adds new statuses over
    time and pending is the safer default.
  • pipelineState (the merge handler's path) keeps its 'no
    pipeline -> passed' semantics; ChecksByChange uses ChecksNone
    in that case so the indicator can distinguish.
  • ChecksByChange issues MergeRequestGet + PipelineJobsList per
    MR. Jobs are reported in pipeline order (stages first, then
    job order within stages); GitLab's job.status is already
    lowercase so it flows straight through as forge-native state.

Integration fixtures regenerate on the next forgetest -update
pass (real GitLab credentials).

Implements the GitLab side of the per-change checks API: rollup
state from the MR's head pipeline, per-job name/state/url from the
pipeline's job list, and the pipeline's web URL as the click target.

  - gateway: Pipeline grows ID and WebURL fields; new Job type
    (name + status + web_url); new PipelineJobsList API method
    wrapping /projects/:id/pipelines/:pipeline_id/jobs.
  - rollupFromPipelineStatus collapses GitLab's pipeline status
    enum to the upstream rollup taxonomy. Canceled/manual/skipped
    are user-initiated non-failures and roll up as passed (the
    operator's choice not to run them isn't a failure). Unknown
    statuses default to pending — GitLab adds new statuses over
    time and pending is the safer default.
  - pipelineState (the merge handler's path) keeps its 'no
    pipeline -> passed' semantics; ChecksByChange uses ChecksNone
    in that case so the indicator can distinguish.
  - ChecksByChange issues MergeRequestGet + PipelineJobsList per
    MR. Jobs are reported in pipeline order (stages first, then
    job order within stages); GitLab's job.status is already
    lowercase so it flows straight through as forge-native state.

Integration fixtures regenerate on the next forgetest -update
pass (real GitLab credentials).
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