The `mergeRequest` field for `PipelineSecurityReportFinding` does not get populated
Summary
The GraphQl field that captures merge requests, which are associated with a pipeline security finding, does not get populated and stays null
.
Steps to reproduce
- Create a merge request for a finding:
mutation createMR($findingUuid: String!) {
securityFindingCreateMergeRequest(input:{uuid:$findingUuid }) {
errors
}
}
- Query the same finding
query getFinding($fullPath: ID!, $pipelineIid: ID!, $findingUuid: String!) {
project(fullPath: $fullPath) {
pipeline(iid: $pipelineIid) {
securityReportFinding(uuid: $findingUuid) {
mergeRequest {
id
}
}
}
}
}
example GraphQL variables (please change to include existing values):
{
"fullPath": "security/test-remediations-v2",
"pipelineIid": "23",
"findingUuid": "5daabde9-4fdf-5b57-87d8-97fe9101e05a",
"comment": "bar",
"project": "gid://gitlab/Project/20"
}
The response does not include the newly created MR. The related REST endpoint does include it.
Example Project
What is the current bug behavior?
https://gitlab.com/sming-gitlab/test-remediations/
What is the expected correct behavior?
After creating an MR for a finding, it should be showing up within the mergeRequest
field.
Relevant logs and/or screenshots
Output of checks
Results of GitLab environment info
Expand for output related to GitLab environment info
(For installations with omnibus-gitlab package run and paste the output of: `sudo gitlab-rake gitlab:env:info`) (For installations from source run and paste the output of: `sudo -u git -H bundle exec rake gitlab:env:info RAILS_ENV=production`)
Results of GitLab application Check
Expand for output related to the GitLab application check
(For installations with omnibus-gitlab package run and paste the output of:
sudo gitlab-rake gitlab:check SANITIZE=true
)(For installations from source run and paste the output of:
sudo -u git -H bundle exec rake gitlab:check RAILS_ENV=production SANITIZE=true
)(we will only investigate if the tests are passing)