-
Notifications
You must be signed in to change notification settings - Fork 66
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
Stream must be a resource #61
Comments
Thanks for reporting this @jasonsarino. BTW it seems that you are using the API incorrectly: |
@krizalys there is some story at msgraph-sdk-php behind this :) Original issue was reported on January and it was related to download DriveItem as stream. When it has been resolved some behavior changed. GraphRequest class have it own member $returnType and it correctly set only by call of setReturnType() method. There is different behavior for return type 'GuzzleHttp\Psr7\Stream' and anything else. Before 1.7.0-preview release at GraphRequest::execute() method 'stream' option was set directly to On release 1.7.0-preview set up 'stream' option
I think there is two ways how to fix this issue: Second way is to use returned stream at
Also, it is a good idea to add |
@jasonsarino @feesler Thanks for the details, this is fixed in Note: |
Fatal error: Uncaught exception 'InvalidArgumentException' with message 'Stream must be a resource' in /home3/o3j3v5e1/public_html/onedrive/vendor/guzzlehttp/psr7/src/Stream.php:49 Stack trace: #0 /home3/o3j3v5e1/public_html/onedrive/vendor/microsoft/microsoft-graph/src/Http/GraphResponse.php(157): GuzzleHttp\Psr7\Stream->__construct(Array) #1 /home3/o3j3v5e1/public_html/onedrive/vendor/krizalys/onedrive-php-sdk/src/Proxy/DriveItemProxy.php(368): Microsoft\Graph\Http\GraphResponse->getResponseAsObject('GuzzleHttp\Psr7...') #2 /home3/o3j3v5e1/public_html/onedrive/redirect.php(45): Krizalys\Onedrive\Proxy\DriveItemProxy->download('hello123.txt') #3 {main} thrown in /home3/o3j3v5e1/public_html/onedrive/vendor/guzzlehttp/psr7/src/Stream.php on line 49
The text was updated successfully, but these errors were encountered: