mirror of
https://gitlab.com/fdroid/fdroidserver.git
synced 2024-11-19 21:30:10 +01:00
Don't open second MR for gradle (Closes: #914)
Traceback (most recent call last): File "/builds/fdroid/fdroidserver/./tests/gradle-release-checksums.py", line 130, in <module> mr = project.mergerequests.create({ File "/usr/lib/python3/dist-packages/gitlab/exceptions.py", line 281, in wrapped_f raise error(e.error_message, e.response_code, e.response_body) from e gitlab.exceptions.GitlabCreateError: 409: ['Another open merge request already exists for this source branch: !1064']
This commit is contained in:
parent
5f43fdccd4
commit
460dffe82b
@ -127,13 +127,16 @@ if git_repo.is_dirty() and ('gradlew-fdroid' in modified or 'makebuildserver' in
|
|||||||
'\n\n<p><small>generated by <a href="%s/-/jobs/%s">GitLab CI Job #%s</a></small></p>'
|
'\n\n<p><small>generated by <a href="%s/-/jobs/%s">GitLab CI Job #%s</a></small></p>'
|
||||||
% (os.getenv('CI_PROJECT_URL'), os.getenv('CI_JOB_ID'), os.getenv('CI_JOB_ID'))
|
% (os.getenv('CI_PROJECT_URL'), os.getenv('CI_JOB_ID'), os.getenv('CI_JOB_ID'))
|
||||||
)
|
)
|
||||||
mr = project.mergerequests.create({
|
try:
|
||||||
'source_branch': branch.name,
|
mr = project.mergerequests.create({
|
||||||
'target_project_id': 36527, # fdroid/fdroidserver
|
'source_branch': branch.name,
|
||||||
'target_branch': 'master',
|
'target_project_id': 36527, # fdroid/fdroidserver
|
||||||
'title': 'update to gradle v' + version,
|
'target_branch': 'master',
|
||||||
'description': description,
|
'title': 'update to gradle v' + version,
|
||||||
'labels': ['fdroid-bot', 'gradle'],
|
'description': description,
|
||||||
'remove_source_branch': True,
|
'labels': ['fdroid-bot', 'gradle'],
|
||||||
})
|
'remove_source_branch': True,
|
||||||
mr.save()
|
})
|
||||||
|
mr.save()
|
||||||
|
except gitlab.exceptions.GitlabCreateError as e:
|
||||||
|
print(e.error_message)
|
||||||
|
Loading…
Reference in New Issue
Block a user