Check that .metadata.yaml actually contains a dict
It might just be empty (= None) or a list or something. Thanks @Kunsi for the heads-up.
This commit is contained in:
parent
e508898564
commit
ec55890c55
1 changed files with 3 additions and 2 deletions
|
|
@ -1353,8 +1353,9 @@ class LocalFileStorage(StorageInterface):
|
|||
except:
|
||||
self._logger.exception("Error while reading .metadata.yaml from {path}".format(**locals()))
|
||||
else:
|
||||
self._metadata_cache[path] = deepcopy(metadata)
|
||||
return metadata
|
||||
if isinstance(metadata, dict):
|
||||
self._metadata_cache[path] = deepcopy(metadata)
|
||||
return metadata
|
||||
return dict()
|
||||
|
||||
def _save_metadata(self, path, metadata):
|
||||
|
|
|
|||
Loading…
Reference in a new issue