2525from renku .core .migration .models .v9 import Person as OldPerson
2626from renku .core .migration .models .v9 import generate_project_id , wfprov
2727from renku .core .migration .utils import OLD_METADATA_PATH , generate_dataset_tag_id , generate_url_id , get_datasets_path
28+ from renku .core .util import yaml
2829from renku .core .util .urls import get_host
29- from renku .domain_model import jsonld
3030
3131
3232class Base :
@@ -86,7 +86,7 @@ class Project(Base):
8686 @classmethod
8787 def from_yaml (cls , path , client ):
8888 """Read content from YAML file."""
89- data = jsonld .read_yaml (path )
89+ data = yaml .read_yaml (path )
9090 self = ProjectSchemaV3 ().load (data )
9191
9292 if not self .creator :
@@ -107,7 +107,7 @@ def to_yaml(self, path):
107107 self .agent_version = __version__
108108
109109 data = ProjectSchemaV3 ().dump (self )
110- jsonld .write_yaml (path = path , data = data )
110+ yaml .write_yaml (path = path , data = data )
111111
112112
113113class Collection (Base ):
@@ -166,7 +166,7 @@ class Dataset(Base):
166166 @classmethod
167167 def from_yaml (cls , path , client = None , commit = None ):
168168 """Read content from YAML file."""
169- data = jsonld .read_yaml (path )
169+ data = yaml .read_yaml (path )
170170 self = DatasetSchemaV3 (client = client , commit = commit ).load (data )
171171 self ._metadata_path = path
172172 return self
@@ -175,7 +175,7 @@ def to_yaml(self, path=None):
175175 """Write content to a YAML file."""
176176 data = DatasetSchemaV3 ().dump (self )
177177 path = path or self ._metadata_path or os .path .join (self .path , OLD_METADATA_PATH )
178- jsonld .write_yaml (path = path , data = data )
178+ yaml .write_yaml (path = path , data = data )
179179
180180
181181class PersonSchemaV3 (JsonLDSchema ):
0 commit comments