evernote-sdk-python3 icon indicating copy to clipboard operation
evernote-sdk-python3 copied to clipboard

Store. _get_thrift_client() causing invalid User Agent values

Open chenjianjx opened this issue 8 years ago • 0 comments

The generated User-Agent will not parse the validation of httpclient.

It generated such a "User-Agent" for me: b'en-devtoken:V=2 / 1.25; Python / 3.5.1 (v3.5.1:37a07cee5969, Dec 5 2015, 21:12:44) \n[GCC 4.2.1 (Apple Inc. build 5666) (dot 3)];'

And an error was raised at "File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/http/client.py", line 1060, in putheader" since function _is_illegal_header_value() says it is an invalid user agent.

I am running python3.5.1 on Mac OS inside an django app whose version is 1.9.

chenjianjx avatar Mar 02 '16 09:03 chenjianjx