-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
GitLabRetriever does not work with pipelines for merge requests #114
Comments
Hi! Thanks for reporting this.
I think this is the same issue as #104. I just pushed a branch I worked on a while ago with a potential fix for this: |
Just tested this branch, see https://gitlab.com/xen-project/xen-guest-agent/-/merge_requests/30 There is a command error that does not get caught, and the DCO is reported as good without even being checked. |
I'll fix this so that the error is properly reported. As for why the error happens, can you try doing a |
See https://gitlab.com/xen-project/xen-guest-agent/-/jobs/5796509345 As you said it would help to know about If I create the local https://gitlab.com/xen-project/xen-guest-agent/-/jobs/5796533504 |
Any progress on this, was the above info sufficient? |
BTW, AFAIK this feature is available for any gitlab repo |
When the pipelines for merge requests feature is used,
dco-check
fails with the following error:I reproduced it in a test repository here: https://gitlab.com/raphael.melotte/dco-check-test/-/jobs/1655135885 .
And it's also possible to reproduce it manually outside of Gitlab:
The problem is that CI_COMMIT_BRANCH is unset in pipelines for merge requests.
From https://docs.gitlab.com/ee/ci/variables/predefined_variables.html:
A possible workaround is to manually set the variable.
For example:
With that,
dco-check
fails, but without giving any reason. See this job, or run the following in a local repository:This time the problem is with the
CI_MERGE_REQUEST_TARGET_BRANCH_SHA
variable: it's set, but empty in merge requests pipelines:As a workaround for the current version, one can set it manually. For example:
or:
While this works, it has the same problem as in #113 (i.e.
git merge-base --fork-point
can fail in some scenarios).The text was updated successfully, but these errors were encountered: