Pipeline Webhook - Merge Request information is empty (null)

Summary

Pipeline webhook is missing the merge request information.

Steps to reproduce

Enable the pipeline webhook and capture the event data. The information sended is missing the merge request data.

What is the current bug behavior?

The sended merge request information is missing (null):

{
   "object_kind": "pipeline",
   "object_attributes":{
      "id": 31,
      "ref": "master",
      "tag": false,
      "sha": "bcbb5ec396a2c0f828686f14fac9b80b780504f2",
      "before_sha": "bcbb5ec396a2c0f828686f14fac9b80b780504f2",
      "source": "merge_request_event",
      "status": "success",
   },
    "merge_request": null
   "user":{
      "name": "Administrator",
   },

What is the expected correct behavior?

The correct behavior should be the documented for the pipeline event hook (https://docs.gitlab.com/ee/user/project/integrations/webhook_events.html#pipeline-events):

    "merge_request": {
      "id": 1,
      "iid": 1,
      "title": "Test",
      "source_branch": "test",
      "source_project_id": 1,
      "target_branch": "master",
      "target_project_id": 1,
      "state": "opened",
      "merge_status": "can_be_merged",
      "url": "http://192.168.64.1:3005/gitlab-org/gitlab-test/merge_requests/1"
   },

The information of the merge request is necessary to be able to relate the information of the pipeline with the related merge request.

Assignee Loading
Time tracking Loading