-
Notifications
You must be signed in to change notification settings - Fork 535
Description
When we use Dataverse's API endpoint for creating a link to a dataset (see section in API guides), and that dataset is unpublished, the endpoint returns the following error message:
$ curl -H "X-Dataverse-key: $API_TOKEN" -X PUT http://localhost:8080/api/datasets/$DATASET_ID/link/$DATAVERSE_ALIAS
{"status":"ERROR","message":"Can't link a dataset that has not been published or is not harvested"}
I think the clause "is not harvested" should be removed from that error message because:
-
It's confusing. If we remove "that has not been published" from the sentence, we get "Can't link a dataset that... is not harvested". Datasets that are not harvested are "local", and of course we can link datasets that are local. I think the "not" was a typo and what was meant was: "Can't link a dataset that has not been published or is harvested". But...
-
We are able to use the endpoint to create links to harvested datasets, which I've done several times when users have requested that datasets published in other repositories appear in their collections in Harvard Dataverse.
So even if the endpoint was designed with the intent to prevent users from creating links to harvested datasets, this has been technically possible for years and I think should remain possible.
So I think the error message should say something like:
"Can't link a dataset that has not been published"
Related GitHub issues: