docstr: Update the status container.
  
  Only specified arguments are updated. Container contents and unspecified
  arguments remain unchanged.
  
  Parameters
  ----------
  label : str or None
      A new label of the status container. If None, the label is not
      changed.
  
  expanded : bool or None
      The new expanded state of the status container. If None,
      the expanded state is not changed.
  
  state : "running", "complete", "error", or None
      The new state of the status container. This mainly changes the
      icon. If None, the state is not changed.
docstr_tok: ["Update","the","status","container",".","Only","specified","arguments","are","updated",".","Container","contents","and","unspecified","arguments","remain","unchanged",".","Parameters","--","--","--","--","--","label",":","str","or","None","A","new","label","of","the","status","container",".","If","None",",","the","label","is","not","changed",".","expanded",":","bool","or","None","The","new","expanded","state","of","the","status","container",".","If","None",",","the","expanded","state","is","not","changed",".","state",":","``","running","''",",","``","complete","''",",","``","error","''",",","or","None","The","new","state","of","the","status","container",".","This","mainly","changes","the","icon",".","If","None",",","the","state","is","not","changed","."]
code: def update(
      self,
      *,
      label: str | None = None,
      expanded: bool | None = None,
      state: States | None = None,
  ) -> None:
      """Update the status container.
  
      Only specified arguments are updated. Container contents and unspecified
      arguments remain unchanged.
  
      Parameters
      ----------
      label : str or None
          A new label of the status container. If None, the label is not
          changed.
  
      expanded : bool or None
          The new expanded state of the status container. If None,
          the expanded state is not changed.
  
      state : "running", "complete", "error", or None
          The new state of the status container. This mainly changes the
          icon. If None, the state is not changed.
      """
      assert (
          self._current_proto is not None
      ), "Status not correctly initialized!"
      assert (
          self._delta_path is not None
      ), "Status not correctly initialized!"
  
      msg = ForwardMsg()
      msg.metadata.delta_path[:] = self._delta_path
      msg.delta.add_block.CopyFrom(self._current_proto)
  
      if expanded is not None:
          msg.delta.add_block.expandable.expanded = expanded
      else:
          msg.delta.add_block.expandable.ClearField("expanded")
  
      if label is not None:
          msg.delta.add_block.expandable.label = label
  
      if state is not None:
          if state == "running":
              msg.delta.add_block.expandable.icon = "spinner"
          elif state == "complete":
              msg.delta.add_block.expandable.icon = "check"
          elif state == "error":
              msg.delta.add_block.expandable.icon = "error"
          else:
              raise StreamlitAPIException(
                  f"Unknown state ({state}). Must be one of 'running', 'complete', or 'error'."
              )
          self._current_state = state
  
      self._current_proto = msg.delta.add_block
      _enqueue_message(msg)
  
file_path: streamlit/lib/streamlit/elements/lib/mutable_status_container.py
imports: from __future__ import annotations
  import time
  from types import TracebackType
  from typing import List, Optional, Type, cast
  from typing_extensions import Literal, TypeAlias
  from streamlit.cursor import Cursor
  from streamlit.delta_generator import DeltaGenerator, _enqueue_message
  from streamlit.errors import StreamlitAPIException
  from streamlit.proto.Block_pb2 import Block
  from streamlit.proto.ForwardMsg_pb2 import ForwardMsg
label_desc: Use image node_id 3 for calling the StatusContainer obj's underlying member method code with example usage: obj.update() without return types