Skip to content

deregister_pull_time_update_exclusion

deregister_pull_time_update_exclusion(
    principal_arn: PrincipalArn, *, config_overrides: Optional[ECRClientConfig] = None
) -> DeregisterPullTimeUpdateExclusionResponse

Removes a principal from the pull time update exclusion list for a registry. Once removed, Amazon ECR will resume updating the pull time if the specified principal pulls an image.

Parameters:

  • principal_arn (PrincipalArn) –

    The ARN of the IAM principal to remove from the pull time update exclusion list.

Raises:

Examples:

To remove a principal from the pull time exclusion list This example removes an IAM role from the pull time update exclusion list. Amazon ECR will resume recording image pull timestamps for this principal.

>>> client.deregister_pull_time_update_exclusion(principal_arn='arn:aws:iam::012345678910:role/ECRAccess')
Source code in docs_src/capo_ecr/_services/ecr.py
def deregister_pull_time_update_exclusion(
    self,
    principal_arn: "capo_ecr.types.principal_arn.PrincipalArn",
    *,
    config_overrides: Optional[ECRClientConfig] = None,
) -> "capo_ecr.types.deregister_pull_time_update_exclusion_response.DeregisterPullTimeUpdateExclusionResponse":
    """<p>Removes a principal from the pull time update exclusion list for a registry. Once removed, Amazon ECR will resume updating the pull time if the specified principal pulls an image.</p>

    Args:
        principal_arn: <p>The ARN of the IAM principal to remove from the pull time update exclusion list.</p>

    Raises:
        capo_ecr.errors.exclusion_not_found_exception.ExclusionNotFoundException: <p>The specified pull time update exclusion was not found.</p>
        capo_ecr.errors.invalid_parameter_exception.InvalidParameterException: <p>The specified parameter is invalid. Review the available parameters for the API request.</p>
        capo_ecr.errors.limit_exceeded_exception.LimitExceededException: <p>The operation did not succeed because it would have exceeded a service limit for your account. For more information, see <a href="https://docs.aws.amazon.com/AmazonECR/latest/userguide/service-quotas.html">Amazon ECR service quotas</a> in the Amazon Elastic Container Registry User Guide.</p>
        capo_ecr.errors.server_exception.ServerException: <p>These errors are usually caused by a server-side issue.</p>
        capo_ecr.errors.validation_exception.ValidationException: <p>There was an exception validating this request.</p>
        capo_ecr.errors.UnknownServiceError: The service returned an error code this client does not model.

    Examples:
        To remove a principal from the pull time exclusion list
        This example removes an IAM role from the pull time update exclusion list. Amazon ECR will resume recording image pull timestamps for this principal.

        >>> client.deregister_pull_time_update_exclusion(principal_arn='arn:aws:iam::012345678910:role/ECRAccess')
    """

    def _handler(
        req: "OperationRequest[capo_ecr.types.deregister_pull_time_update_exclusion_request.DeregisterPullTimeUpdateExclusionRequest]",
    ) -> OperationResponse[
        "capo_ecr.types.deregister_pull_time_update_exclusion_response.DeregisterPullTimeUpdateExclusionResponse"
    ]:
        import capo_ecr._operations.amazon_ec2_container_registry_v20150921.deregister_pull_time_update_exclusion

        output, http_response = (
            capo_ecr._operations.amazon_ec2_container_registry_v20150921.deregister_pull_time_update_exclusion.deregister_pull_time_update_exclusion(
                req.options, req.input
            )
        )
        return OperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("DeregisterPullTimeUpdateExclusion")
    )
    input_: capo_ecr.types.deregister_pull_time_update_exclusion_request.DeregisterPullTimeUpdateExclusionRequest = {
        "principal_arn": principal_arn
    }

    response = execute_pipeline(
        OperationRequest(input=input_, options=options_),
        handler=_handler,
        interceptors=list(interceptors_),
    )
    response.response.close()
    return response.output