Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Download all files from record #5

Open
mpariente opened this issue May 23, 2020 · 4 comments
Open

Download all files from record #5

mpariente opened this issue May 23, 2020 · 4 comments

Comments

@mpariente
Copy link

Hi,

The Readme says we can download from Zenodo, how can I do that with pyzenodo please? Preferably, I'd like to download all files in the same time.

Thanks,

@mpariente
Copy link
Author

Ok, I can use search and then download all the files with their links, that seems feasible.

However, I'm not able to find my records, this one for example.
This is the code I used.

import pyzenodo3

# BASE_URL = "https://zenodo.org/api/"
BASE_URL = "https://sandbox.zenodo.org/api/"

zen = pyzenodo3.Zenodo(base_url=BASE_URL)
res = zen.search('This is my asteroid-model upload')
print(res)
for r in res: 
    print(r.data['metadata']['creators']) 

I would expect to find myself in in the creators, but I don't.

Also, I'm not sure what is queried, is it the description, the title etc?
Could you also provide a command to list all records in a community? That would be great !

@drscotthawley
Copy link

I too am confused on how to use pyzenodo to download a dataset programmatically. I don't see any methods like zen.download()...? Adding some documentation on this would be very helpful!

@abhi-glitchhg
Copy link

Hmm, I know this is way late, but i am currently working on a way to include the download method on a Record object. Will let you know the status in few days. Thank you!

@abhi-glitchhg
Copy link

Hey @mpariente, @drscotthawley, @scivision if you have some spare time, could you give it a look and see if this thing is working for your use case? your feedback is appreciated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants