salimoha / googlecl

Automatically exported from code.google.com/p/googlecl
0 stars 0 forks source link

docs edit fails when saving plain-text document from Windows #202

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?

google docs edit --folder "scratch" --format "txt" --editor "notepad" --title 
"notes"

Where a plain-text document called "notes" exists in folder "scratch"

What is the expected output? What do you see instead?

I expect the command to complete without error. Instead I see this:

Traceback (most recent call last):
  File "google", line 536, in <module>
  File "google", line 530, in main
  File "google", line 408, in run_once
  File "googlecl\docs\service.pyo", line 555, in _run_edit
  File "googlecl\docs\service.pyo", line 134, in edit_doc
  File "gdata\service.pyo", line 1394, in Put
  File "gdata\service.pyo", line 1357, in PostOrPut
gdata.service.RequestError: {'status': 400, 'body': 'Could not convert 
document.', 'reason': 'Bad Request'}

What version of the product are you using? On what operating system? What
version of gdata-python-client (aka python-gdata)?

GoogleCL v0.9.8
gdata-2.0.10
Windows XP Professional SP3

Please provide any additional information below.

This was working in GoogleCL v0.9.7.

Original issue reported on code.google.com by itruett on 2 Jul 2010 at 1:47

GoogleCodeExporter commented 9 years ago
I'm suspecting that sometime after this worked for you in 0.9.7, you converted 
to using new-version docs. If the new version in the trunk does not work for 
you, please let me know and I'll un-merge this issue and take a look.

Original comment by tom.h.mi...@gmail.com on 12 Jul 2010 at 9:44

GoogleCodeExporter commented 9 years ago
r342 isn't running for me. But r340 works.

Error with r342:

AttributeError: 'module' object has no attribute 'uname'

I don't think this error is related to this issue at all. Let me know if you 
need me to open a new issue, but I'm guessing it was just something missing 
from the r342 commit.

Original comment by itruett on 12 Jul 2010 at 10:05

GoogleCodeExporter commented 9 years ago
Yup, I used os.uname which isn't supported on windows. r343 should be working 
for you.

Thanks for the quick response!

Original comment by tom.h.mi...@gmail.com on 12 Jul 2010 at 10:20