biosimulators / Biosimulators_utils

Utilities for building standardized command-line interfaces for biosimulation software packages
https://docs.biosimulators.org/Biosimulators_utils
MIT License
4 stars 6 forks source link

Add to_json and from_json method to JournalArticle class #78

Closed bilalshaikh42 closed 2 years ago

bilalshaikh42 commented 2 years ago

I have a small hack function to save the journal article to a json file to avoid calling the NCBI API too much. It would be helpful to incorporate this into the class

bilalshaikh42 commented 2 years ago

I am silly. JournalArticle is a data class and I can just use the asDict method

jonrkarr commented 2 years ago

For caching HTTP queries, I like requests-cache.

The Entrez methods are probably easiest to cache externally. One option is something like https://pypi.org/project/diskcache/.

jonrkarr commented 2 years ago

Dataclass is nice. Unfortunately, I wasn't aware of this when we started.