Pierre-Lannoy / wp-traffic

Full featured monitoring & analytics for WordPress APIs.
https://perfops.one/
GNU General Public License v3.0
8 stars 1 forks source link

Can't activate Traffic #4

Open zorglube opened 7 months ago

zorglube commented 7 months ago

Describe the bug I installed Traffic 2.13.0 into a Wordpress 6.5.2 witch is deployed with Bedrock on Clever-Cloud : https://github.com/zorglube/clever-wordpress I couldn't activate the plugin. Here is the error message : 2024-04-30T14:03:12+02:00 [Tue Apr 30 12:03:06.361580 2024] [proxy_fcgi:error] [pid 1294:tid 139919294990016] [client 91.208.207.217:52646] [145.248.195.1] AH01071: Got error 'PHP message: PHP Fatal error: Declaration of DecaLog\\EventsLogger::emergency($message, $context = []) must be compatible with Psr\\Log\\LoggerInterface::emergency(Stringable|string $message, array $context = []): void in /home/bas/XXXXXXXX/web/app/plugins/traffic/includes/libraries/decalog-sdk/EventsLogger.php on line 74', referer https://blog.broncotoxique.com/wp/wp-admin/plugins.php

I'm not really a good at Wordpress, still I'll do my mest to respond all your question.

To Reproduce Steps to reproduce the behavior:

  1. Fork https://github.com/zorglube/clever-wordpress
  2. Deploy on clever-cloud
  3. Add Traffic https://github.com/zorglube/clever-wordpress/pull/50
  4. Re-deploy
  5. Try activate Traffic
  6. See error

Expected behavior Traffic work withour errors

Environment (please complete the following information):

Additional context My Wordpress instance is deployed the immutable way.

Pierre-Lannoy commented 7 months ago

Hello @zorglube ! And thanks for the report ;) Yes, I know there's a problem with PSR versions. What you see is mainly due to another component of your install that's using PSR3 v3 while Traffic uses v1. The problem will be fixed in the next release (I'm working on it for a some weeks now).

zorglube commented 7 months ago

Ok, I wait.