[go: up one dir, main page]

Skip to content

Support getting stats for a specific commit in MergeRequest GraphQL query

Everyone can contribute. Help move this issue forward while earning points, leveling up and collecting rewards.

Right now there's no way to select a specific commit on a MergeRequest query and get its stats similar to diffStatsSummary.

This is required to fix Number of changes in MR changes when scrolling ... (#483020 - closed).

I see two possible approaches to fix this:

Option A

  1. Allow passing a commitId to the MergeRequest query.

This approach is similar to how our REST API works but doesn't align well with GraphQL's resource structure.

Option B

  1. Add a commit field to MergeRequest query (commits won't work as it's pagination based)
  2. Add a commitId argument for Commit query
  3. Provide commit stats field in the same shape as diffStatsSummary

This option aligns better with GraphQL's paradigm but requires more effort to implement.

Edited by 🤖 GitLab Bot 🤖