zenodo-rdm
zenodo-rdm copied to clipboard
legacy: handle external/datacite DOI changes
The issue is that the behaviour of passing the pids
field as input via the create()/update()
service methods is a bit flaky (even in the "stock" RDM API). E.g. if one passes a doi
with datacite
provider, and then changes over to external
, there are additional calls necessary to un-reserve the datacite
DOI... You can check the REST API calls in the default InvenioRDM deposit form and see that there are more calls happening to /api/records/{id}/draft/pids
. These service calls must be "baked-in" the Zenodo legacy REST API.
Since this is actually a bit difficult to handle fully now, I would say let's make the happy paths work (i.e. A. publish with Zenodo DOI, and B. publish with an external DOI), and we tackle the edge cases separately.
Originally posted by @slint in https://github.com/zenodo/zenodo-rdm/pull/330#discussion_r1200700383