yadayada / acd_cli

An unmaintained command line interface and FUSE filesystem for Amazon (Cloud) Drive
Other
1.35k stars 166 forks source link

RequestError: 400 InvalidArgument with mount (non-english filename & > 10GB) #451

Open Em31Et opened 7 years ago

Em31Et commented 7 years ago

I cannot download the file with non-english filename and > 10GB via Web UI. I don't know whether acd_cli is using the same mechanism with Amazon Drive Web UI. Just want to know, is it acd_cli issue or Amazon Drive? Thanks.

When i access any file with non-english filename and > 10GB, acd_cli always throw the exception RequestError: 400

16-10-22 15:52:06.051 [ERROR] [acdcli.acd_fuse] - get: RequestError: 400, <?xml version="1.0" encoding="UTF-8"?>
<Error><Code>InvalidArgument</Code><Message>Header value cannot be represented using ISO-8859-1.</Message><ArgumentName>response-content-disposition</ArgumentName><ArgumentValue>attachment; filename="你好嗎.mkv"
</ArgumentValue><RequestId>A46878470571C7BAF3E</RequestId><HostId>WX0OxzIc4K+UC6B5/s8zvpifXDr5zHXTP+X9+u773+fDgEUYAsLuHptlGXasbQCsOQnoK22NDvjLk=</HostId></Error>
Traceback (most recent call last):
  File "/usr/local/lib/python3.5/dist-packages/acdcli/acd_fuse.py", line 168, in get
    timeout=self.timeout)
  File "/usr/local/lib/python3.5/dist-packages/acdcli/acd_fuse.py", line 101, in __init__
    self.r = acd_client.response_chunk(id_, offset, length, **kwargs)
  File "/usr/local/lib/python3.5/dist-packages/acdcli/api/content.py", line 361, in response_chunk
    raise RequestError(r.status_code, r.text)
acdcli.api.common.RequestError: RequestError: 400, <?xml version="1.0" encoding="UTF-8"?>
<Error><Code>InvalidArgument</Code><Message>Header value cannot be represented using ISO-8859-1.</Message><ArgumentName>response-content-disposition</ArgumentName><ArgumentValue>attachment; filename="你好嗎.mkv"
</ArgumentValue><RequestId>A46878470571C7BAF3E</RequestId><HostId>WX0OxzIc4K+UC6B5/s8zvpifXDr5zHXTP+X9+u773+fDgEUYAsLuHptlGXasbQCsOQnoK22NDvjLk=</HostId></Error>
yadayada commented 7 years ago

I tested this on a 16GB file that was downloadable. I changed the file name in the web interface and tried to download again (without syncing first) and also got a 400 error.