code: def _unify_entry_points(project_table: dict):
      project = project_table
      entry_points = project.pop(
          "entry-points", project.pop("entry_points", {})
      )
      renaming = {
          "scripts": "console_scripts",
          "gui_scripts": "gui_scripts",
      }
      for key, value in list(
          project.items()
      ):  # eager to allow modifications
          norm_key = json_compatible_key(key)
          if norm_key in renaming:
              # Don't skip even if value is empty (reason: reset missing `dynamic`)
              entry_points[renaming[norm_key]] = project.pop(key)
  
      if entry_points:
          project["entry-points"] = {
              name: [f"{k} = {v}" for k, v in group.items()]
              for name, group in entry_points.items()
              if group  # now we can skip empty groups
          }
  
imports: import logging
  import os
  from collections.abc import Mapping
  from email.headerregistry import Address
  from functools import partial, reduce
  from inspect import cleandoc
  from itertools import chain
  from types import MappingProxyType
  from typing import TYPE_CHECKING, Any, Callable, Dict, List, Optional, Set, Tuple, Type, Union, cast
  from ..errors import RemovedConfigError
  from ..warnings import SetuptoolsWarning
label_desc: Use image node_id 15 for calling a global function with example usage: _unify_entry_points(project_table) without return types