def METHOD_NAME(loggroup: str) -> None:
    client_logs = boto3.client("logs")
    with pytest.raises(exceptions.QueryCancelled):
        while True:
            query_id = wr.cloudwatch.start_query(
                log_group_names=[loggroup], query="fields @timestamp, @message | sort @timestamp desc"
            )
            try:
                client_logs.stop_query(queryId=query_id)
                break
            except Exception as ex:
                if "is not in Running or Scheduled state" not in str(ex):
                    raise ex
        wr.cloudwatch.wait_query(query_id=query_id)