Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TypeError: object supporting the buffer API required with BufferedReader requests #15

Open
m9aertner opened this issue Jun 15, 2022 · 2 comments

Comments

@m9aertner
Copy link

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.

@m9aertner
Copy link
Author

Proposed fix: DavidMuller/aws-requests-auth#64

@aidan-
Copy link
Owner

aidan- commented Jun 16, 2022

Thank you for reporting this! I will keep an eye on the linked PR and bump the dependency when it is resolved.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants