Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- problems when using google docs api python version to upload file of arbitrary type [closed]
- bash-4.1$ python resumable_upload_sample.py
- Enter path to a file: /home/myfolder/test.txt
- Please choose the authorization mechanism you want to use.
- 1. to use your email address and password (ClientLogin)
- 2. to use a web browser to visit an auth web page (AuthSub)
- 3. if you have registed to use OAuth
- : 1
- Please enter your username: mylogin@gmail.com
- Password:
- Enter title for the document: test.txt
- Uploading /home/myfolder/test.txt ( text/plain ) @ 10 bytes...
- Traceback (most recent call last):
- File "resumable_upload_sample.py", line 221, in <module>
- main()
- File "resumable_upload_sample.py", line 213, in main
- gdata.docs.data.DocsEntry(title=atom.data.Title(text=title)))
- File "resumable_upload_sample.py", line 127, in UploadInManualChunks
- self.uploader._InitSession(uri, entry=new_entry)
- File "/usr/lib/python2.7/site-packages/gdata/client.py", line 944, in _init_session
- http_request=http_request)
- File "/usr/lib/python2.7/site-packages/gdata/client.py", line 265, in request
- uri=uri, auth_token=auth_token, http_request=http_request, **kwargs)
- File "/usr/lib/python2.7/site-packages/atom/client.py", line 117, in request
- return self.http_client.request(http_request)
- File "/usr/lib/python2.7/site-packages/atom/http_core.py", line 420, in request
- http_request.headers, http_request._body_parts)
- File "/usr/lib/python2.7/site-packages/atom/http_core.py", line 488, in _http_request
- connection.putheader(header_name, value)
- File "/usr/lib64/python2.7/httplib.py", line 924, in putheader
- str = '%s: %s' % (header, 'rnt'.join(values))
- TypeError: sequence item 0: expected string, int found
- 'xfa'.join([1,2,3])
- TypeError: sequence item 0: expected string, int found
Add Comment
Please, Sign In to add comment