Add section using git-annex-remote-zenodo to Third Party chapter #941
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
The question whether one can publish datalad datasets to Zenodo came up in the office hour chatroom. We found a resource by CONP which did not deal with annexed contents on first read, and a dedicated git-annex special remote for Zenodo that none of us yet tried.
Content-wise, a section describing a workflow to publish to Zenodo with these tools could fit into the third-party sharing chapter.
I have started to look into how this could be done. Currently, its not very convenient, and half-way broken. With the tutorial and a few fixes I got it to a state where you can push files to zenodo, and retrieve them back, but only in one and same dataset:
For anyone who wants to repeat my steps:
git-annex-remote-zenodois executable:chmod +x git-annex-remote-zenodoPATH:export PATH=$PATH:$(pwd)then, you can use it to create a Zenodo deposit, push data there, and retrieve it back:
The special remote does not publish zenodo records, you can find them as untitled drafts in your account and edit their metadata:
Be a bit careful here, if you publish something you can't delete it yourself. If you use
url=sandboxin initremote and a token from sandbox.zenodo.org, you can test in a sandbox:Things then fall apart quite quickly when I want to enable the remote in a clone.
I have investigated this a bit, and it seems like this enableremote triggers an
initremotein the specialremote with a completly new deposition id - instead of finding the former deposit, it creates a new one.I think the deposition ID needs to be recorded in the special remote to later get enabled. But I ran out of time, and will leave this investigation for the next time or person.
Sadly, the git repository the special remote implementation lives in does not have an issue tracker enabled.
Hey, I had a look into this and tried to fix the script that @adswa found.
Can someone maybe take a look at this before I continue?
Currently, the advantages are, that a new clone does not open a new deposit (so far I only checked this for the case that we have one user pushing into the deposit) and the script now checks if the deposit is published or not. If it the lastest draft is published and therefore not writeable, a new draft is made and we subsequently push into that draft.
Could be cool to have some feedback :)
hey @jkuhl-uni! This is fantastic, thanks a lot! Maybe we can use this momentum to turn this into a fully functioning special remote! I was wondering whether you could enable issues in your fork so that we could explore and develop over there? I also send a very small PR.
I only tried it out briefly, and it indeed works nicely for a single-user use case. I like how it creates a new draft when a dataset was previously published already. I was not able to add to an existing draft with a different user (I believe this is because the draft is not listed under that second user's drafts in zenodos API, even if they're authorized to manage the draft). And I have struggled to obtain files when using a second user's API key. I hope to look at this further this week. :)