[issue32475] Add ability to query number of buffered bytes available on buffered I/O

2018-06-26 Thread Josh Snyder
Josh Snyder added the comment: I've opened PR #7947 with another approach to this issue. In my use-case, an HTTP client makes a request and uses buffered I/O to parse the response headers. I would like to hand off the response socket to an extension module for use with raw I/O syscalls. The

[issue32475] Add ability to query number of buffered bytes available on buffered I/O

2018-06-26 Thread Josh Snyder
Change by Josh Snyder : -- pull_requests: +7556 stage: -> patch review ___ Python tracker ___ ___ Python-bugs-list mailing list Uns

[issue32475] Add ability to query number of buffered bytes available on buffered I/O

2018-01-15 Thread Martin Panter
Martin Panter added the comment: If I remember the implementation of “peek” right, it may do what you want. But the documentation doesn’t guarantee much about its behaviour; see Issue 5811. Anyway, I agree that a “getbuffn” method (or property) would be nice. (Perhaps with a better name!) But

[issue32475] Add ability to query number of buffered bytes available on buffered I/O

2018-01-01 Thread Antoine Pitrou
Antoine Pitrou added the comment: Why don't you use BufferedReader.peek()? -- nosy: +pitrou ___ Python tracker ___ ___ Python-bugs-l

[issue32475] Add ability to query number of buffered bytes available on buffered I/O

2018-01-01 Thread Tim Savannah
New submission from Tim Savannah : Hello! This is my first time submitting to Python bug tracker, so please bear with me if I miss/mess something. So a little bit of relevant background, I'm an avid python developer with many open-source projects. One of the projects I wrote and maintain is