merge_pull_request_by_fast_forward
async
¶
merge_pull_request_by_fast_forward(
pull_request_id: PullRequestId,
repository_name: RepositoryName,
*,
config_overrides: Optional[AsyncCodeCommitClientConfig] = None,
source_commit_id: Optional[ObjectId] = None,
) -> MergePullRequestByFastForwardOutput
Attempts to merge the source commit of a pull request into the specified destination branch for that pull request at the specified commit using the fast-forward merge strategy. If the merge is successful, it closes the pull request.
Parameters:
-
pull_request_id(PullRequestId) –The system-generated ID of the pull request. To get this ID, use ListPullRequests.
-
repository_name(RepositoryName) –The name of the repository where the pull request was created.
-
source_commit_id(Optional[ObjectId], default:None) –The full commit ID of the original or updated commit in the pull request source branch. Pass this value if you want an exception thrown if the current commit ID of the tip of the source branch does not match this commit ID.
Raises:
-
ConcurrentReferenceUpdateException–The merge cannot be completed because the target branch has been modified. Another user might have modified the target branch while the merge was in progress. Wait a few minutes, and then try again.
-
EncryptionIntegrityChecksFailedException–An encryption integrity check failed.
-
EncryptionKeyAccessDeniedException–An encryption key could not be accessed.
-
EncryptionKeyDisabledException–The encryption key is disabled.
-
EncryptionKeyNotFoundException–No encryption key was found.
-
EncryptionKeyUnavailableException–The encryption key is not available.
-
InvalidCommitIdException–The specified commit ID is not valid.
-
InvalidPullRequestIdException–The pull request ID is not valid. Make sure that you have provided the full ID and that the pull request is in the specified repository, and then try again.
-
InvalidRepositoryNameException–A specified repository name is not valid.
This exception occurs only when a specified repository name is not valid. Other exceptions occur when a required repository parameter is missing, or when a specified repository does not exist.
-
ManualMergeRequiredException–The pull request cannot be merged automatically into the destination branch. You must manually merge the branches and resolve any conflicts.
-
PullRequestAlreadyClosedException–The pull request status cannot be updated because it is already closed.
-
PullRequestApprovalRulesNotSatisfiedException–The pull request cannot be merged because one or more approval rules applied to the pull request have conditions that have not been met.
-
PullRequestDoesNotExistException–The pull request ID could not be found. Make sure that you have specified the correct repository name and pull request ID, and then try again.
-
PullRequestIdRequiredException–A pull request ID is required, but none was provided.
-
ReferenceDoesNotExistException–The specified reference does not exist. You must provide a full commit ID.
-
RepositoryDoesNotExistException–The specified repository does not exist.
-
RepositoryNameRequiredException–A repository name is required, but was not specified.
-
RepositoryNotAssociatedWithPullRequestException–The repository does not contain any pull requests with that pull request ID. Use GetPullRequest to verify the correct repository name for the pull request ID.
-
TipOfSourceReferenceIsDifferentException–The tip of the source branch in the destination repository does not match the tip of the source branch specified in your request. The pull request might have been updated. Make sure that you have the latest changes.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_codecommit/_services/async_code_commit.py
4594 4595 4596 4597 4598 4599 4600 4601 4602 4603 4604 4605 4606 4607 4608 4609 4610 4611 4612 4613 4614 4615 4616 4617 4618 4619 4620 4621 4622 4623 4624 4625 4626 4627 4628 4629 4630 4631 4632 4633 4634 4635 4636 4637 4638 4639 4640 4641 4642 4643 4644 4645 4646 4647 4648 4649 4650 4651 4652 4653 4654 4655 4656 4657 4658 4659 4660 4661 4662 4663 | |