Laravel since version 7.0 supports guzzlehttp/guzzle 7 versions.
The guzzlehttp/guzzle package released version 7.0.0 on June 27th.
Could you add support for your package?
Hi @andrey-helldar, in time we can for sure. However we use HTTPlug under the hood and they have yet to release a Guzzle 7 adapter. I'm sure this will happen (issue/pr), but we have to wait for that at the moment. Since Guzzle 7 was released 5 days ago at the time of this comment, give it some time 馃槃
Edit: Also this will likely be fixed in https://github.com/getsentry/sentry-php-sdk and not in this package directly.
In the package https://github.com/getsentry/sentry-php-sdk there is no way to create issue, so I opened it here in the parent project 馃檪
Well, wait until they create the project 馃槉
Hi @stayallive, I think since Guzzle 7 is PSR-18 compliant (https://github.com/php-http/guzzle6-adapter/issues/73#issuecomment-651122068) there is no need to use an adapter for HTTPlug. Maybe it is possible to use sentry/sentry directly with Guzzle 7 instead of sentry/sdk?
Yes, you are correct @Brenneisen, although I've not tested this method you should be able to replace the sentry/sdk package and provide your own PSR-18 complaint package.
{
"require": {
"sentry/sentry-laravel": "^1.8",
"http-interop/http-factory-guzzle": "^1.0",
"php-http/guzzle6-adapter": "^1.1|^2.0"
},
"replace": {
"sentry/sdk": "*"
}
}
The above should be equal to just having:
{
"require": {
"sentry/sentry-laravel": "^1.8"
}
}
And you should be able to pull out / replace the http-interop and php-http packages.
We provide sentry/sdk as a quick way to install the correct dependencies and I don't believe there is an easy way for us to allow both Guzzle 6 and 7 right now (using sentry/sdk), open for suggestions ofcourse.
Hmm, this too is preventing from upgrading to Guzzle 7 as I've direct dependency in my application too:
$ ./composer.phar depends guzzlehttp/guzzle
laravel/laravel dev-master requires guzzlehttp/guzzle (^6.1)
aws/aws-sdk-php 3.147.10 requires guzzlehttp/guzzle (^5.3.3|^6.2.1|^7.0)
caseyamcl/guzzle_retry_middleware v2.3.3 requires guzzlehttp/guzzle (^6.3|^7.0)
google/apiclient v2.7.0 requires guzzlehttp/guzzle (~5.3.1||~6.0||~7.0)
google/auth v1.11.1 requires guzzlehttp/guzzle (^5.3.1|^6.2.1|^7.0)
laravel/slack-notification-channel v2.1.0 requires guzzlehttp/guzzle (^6.0|^7.0)
php-http/guzzle6-adapter v2.0.1 requires guzzlehttp/guzzle (^6.0)
wildbit/swiftmailer-postmark 3.1.0 requires guzzlehttp/guzzle (^6.0.0)
The only other is https://github.com/wildbit/swiftmailer-postmark which has a PR https://github.com/wildbit/swiftmailer-postmark/pull/27 but no one is doing anything there; but _that_ package I can easily replace with a custom driver if must be.
But commercially depending on Sentry prevents me from just removing it 馃槄
@mfn, for Postmark it's a bit "easier" since they directly depend on Guzzle and can just add 7.x as an allowed version. We have it a bit more complicated because we use a meta package to pull in the Guzzle integration but that uses HTTPlug to interface with Guzzle and that interface has not yet updated (and is not under out control) to be able to use Guzzle 7 (php-http/guzzle6-adapter#72).
If you want / must / require Guzzle 7 for some reason see here: https://github.com/getsentry/sentry-laravel/issues/371#issuecomment-689084918.
There is an workaround available (https://github.com/getsentry/sentry-laravel/issues/360#issuecomment-667851533) so I'm going to close this issue to track it on the main SDK repository since it's not only Laravel related but has effect on all PHP integrations.
See getsentry/sentry-php#1059 for progress updates.
Most helpful comment
@mfn, for Postmark it's a bit "easier" since they directly depend on Guzzle and can just add
7.xas an allowed version. We have it a bit more complicated because we use a meta package to pull in the Guzzle integration but that uses HTTPlug to interface with Guzzle and that interface has not yet updated (and is not under out control) to be able to use Guzzle 7 (php-http/guzzle6-adapter#72).If you want / must / require Guzzle 7 for some reason see here: https://github.com/getsentry/sentry-laravel/issues/371#issuecomment-689084918.