You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm using nyholm/psr7, but that shouldn't matter - if your StreamInterface implementation is somehow rewinding the body stream automatically after write (or isn't moving the stream pointer ahead in the first place) it isn't following the PSR-7 spec.
The text was updated successfully, but these errors were encountered:
The returned
ResponseInterface
instance contains aStreamInterface
instance that isn't ready to read.The issue is here:
http-client-curl/src/Client.php
Lines 206 to 231 in 7da8dbd
The response gets returned after writing to the stream, which means the stream pointer will be at the end of the stream.
After writing to the response body stream (in line 228) you need to rewind the stream, e.g.:
I'm using
nyholm/psr7
, but that shouldn't matter - if yourStreamInterface
implementation is somehow rewinding the body stream automatically afterwrite
(or isn't moving the stream pointer ahead in the first place) it isn't following the PSR-7 spec.The text was updated successfully, but these errors were encountered: