Skip to content

Commit 3d3b2b1

Browse files
committed
Use default attrs
1 parent bdfc69e commit 3d3b2b1

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/DPR/DPR_processor_mock.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -115,8 +115,9 @@ def payload_to_url(self):
115115
@staticmethod
116116
def read_attrs(path: pathlib.Path):
117117
"""Read zarr attributes from zip or folder."""
118-
data = zipfile.ZipFile(path, "r").read(f"{path.stem}/.zattrs") if path.suffix == ".zip" else open(path / ".zattrs").read()
119-
return json.loads(data)
118+
#data = zipfile.ZipFile(path, "r").read(f"{path.stem}/.zattrs") if path.suffix == ".zip" else open(path / ".zattrs").read()
119+
with open(pathlib.Path(__file__).resolve().parent / "default_zattrs.json") as data:
120+
return json.loads(data.read())
120121

121122
def update_product(self, path: pathlib.Path, ptype):
122123
default_processing_stamp = {

0 commit comments

Comments
 (0)