code: def write_error(self, status_code: int, **kwargs) -> None:
      if status_code == 404:
          index_file = os.path.join(
              file_util.get_static_dir(), "index.html"
          )
          self.render(index_file)
      else:
          super().write_error(status_code, **kwargs)
  
imports: import os
  import tornado.web
  from streamlit import config, file_util
  from streamlit.logger import get_logger
  from streamlit.runtime.runtime_util import serialize_forward_msg
  from streamlit.web.server.server_util import emit_endpoint_deprecation_notice
label_desc: Use image node_id 4 for calling the StaticFileHandler obj's underlying member method code with example usage: obj.write_error(status_code) without return types