class_docstr: Store a mapping from keys to multiple values with minimal overhead.
  
  Avoids storing empty collections.
code: def get_one(self, k: K, duplicate_error: str) -> V | None:
      """ """
      existing = self._dict.get(k)
      if isinstance(existing, set):
          existing = cast(set[V], existing)
          if len(existing) == 1:
              return next(iter(existing))
          else:
              raise ValueError(f"{duplicate_error}: {existing!r}")
      else:
          return existing
  
file_path: bokeh/src/bokeh/util/datatypes.py
imports: from __future__ import annotations
  import logging
  from typing import Generic, TypeVar, cast
label_desc: Use image node_id 4 for calling the MultiValuedDict obj's underlying member method code with example usage: obj.get_one(k, duplicate_error) and returns: existing, next