-
Notifications
You must be signed in to change notification settings - Fork 20
Description
Is it possible to add an autocomplete for PR in ADO? The current automerge feature works fine until you have validation pipelines on the branch.
INFO clone: Cloning repository: https://dev.azure.com/xxx/yyy/_git/zzz
INFO new_branch: Creating new branch: gitopscli-deploy-89bf9199
INFO __update_values: Updated yaml property spec.revision to 2
INFO commit: Creating commit with message: changed 'spec.revision' to '2' in dummy.yaml
INFO push: Pushing branch: gitopscli-deploy-89bf9199
INFO create_pull_request_to_default_branch: Creating pull request from 'gitopscli-deploy-89bf9199' to default branch with title: Updated value in dummy.yaml
INFO merge_pull_request: Merging pull request 33274
ERROR main: Error merging pull request: Build Validation must succeed to update main.
Traceback (most recent call last):
File "/app/.venv/lib/python3.12/site-packages/gitopscli/git_api/azure_devops_git_repo_api_adapter.py", line 151, in merge_pull_request
self.__git_client.update_pull_request(
File "/app/.venv/lib/python3.12/site-packages/azure/devops/v7_0/git/git_client_base.py", line 2244, in update_pull_request
response = self._send(http_method='PATCH',
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/app/.venv/lib/python3.12/site-packages/azure/devops/client.py", line 104, in _send
response = self._send_request(request=request, headers=headers, content=content, media_type=media_type)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/app/.venv/lib/python3.12/site-packages/azure/devops/client.py", line 68, in _send_request
self._handle_error(request, response)
File "/app/.venv/lib/python3.12/site-packages/azure/devops/client.py", line 270, in _handle_error
raise AzureDevOpsServiceError(wrapped_exception)
azure.devops.exceptions.AzureDevOpsServiceError: Build Validation must succeed to update main.
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/app/.venv/lib/python3.12/site-packages/gitopscli/main.py", line 14, in main
command.execute()
File "/app/.venv/lib/python3.12/site-packages/gitopscli/commands/deploy.py", line 70, in execute
git_repo_api.merge_pull_request(pr_id, self.__args.merge_method)
File "/app/.venv/lib/python3.12/site-packages/gitopscli/git_api/git_repo_api_logging_proxy.py", line 46, in merge_pull_request
self.__api.merge_pull_request(pr_id, merge_method=merge_method)
File "/app/.venv/lib/python3.12/site-packages/gitopscli/git_api/azure_devops_git_repo_api_adapter.py", line 164, in merge_pull_request
raise GitOpsException(f"Error merging pull request: {error_msg}") from ex
gitopscli.gitops_exception.GitOpsException: Error merging pull request: Build Validation must succeed to update main.