jenkinsci / gitlab-plugin

A Jenkins plugin for interfacing with GitLab
https://plugins.jenkins.io/gitlab-plugin/
GNU General Public License v2.0
1.43k stars 613 forks source link

Build only if new commits were pushed to Merge Request seem to be not working #1674

Open ChristRm opened 1 month ago

ChristRm commented 1 month ago

Jenkins and plugins versions report

Jenkins 2.452.3 Gitlab plugin 1.8.1

Environment ```text Paste the output here ```

What Operating System are you using (both controller, and any agents involved in the problem)?

Jenkins installed on Mac OS X Ventura 13.5.2

Reproduction steps

Create a Webhook on Gitlab with the following config: Push events: All branches Comments Merge request events

Create a Jenkins Freestyle job which is linked to this web hook and config it the following way: Build when a change is pushed to GitLab. GitLab webhook URL: http://**** and the config Push events Opened Merge requests Merge request events Build only if new commits were pushed to Merge Request Approved merge requests

Expected Results

The job is triggered only if MR is created The push is made to the MR branch

Actual Results

The job is triggered whenever any push to any branch is done

Anything else?

There is a suspicion that the issue could be in the following topic, where the ref spec value cannot be set with the recommended value by documentation https://issues.jenkins.io/browse/JENKINS-73527

Are you interested in contributing a fix?

No response