S3client headObject not possible when streams are enabled after update of aws-sdk-php #107
Labels
bug
This issue is a bug.
investigating
This issue is being investigated and/or work is in progress to resolve the issue.
needs-triage
This issue or PR still needs to be triaged.
Describe the bug
After updating the aws-sdk-php from 3.305.4 to 3.325.2, my code suddenly stopped working.
After testing it further, the problem was introduced in the 3.319.4 version, 3.319.3 still works.
I get an
Stream is not seekable
exception when doing a S3Client->headObject call.Streams are enabled via the global bundle setting:
It seems to be caused by the new introduced S3Parser which allways trys to rewind the stream when checking if the 2xx result is an error:
https://github.com/yenfryherrerafeliz/aws-sdk-php/blob/bb1c0d42b646bcf4a520fe58d722b8097cc12149/src/S3/Parser/S3Parser.php#L181
Regression Issue
Expected Behavior
Returns the head infos.
Current Behavior
A
RuntimeException
with theStream is not seekable
message is thrown.Reproduction Steps
Enable streams in the bundle settings:
Call headObject on the S3Client instance
Possible Solution
No response
Additional Information/Context
No response
SDK version used
2.7.0
Environment details (OS name and version, etc.)
Linux, PHP 8.2.24 FPM, Symfony 7.0.8
The text was updated successfully, but these errors were encountered: