Problem/Motivation
Can't make Sentry work with Raven module after upgrade to PHP 7.4 from PHP 7.0.
Steps to reproduce
PHP 7.2 or PHP 7.4
Raven 7.x-4.2
composer require sentry/sentry
Ok, Sentry 3 is installed via composer. composer_autoloader module is enabled.
/admin/reports/status says that Sentry PHP SDK is loaded. But drush raven-capture-message 'test' says `Raven client not available.`. Trying to call not existing function is not getting captured by Sentry neither.
Sentry PHP handler is enabled, Sentry DSN is set. What am I missing?
Raven 7.x-3.9
ls sites/all/libraries/sentry-php/lib/Raven/Client.php
sites/all/libraries/sentry-php/lib/Raven/Client.php
I have Libraries API 2, XAutoload and Sentry PHP library installed as described in README, but /admin/reports/status says "The Sentry PHP library could not be loaded".
composer require sentry/sentry ^1.11.0
Sentry 3.1 gets installed. It is not supported by Raven 7.x-3.9.
composer require sentry/sentry 1.11.0
1.x version can't be installed via composer:
./composer.json has been updated
Loading composer repositories with package information
Updating dependencies (including require-dev)
Your requirements could not be resolved to an installable set of packages.
Problem 1
- sentry/sdk 3.1.0 requires sentry/sentry ^3.1 -> satisfiable by sentry/sentry[3.1.0, 3.1.1, 3.1.x-dev] but these conflict with your requirements or minimum-stability.
- sentry/sdk 3.1.0 requires sentry/sentry ^3.1 -> satisfiable by sentry/sentry[3.1.0, 3.1.1, 3.1.x-dev] but these conflict with your requirements or minimum-stability.
- sentry/sdk 3.1.0 requires sentry/sentry ^3.1 -> satisfiable by sentry/sentry[3.1.0, 3.1.1, 3.1.x-dev] but these conflict with your requirements or minimum-stability.
- Installation request for sentry/sdk (locked at 3.1.0) -> satisfiable by sentry/sdk[3.1.0].
Comments
Comment #2
quotesbro commentedComment #4
mfbThank you for the report, there was a typo in the README! For 7.x-4.x you should use
composer require sentry/sdk:^3Comment #5
quotesbro commentedI tried sentry/sdk:^3. It is listed on Status report page:
Sentry PHP SDK 3.1.1drush raven-capture-message 'test'says `Raven client not available.`. Trying to call not existing function is not getting captured by Sentry neither.Comment #6
quotesbro commentedComment #7
mfbWhat does
drush status-report | grep Sentrysay?Comment #8
mfbThere are only two cases that I know of where you could see "Raven client not available": 1) Sentry SDK is not installed and autoloaded - but it sounds like it is if the status report is showing "Sentry PHP SDK 3.1.1" or 2) Sentry DSN has invalid configuration, for example has a space at the start. Can you double check that the PHP Sentry DSN is configured correctly?
Comment #9
quotesbro commentedOops, I double-checked and found out that my quota is depleted.
Thank you for your time!