class_docstr: Exception raised when a websocket message is larger than the configured limit.
code: def _get_message(self, failed_msg_str: Any) -> str:
      # This needs to have zero indentation otherwise the markdown will render incorrectly.
      return (
          (
              """
  **Data of size {message_size_mb:.1f} MB exceeds the message size limit of {message_size_limit_mb} MB.**
  
  This is often caused by a large chart or dataframe. Please decrease the amount of data sent
  to the browser, or increase the limit by setting the config option `server.maxMessageSize`.
  [Click here to learn more about config options](https://docs.streamlit.io/library/advanced-features/configuration#set-configuration-options).
  
  _Note that increasing the limit may lead to long loading times and large memory consumption
  of the client's browser and the Streamlit server._
  """
          )
          .format(
              message_size_mb=len(failed_msg_str) / 1e6,
              message_size_limit_mb=(
                  get_max_message_size_bytes() / 1e6
              ),
          )
          .strip("\n")
      )
  
file_path: streamlit/lib/streamlit/runtime/runtime_util.py
imports: from typing import Any, Optional
  from streamlit import config
  from streamlit.errors import MarkdownFormattedException
  from streamlit.proto.ForwardMsg_pb2 import ForwardMsg
  from streamlit.runtime.forward_msg_cache import populate_hash_if_needed
label_desc: Use image node_id 2 for calling the MessageSizeError obj's underlying member method code with example usage: obj._get_message(failed_msg_str) and returns: str