code: def update_current_task(task):
      # set current Task before patching
      PatchHydra._current_task = task
      if not task:
          return
      if PatchHydra.patch_hydra():
          # check if we have an untracked state, store it.
          if PatchHydra._last_untracked_state.get("connect"):
              if (
                  PatchHydra._parameter_allow_full_edit
                  in PatchHydra._last_untracked_state["connect"].get(
                      "mutable", {}
                  )
              ):
                  allow_omegaconf_edit_section = (
                      PatchHydra._parameter_section
                      + "/"
                      + PatchHydra._parameter_allow_full_edit
                  )
                  allow_omegaconf_edit_section_val = (
                      PatchHydra._last_untracked_state["connect"][
                          "mutable"
                      ].pop(PatchHydra._parameter_allow_full_edit)
                  )
                  PatchHydra._current_task.set_parameter(
                      allow_omegaconf_edit_section,
                      allow_omegaconf_edit_section_val,
                      description="If True, the `{}` parameter section will be completely ignored. The OmegaConf will instead be pulled from the `{}` section".format(
                          PatchHydra._parameter_section,
                          PatchHydra._config_section,
                      ),
                  )
              PatchHydra._current_task.connect(
                  **PatchHydra._last_untracked_state["connect"]
              )
          if PatchHydra._last_untracked_state.get("_set_configuration"):
              # noinspection PyProtectedMember
              PatchHydra._current_task._set_configuration(
                  **PatchHydra._last_untracked_state[
                      "_set_configuration"
                  ]
              )
          PatchHydra._last_untracked_state = {}
      else:
          # if patching failed set it to None
          PatchHydra._current_task = None
  
file_path: clearml/clearml/binding/hydra_bind.py
imports: import io
  import sys
  from functools import partial
  from ..config import running_remotely, get_remote_task_id, DEV_TASK_NO_REUSE
  from ..debugging.log import LoggerRoot
label_desc: Use image node_id 3 for calling the PatchHydra obj's underlying member method code with example usage: obj.update_current_task(task) without return types