get_comments_for_pull_request
async
¶
get_comments_for_pull_request(
pull_request_id: PullRequestId,
*,
config_overrides: Optional[AsyncCodeCommitClientConfig] = None,
repository_name: Optional[RepositoryName] = None,
before_commit_id: Optional[CommitId] = None,
after_commit_id: Optional[CommitId] = None,
next_token: Optional[NextToken] = None,
max_results: Optional[MaxResults] = None,
) -> GetCommentsForPullRequestOutput
Returns comments made on a pull request.
Reaction counts might include numbers from user identities who were deleted after the reaction was made. For a count of reactions from active identities, use GetCommentReactions.
Parameters:
-
pull_request_id(PullRequestId) –The system-generated ID of the pull request. To get this ID, use ListPullRequests.
-
repository_name(Optional[RepositoryName], default:None) –The name of the repository that contains the pull request. Requirement is conditional:
repositoryNamemust be specified whenbeforeCommitIdandafterCommitIdare included. -
before_commit_id(Optional[CommitId], default:None) –The full commit ID of the commit in the destination branch that was the tip of the branch at the time the pull request was created. Requirement is conditional:
beforeCommitIdmust be specified whenrepositoryNameis included. -
after_commit_id(Optional[CommitId], default:None) –The full commit ID of the commit in the source branch that was the tip of the branch at the time the comment was made. Requirement is conditional:
afterCommitIdmust be specified whenrepositoryNameis included. -
next_token(Optional[NextToken], default:None) –An enumeration token that, when provided in a request, returns the next batch of the results.
-
max_results(Optional[MaxResults], default:None) –A non-zero, non-negative integer used to limit the number of returned results. The default is 100 comments. You can return up to 500 comments with a single request.
Raises:
-
CommitDoesNotExistException–The specified commit does not exist or no commit was specified, and the specified repository has no default branch.
-
CommitIdRequiredException–A commit ID was not specified.
-
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.
-
InvalidContinuationTokenException–The specified continuation token is not valid.
-
InvalidMaxResultsException–The specified number of maximum results 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.
-
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.
-
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.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_codecommit/_services/async_code_commit.py
2610 2611 2612 2613 2614 2615 2616 2617 2618 2619 2620 2621 2622 2623 2624 2625 2626 2627 2628 2629 2630 2631 2632 2633 2634 2635 2636 2637 2638 2639 2640 2641 2642 2643 2644 2645 2646 2647 2648 2649 2650 2651 2652 2653 2654 2655 2656 2657 2658 2659 2660 2661 2662 2663 2664 2665 2666 2667 2668 2669 2670 2671 2672 2673 2674 2675 2676 2677 2678 2679 2680 2681 2682 2683 2684 2685 2686 2687 2688 2689 2690 2691 2692 | |