class_docstr: Hook for Google ML Engine APIs.
  
  All the methods in the hook where project_id is used must be called with
  keyword arguments rather than positional.
class_docstr_tok: ["Hook","for","Google","ML","Engine","APIs",".","All","the","methods","in","the","hook","where","project_id","is","used","must","be","called","with","keyword","arguments","rather","than","positional","."]
docstr: Deletes the given version of a model. Blocks until finished.
  
  :param model_name: The name of the Google Cloud ML Engine model that the version
      belongs to. (templated)
  :param project_id: The Google Cloud project name to which MLEngine
      model belongs.
  :param version_name: A name to use for the version being operated upon. (templated)
  :return: If the version was deleted successfully, returns the operation.
      Otherwise raises an error.
docstr_tok: ["Deletes","the","given","version","of","a","model",".","Blocks","until","finished",".",":","param","model_name",":","The","name","of","the","Google","Cloud","ML","Engine","model","that","the","version","belongs","to",".","(","templated",")",":","param","project_id",":","The","Google","Cloud","project","name","to","which","MLEngine","model","belongs",".",":","param","version_name",":","A","name","to","use","for","the","version","being","operated","upon",".","(","templated",")",":","return",":","If","the","version","was","deleted","successfully",",","returns","the","operation",".","Otherwise","raises","an","error","."]
code: def delete_version(
      self,
      model_name: str,
      version_name: str,
      project_id: str,
  ) -> dict:
      """
      Deletes the given version of a model. Blocks until finished.
  
      :param model_name: The name of the Google Cloud ML Engine model that the version
          belongs to. (templated)
      :param project_id: The Google Cloud project name to which MLEngine
          model belongs.
      :param version_name: A name to use for the version being operated upon. (templated)
      :return: If the version was deleted successfully, returns the operation.
          Otherwise raises an error.
      """
      hook = self.get_conn()
      full_name = f"projects/{project_id}/models/{model_name}/versions/{version_name}"
      delete_request = (
          hook.projects().models().versions().delete(name=full_name)
      )
      response = delete_request.execute(num_retries=self.num_retries)
      get_request = (
          hook.projects().operations().get(name=response["name"])
      )
  
      return _poll_with_exponential_delay(
          request=get_request,
          execute_num_retries=self.num_retries,
          max_n=9,
          is_done_func=lambda resp: resp.get("done", False),
          is_error_func=lambda resp: resp.get("error", None)
          is not None,
      )
  
imports: from __future__ import annotations
  import contextlib
  import logging
  import random
  import time
  from typing import TYPE_CHECKING, Callable
  from aiohttp import ClientSession
  from gcloud.aio.auth import AioSession, Token
  from googleapiclient.discovery import Resource, build
  from googleapiclient.errors import HttpError
  from airflow.exceptions import AirflowException
  from airflow.providers.google.common.hooks.base_google import GoogleBaseAsyncHook, GoogleBaseHook
  from airflow.version import version
label_desc: Use image node_id 11 for calling the MLEngineHook obj's underlying member method code with example usage: obj.delete_version(model_name, version_name, project_id) and returns: _poll_with_exponential_delay