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

osf clone fails with a KeyError #169

Open
habi opened this issue Jul 17, 2019 · 4 comments
Open

osf clone fails with a KeyError #169

habi opened this issue Jul 17, 2019 · 4 comments
Labels

Comments

@habi
Copy link

habi commented Jul 17, 2019

I'm preparing the submission of a manuscript and would like to test how readers can perform reproducible research with our data.
I managed to upload a great bunch of files but now cannot download them on another machine.
In an empty directory I'd like to download them with osf -p a5esx clone gills.
The command quits after a short while with

Traceback (most recent call last):
  File "/home/habi/miniconda3/bin/osf", line 10, in <module>
    sys.exit(main())
  File "/home/habi/miniconda3/lib/python3.7/site-packages/osfclient/__main__.py", line 104, in main
    exit_code = args.func(args)
  File "/home/habi/miniconda3/lib/python3.7/site-packages/osfclient/cli.py", line 91, in wrapper
    return_value = f(cli_args)
  File "/home/habi/miniconda3/lib/python3.7/site-packages/osfclient/cli.py", line 167, in clone
    file_.write_to(f)
  File "/home/habi/miniconda3/lib/python3.7/site-packages/osfclient/models/file.py", line 57, in write_to
    int(response.headers['Content-Length']))
  File "/home/habi/miniconda3/lib/python3.7/site-packages/requests/structures.py", line 52, in __getitem__
    return self._store[key.lower()][1]
KeyError: 'content-length'

How can I instruct a keen reader of our manuscript to easily get the data?

@habi
Copy link
Author

habi commented Aug 6, 2019

Hello?

habi added a commit to habi/Zebra-Fish-Gills that referenced this issue Aug 6, 2019
@habi
Copy link
Author

habi commented Aug 23, 2019

It's now been more than a month, we now submitted the manuscript (and the accompanying Jupyter notebook) without the possibility to directly download the data.
To allow for reproducible research I whipped up a small bash script which downloads each single ZIP file separately. The script is linked above in the commit reference...

Nonetheless, I'd really like to get this fixed and not present the workaround to our (potential) readers.

@benlindsay
Copy link
Collaborator

As someone who is technically a maintainer of this because I got added back when I had some bandwidth to make a few PRs, I think it's fair to say that unfortunately this project is probably going to be stagnant until we can get some new people with some time and interest in this. I think some of the original developers on this are busy with bigger and better things, and I'll be leaving academia soon, so I don't really anticipate using or working on this tool moving forward. That said, if you or anyone else wanted to contribute moving I'd be happy to help get started. Otherwise, unfortunately for now your workaround bash script will have to do.

@habi
Copy link
Author

habi commented Aug 23, 2019

Thanks for the information.
It's sad that the project is stagnant.
I'll leave the issue open, so other interested people can find this information.

@felliott felliott added the bug label Sep 11, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants