code: def serialize(self):
          
          import yaml
          output = {"metadata": self.metadata, "sources": {},
                    "name": self.name}
          for key, entry in self.items():
              output["sources"][key] = entry._captured_init_kwargs
          return yaml.dump(output)
docs: Produce YAML version of this catalog.
  
          Note that this is not the same as ``.yaml()``, which produces a YAML
          block referring to this catalog.