docs: def load_yaml(fname):
      """Load a YAML file."""
      yaml = YAML(typ="safe")
      # Compat with HASS
      yaml.allow_duplicate_keys = True
      # Stub HASS constructors
      HassSafeConstructor.name = fname
      yaml.Constructor = HassSafeConstructor
  
      with open(fname, encoding="utf-8") as conf_file:
          # If configuration file is empty YAML returns None
          # We convert that to an empty dict
          return yaml.load(conf_file) or {}