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

Using the Uploader class directly fails because of no headers #14

Closed
peixian opened this issue Nov 15, 2017 · 2 comments
Closed

Using the Uploader class directly fails because of no headers #14

peixian opened this issue Nov 15, 2017 · 2 comments

Comments

@peixian
Copy link

peixian commented Nov 15, 2017

When using the uploader.py file like so:

from tusclient.uploader import Uploader

my_uploader = Uploader('path/to/file.ext',
                       url='http://master.tus.io/files/abcdef123456',
                       chunk_size=200)

a 'NoneType' object has no attribute 'headers' error is raised. This is because self.headers is never set, resulting in the error when self.getoffset() is called: https://github.com/tus/tus-py-client/blob/master/tusclient/uploader.py#L92

@ifedapoolarewaju
Copy link
Contributor

@peixian thank you for reporting. I'll work on this, but please also feel free to submit a PR :)

@ifedapoolarewaju
Copy link
Contributor

this issue is fixed here

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

2 participants