httpie-aws-authv4
httpie-aws-authv4 copied to clipboard
TypeError: object supporting the buffer API required with BufferedReader requests
Very similar to Issue 10, we are seeing an issue when POSTing some piped content, e.g. via here file:
http -A aws4 POST $AWS_ES_URL/some_index/doc/TEST:1 <<<'{"SOME":"text"}'
...
http: error: TypeError: object supporting the buffer API required
In this case, the body appears to be a BufferedReader
, with BufferedIOBase
superclass defining the read()
method.
Materializing the reader using read()
works around that problem, at the cost of loading the body into memory.
Proposed fix: https://github.com/DavidMuller/aws-requests-auth/pull/64
Thank you for reporting this! I will keep an eye on the linked PR and bump the dependency when it is resolved.