code: def validate_menu_items(menu_items: MenuItems) -> None:
      for k, v in menu_items.items():
          if not valid_menu_item_key(k):
              raise StreamlitAPIException(
                  "We only accept the keys: "
                  '"Get help", "Report a bug", and "About" '
                  f'("{k}" is not a valid key.)'
              )
          if v is not None:
              if not valid_url(v) and k != ABOUT_KEY:
                  raise StreamlitAPIException(
                      f'"{v}" is a not a valid URL!'
                  )
  
file_path: streamlit/lib/streamlit/commands/page_config.py
imports: import random
  from textwrap import dedent
  from typing import TYPE_CHECKING, Mapping, Optional, Union, cast
  from urllib.parse import urlparse
  from typing_extensions import Final, Literal, TypeAlias
  from streamlit.elements import image
  from streamlit.errors import StreamlitAPIException
  from streamlit.proto.ForwardMsg_pb2 import ForwardMsg
  from streamlit.proto.PageConfig_pb2 import PageConfig
  from streamlit.runtime.metrics_util import gather_metrics
  from streamlit.runtime.scriptrunner import get_script_run_ctx
  from streamlit.string_util import is_emoji
  from streamlit.util import lower_clean_dict_keys
label_desc: Use image node_id 5 for calling a global function with example usage: validate_menu_items(menu_items) without return types