-
Notifications
You must be signed in to change notification settings - Fork 207
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
Enable discussion #216
Enable discussion #216
Conversation
@gabrie-allaigre is that possible to get this soon? |
Throws an exception when executing the following code:
Exception information:
|
file: com/talanlabs/gitlab/api/v4/models/GitlabMergeRequest.java
|
Hi, Thanks, |
I do not feel that the discussion is resolved when the issue is fixed |
4ada48b
to
ff206e1
Compare
Hi @gabrie-allaigre I have updated the pull request and added the tests. In addition, since gitlab 11.6 a new ci variable called |
Hey guys, which is odd as the mentioned line is not blank. This appears without a clear pattern. |
If you retry this ci build with discussion feature turn off, occurs the error too? And what GitLab Version you use? Are you able to post a comment/discussion via the ui to this line? If you post the discussion via the ui, what is the response for? |
We are using GitLab Version 11.8.7 Most often it occurs when you directly create a branch+merge request where you did not commit any changes yet but this is not always the case. We could not test if it is possible to post any comments or discussions because we are not able to reproduce this in a predictable way with changes in the branch. Might be the case that this error occurs as the plugin is not able to post any comment / discussion because no changes were made and the UI will not let you create any discussions. |
@gabrie-allaigre any progress on this? It's very frustrating not to hear anything anymore. |
@ManuZiD we're running 11.9 and occasionally see "SonarQube failed to complete the review of this commit: The merge request iid must be provided." I tried updating our .gitlab-ci.yml to the following..
and it complains that CI_MERGE_REQUEST_IID is an empty string.. have you seen this? The build in question does have an open merge request. |
Hi @johnou If you look at the gitlab docs https://docs.gitlab.com/11.9/ee/ci/variables/README.html you will see that the variable is exposed. But I have seen since version 11.10 they are no longer exposed. |
Yeah not listed here https://docs.gitlab.com/11.10/ee/ci/variables/README.html .. |
@ManuZiD have you pinged gitlab? |
@johnou no. You? |
might not need to, I verified it's still in the master branch https://gitlab.com/gitlab-org/gitlab-ce/blob/master/app/models/merge_request.rb#L1175 |
Can you run a build and output the variable to see if it is really exposed? |
We are still running 11.9.x which has been occasionally omitting the variables.. I have since changed my gitlab.yml to the following.. will see if that helps. sonarqube_preview:
stage: test
script:
- mvn --batch-mode verify sonar:sonar -DskipITs -Dgpg.sign=false -Dsonar.host.url=$SONAR_URL -Dsonar.analysis.mode=preview -Dsonar.gitlab.api_version=v4 -Dsonar.issuesReport.console.enable=true -Dsonar.gitlab.project_id=$CI_PROJECT_PATH -Dsonar.gitlab.commit_sha=$CI_COMMIT_SHA -Dsonar.gitlab.ref_name=$CI_COMMIT_REF_NAME -Dsonar.gitlab.ci_merge_request_iid=$CI_MERGE_REQUEST_IID -Dsonar.gitlab.merge_request_discussion=true
only:
- merge_requests
except:
- develop
- master
- /^hotfix_.*$/
- /.*-hotfix$/
tags:
- java |
Enable discussion support see issue 186 for more details. To merge this pull request the https://github.com/gabrie-allaigre/java-gitlab-api must be released first!