[skip ci] duplicated pipeline on MR with only:MR condition

Summary

Commit is made on an MR with [skip ci] commit message & the job have only: - merge_requests condition.

2 pipelines are created. One is correctly skipped. The other one is running normally. There should be only 1 skipped pipeline created

[skip ci] condition in MR works normally if there is no only: - merge_requests condition.

Steps to reproduce

  1. Add the CI rule below
On MR only:
  stage: build
  only:
    - merge_requests 
  script:
    - echo "MR only"
  1. Create an MR
  2. Update a file in the MR with [skip ci] in the commit message

What is the current bug behavior?

Duplicated Pipeline, one skip correctly. The other run like normal

What is the expected correct behavior?

One skipped pipeline

Relevant logs and/or screenshots

skip_ci

Reported (internal only ZD): https://gitlab.zendesk.com/agent/tickets/116539

Output of checks

This bug happens on GitLab.com

Assignee Loading
Time tracking Loading