diff --git a/softpack_core/schemas/environment.py b/softpack_core/schemas/environment.py index 0e3b24a..15900d3 100644 --- a/softpack_core/schemas/environment.py +++ b/softpack_core/schemas/environment.py @@ -616,13 +616,15 @@ def read_metadata(cls, path: str, name: str) -> Box: """This method returns the metadata for an environment with the given path and name. """ + return artifacts.get(path, name).metadata() @classmethod def store_metadata(cls, environment_path: str, metadata: Box): - """This method writes the given metadata to the repo for the environment - path given. + """This method writes the given metadata to the repo for the + environment path given. """ + tree_oid = artifacts.create_file( environment_path, artifacts.meta_file, @@ -637,6 +639,7 @@ def set_hidden( cls, name: str, path: str, hidden: bool ) -> HiddenResponse: # type: ignore """This method sets the hidden status for the given environment.""" + environment_path = Path(path, name) response: Optional[Error] = cls.check_env_exists(environment_path) if response is not None: