class_docstr: Update an environment.
  
  :param project_id: Required. The ID of the Google Cloud project that the service belongs to.
  :param region: Required. The ID of the Google Cloud region that the service belongs to.
  :param environment_id: Required. The ID of the Google Cloud environment that the service belongs to.
  :param environment:  A patch environment. Fields specified by the ``updateMask`` will be copied from the
      patch environment into the environment under update.
  :param update_mask:  Required. A comma-separated list of paths, relative to ``Environment``, of fields to
      update. If a dict is provided, it must be of the same form as the protobuf message
      :class:`~google.protobuf.field_mask_pb2.FieldMask`
  :param retry: Designation of what errors, if any, should be retried.
  :param timeout: The timeout for this request.
  :param metadata: Strings which should be sent along with the request as metadata.
  :param gcp_conn_id:
  :param impersonation_chain: Optional service account to impersonate using short-term
      credentials, or chained list of accounts required to get the access_token
      of the last account in the list, which will be impersonated in the request.
      If set as a string, the account must grant the originating account
      the Service Account Token Creator IAM role.
      If set as a sequence, the identities from the list must grant
      Service Account Token Creator IAM role to the directly preceding identity, with first
      account from the list granting this role to the originating account (templated).
  :param deferrable: Run operator in the deferrable mode
  :param pooling_period_seconds: Optional: Control the rate of the poll for the result of deferrable run.
      By default, the trigger will poll every 30 seconds.
class_docstr_tok: ["Update","an","environment",".",":","param","project_id",":","Required",".","The","ID","of","the","Google","Cloud","project","that","the","service","belongs","to",".",":","param","region",":","Required",".","The","ID","of","the","Google","Cloud","region","that","the","service","belongs","to",".",":","param","environment_id",":","Required",".","The","ID","of","the","Google","Cloud","environment","that","the","service","belongs","to",".",":","param","environment",":","A","patch","environment",".","Fields","specified","by","the","``","updateMask","``","will","be","copied","from","the","patch","environment","into","the","environment","under","update",".",":","param","update_mask",":","Required",".","A","comma-separated","list","of","paths",",","relative","to","``","Environment","``",",","of","fields","to","update",".","If","a","dict","is","provided",",","it","must","be","of","the","same","form","as","the","protobuf","message",":","class",":","`","~google.protobuf.field_mask_pb2.FieldMask","`",":","param","retry",":","Designation","of","what","errors",",","if","any",",","should","be","retried",".",":","param","timeout",":","The","timeout","for","this","request",".",":","param","metadata",":","Strings","which","should","be","sent","along","with","the","request","as","metadata",".",":","param","gcp_conn_id",":",":","param","impersonation_chain",":","Optional","service","account","to","impersonate","using","short-term","credentials",",","or","chained","list","of","accounts","required","to","get","the","access_token","of","the","last","account","in","the","list",",","which","will","be","impersonated","in","the","request",".","If","set","as","a","string",",","the","account","must","grant","the","originating","account","the","Service","Account","Token","Creator","IAM","role",".","If","set","as","a","sequence",",","the","identities","from","the","list","must","grant","Service","Account","Token","Creator","IAM","role","to","the","directly","preceding","identity",",","with","first","account","from","the","list","granting","this","role","to","the","originating","account","(","templated",")",".",":","param","deferrable",":","Run","operator","in","the","deferrable","mode",":","param","pooling_period_seconds",":","Optional",":","Control","the","rate","of","the","poll","for","the","result","of","deferrable","run",".","By","default",",","the","trigger","will","poll","every","30","seconds","."]
code: def execute_complete(self, context: Context, event: dict):
      if event["operation_done"]:
          hook = CloudComposerHook(
              gcp_conn_id=self.gcp_conn_id,
              impersonation_chain=self.impersonation_chain,
          )
  
          env = hook.get_environment(
              project_id=self.project_id,
              region=self.region,
              environment_id=self.environment_id,
              retry=self.retry,
              timeout=self.timeout,
              metadata=self.metadata,
          )
          return Environment.to_dict(env)
      else:
          raise AirflowException(
              f"Unexpected error in the operation: {event['operation_name']}"
          )
  
imports: from __future__ import annotations
  from typing import TYPE_CHECKING, Sequence
  from google.api_core.exceptions import AlreadyExists
  from google.api_core.gapic_v1.method import DEFAULT, _MethodDefault
  from google.cloud.orchestration.airflow.service_v1 import ImageVersion
  from google.cloud.orchestration.airflow.service_v1.types import Environment
  from airflow.configuration import conf
  from airflow.exceptions import AirflowException
  from airflow.providers.google.cloud.hooks.cloud_composer import CloudComposerHook
  from airflow.providers.google.cloud.links.base import BaseGoogleLink
  from airflow.providers.google.cloud.operators.cloud_base import GoogleCloudBaseOperator
  from airflow.providers.google.cloud.triggers.cloud_composer import CloudComposerExecutionTrigger
  from airflow.providers.google.common.consts import GOOGLE_DEFAULT_DEFERRABLE_METHOD_NAME
label_desc: Use image node_id 3 for calling the CloudComposerUpdateEnvironmentOperator obj's underlying member method code with example usage: obj.execute_complete(context, event) and returns: Environment