monarch-initiative / phenopacket-store

Collections of GA4GH phenopackets that represent individuals with Mendelian diseases.
https://monarch-initiative.github.io/phenopacket-store/
BSD 3-Clause "New" or "Revised" License
14 stars 4 forks source link

Path' object has no attribute 'suffix' #133

Closed pnrobinson closed 1 month ago

pnrobinson commented 1 month ago
----> 4 store = PhenopacketStore.from_release_zip(input_zip)

File ~/GIT/phenopacket-store/src/ppktstore/model.py:94, in PhenopacketStore.from_release_zip(zip_path)
     92         cohort_name = entry_path.name
     93         cohort2path[cohort_name] = entry_path
---> 94 elif entry_path.is_file() and entry_path.suffix == '.json':
     95     # This SHOULD be a phenopacket!
     96     cohort = entry_path.parent.name  # type: ignore
     97     cohort2pp_paths[cohort].append(entry_path)

AttributeError: 'Path' object has no attribute 'suffix'"
}
ielis commented 1 month ago

This seems to be caused by running the code on Python < 3.12.

The question is - do we want to support this package on Python < 3.12 or we're OK with just 3.12?