elifesciences / elife-crossref-xml-generation

Crossref deposit of journal articles
MIT License
4 stars 3 forks source link

Add clinical trials data to Crossmark custom_data #88

Closed gnott closed 4 years ago

gnott commented 4 years ago

Re issue https://github.com/elifesciences/elife-crossref-feed/issues/146

CrossMark program, if the depositor is participating, can also accept clinical trial data in the <custom_meta> tag of the Crossref deposit.

The ClinicalTrial object will be populated when article XML is parsed.

The elifecrossref/clinical_trials.py module is new, which includes

In order to download the registries XML from Crossref, requests library is now a requirement for this library.

The hook to add clinical trials is added to the elifecrossref/crossmark.py module.

There are tests to cover

coveralls commented 4 years ago

Coverage Status

Coverage remained the same at 100.0% when pulling 606f40019dcfec6dd9915d6581e6661eaf01f4da on clinical-trials into 31ab5ba778e83fcaef50ec5ce3c44ce7330a1b63 on develop.

gnott commented 4 years ago

I will also mention, I didn't add an exception handling around getting the registries XML, so I guess we'd rely on the exception being caught upstream from this. A possible addition could be to check the status_code of the GET and log some things here.