@Findus23 opened this Issue on December 1st 2019 Member

As reported in https://forum.matomo.org/t/error-php-deprecated-auto-archiving/35190 and https://github.com/matomo-org/matomo/issues/14821#issuecomment-525816696 (the next time I'll create a sparate issue for every bug/warning).
I can't reproduce it on my empty testinstance anymore, but it still seems to happen.

/var/www/matomo-beta/core/DataTable/Filter/ColumnDelete.php(164): Deprecated - array_key_exists(): Using array_key_exists() on objects is deprecated. Use isset() or property_exists() instead - Matomo 3.11.0

https://github.com/matomo-org/matomo/blob/b16a791aa3650d85af829156129c2bd44c7cb075/core/DataTable/Filter/ColumnDelete.php#L164

@tsteur commented on December 1st 2019 Member

I suppose there is no chance to get a stack trace? Any chance we can find out when this happens or on which URL this is triggered?

Ideally, for performance reasons, we would avoid needing to call is_array|isobject for each row there but may not be possible to workaround this. In general, we might not really support returning objects so be good to find out where this is triggered.

@sgiehl commented on December 2nd 2019 Member

Wouldn't it be enough to check for isset($row[$column]) instead of the array_key_exists? As $row should implement ArrayAccess, isset should work as well and avoid the warning.

@tsteur commented on December 2nd 2019 Member

isset might just ignore null values... not sure if that's wanted?

@tsteur commented on December 2nd 2019 Member

Created https://github.com/matomo-org/matomo/pull/15224 for now just to be safe...

@Eckybrazzz commented on December 2nd 2019
PHP Deprecated:  Array and string offset access syntax with curly braces is deprecated in /home/nginx/domains/analytics.domain.com/public/libs/upgradephp/upgrade.php on line 180
PHP Deprecated:  Array and string offset access syntax with curly braces is deprecated in /home/nginx/domains/analytics.domain.com/public/libs/upgradephp/upgrade.php on line 194
PHP Deprecated:  Array and string offset access syntax with curly braces is deprecated in /home/nginx/domains/analytics.domain.com/public/libs/upgradephp/upgrade.php on line 194
PHP Deprecated:  Array and string offset access syntax with curly braces is deprecated in /home/nginx/domains/analytics.domain.com/public/libs/upgradephp/upgrade.php on line 200
PHP Deprecated:  Array and string offset access syntax with curly braces is deprecated in /home/nginx/domains/analytics.domain.com/public/libs/upgradephp/upgrade.php on line 202
ERROR [2019-12-02 22:05:02] 26165  Empty or invalid response 'PHP Deprecated:  Array and string offset access syntax with curly braces is deprecated in /home/nginx/domains/analytics.domain.com/public/libs/upgradephp/upgrade.php on line 180 PHP Deprecated:  Array and string offset access syntax with curly braces is deprecated in /home/nginx/domains/analytics.domain.com/public/libs/upgradephp/upgrade.php on line 194 PHP Deprecated:  Array and string offset access syntax with curly braces is deprecated in /home/nginx/domains/analytics.domain.com/public/libs/upgradephp/upgrade.php on line 194 PHP Deprecated:  Array and string offset access syntax with curly braces is deprecated in /home/nginx/domains/analytics.domain.com/public/libs/upgradephp/upgrade.php on line 200 PHP Deprecated:  Array and string offset access syntax with curly braces is deprecated in /home/nginx/domains/analytics.domain.com/public/libs/upgradephp/upgrade.php on line 202 a:3:{s:10:"2019-11-30";a:56:{s:16:"n
@Findus23 commented on December 2nd 2019 Member

This one has been fixed in https://github.com/matomo-org/matomo/pull/15204

Lukas

Am 02.12.2019 um 23:34 schrieb Mike van Eckendonk <notifications@github.com>:


PHP Deprecated: Array and string offset access syntax with curly braces is deprecated in /home/nginx/domains/analytics.domain.com/public/libs/upgradephp/upgrade.php on line 180
PHP Deprecated: Array and string offset access syntax with curly braces is deprecated in /home/nginx/domains/analytics.domain.com/public/libs/upgradephp/upgrade.php on line 194
PHP Deprecated: Array and string offset access syntax with curly braces is deprecated in /home/nginx/domains/analytics.domain.com/public/libs/upgradephp/upgrade.php on line 194
PHP Deprecated: Array and string offset access syntax with curly braces is deprecated in /home/nginx/domains/analytics.domain.com/public/libs/upgradephp/upgrade.php on line 200
PHP Deprecated: Array and string offset access syntax with curly braces is deprecated in /home/nginx/domains/analytics.domain.com/public/libs/upgradephp/upgrade.php on line 202
ERROR [2019-12-02 22:05:02] 26165 Empty or invalid response 'PHP Deprecated: Array and string offset access syntax with curly braces is deprecated in /home/nginx/domains/analytics.domain.com/public/libs/upgradephp/upgrade.php on line 180 PHP Deprecated: Array and string offset access syntax with curly braces is deprecated in /home/nginx/domains/analytics.domain.com/public/libs/upgradephp/upgrade.php on line 194 PHP Deprecated: Array and string offset access syntax with curly braces is deprecated in /home/nginx/domains/analytics.domain.com/public/libs/upgradephp/upgrade.php on line 194 PHP Deprecated: Array and string offset access syntax with curly braces is deprecated in /home/nginx/domains/analytics.domain.com/public/libs/upgradephp/upgrade.php on line 200 PHP Deprecated: Array and string offset access syntax with curly braces is deprecated in /home/nginx/domains/analytics.domain.com/public/libs/upgradephp/upgrade.php on line 202 a:3:{s:10:"2019-11-30";a:56:{s:16:"n

You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or unsubscribe.

@mattab commented on December 4th 2019 Member

FYI our host has PHP 7.4 support now https://twitter.com/alwaysdata/status/1201425777667059712

@MacFan4000 commented on December 13th 2019
PHP Deprecated:  Array and string offset access syntax with curly braces is deprecated in /home/nginx/domains/analytics.domain.com/public/libs/upgradephp/upgrade.php on line 180
PHP Deprecated:  Array and string offset access syntax with curly braces is deprecated in /home/nginx/domains/analytics.domain.com/public/libs/upgradephp/upgrade.php on line 194
PHP Deprecated:  Array and string offset access syntax with curly braces is deprecated in /home/nginx/domains/analytics.domain.com/public/libs/upgradephp/upgrade.php on line 194
PHP Deprecated:  Array and string offset access syntax with curly braces is deprecated in /home/nginx/domains/analytics.domain.com/public/libs/upgradephp/upgrade.php on line 200
PHP Deprecated:  Array and string offset access syntax with curly braces is deprecated in /home/nginx/domains/analytics.domain.com/public/libs/upgradephp/upgrade.php on line 202
ERROR [2019-12-02 22:05:02] 26165  Empty or invalid response 'PHP Deprecated:  Array and string offset access syntax with curly braces is deprecated in /home/nginx/domains/analytics.domain.com/public/libs/upgradephp/upgrade.php on line 180 PHP Deprecated:  Array and string offset access syntax with curly braces is deprecated in /home/nginx/domains/analytics.domain.com/public/libs/upgradephp/upgrade.php on line 194 PHP Deprecated:  Array and string offset access syntax with curly braces is deprecated in /home/nginx/domains/analytics.domain.com/public/libs/upgradephp/upgrade.php on line 194 PHP Deprecated:  Array and string offset access syntax with curly braces is deprecated in /home/nginx/domains/analytics.domain.com/public/libs/upgradephp/upgrade.php on line 200 PHP Deprecated:  Array and string offset access syntax with curly braces is deprecated in /home/nginx/domains/analytics.domain.com/public/libs/upgradephp/upgrade.php on line 202 a:3:{s:10:"2019-11-30";a:56:{s:16:"n

that same error seems to occur in the console script as well

@Findus23 commented on December 13th 2019 Member

@MacFan4000 That's another bug and has been fixed in https://github.com/matomo-org/matomo/pull/15204

@Eckybrazzz commented on December 14th 2019

So, we can finally use Matomo with 7.4.0?? Getting issues with the cron, everything. And it's not only Matamo, but there are so many issues with 7.4.0, I have to change my billing software, many other things. pff.

Everything needs time to get mature.

@Findus23 commented on December 14th 2019 Member

@Eckybrazzz As every release PHP 7.4 added new warnings for deprecated features and if your software depends on code that uses these ancient features (like e.g. TCPDF in case of Matomo) you will see these kind of warnings. I tested most Matomo features before the release, but obviously can't catch everything. And as no one reported any issues during the PHP 7.4 beta phase, these remaining things can only be fixed now.

So yes, you can use Matomo with 7.4!! But you will have to either apply the few patches like https://github.com/matomo-org/matomo/pull/15204 yourself or have to wait until 3.13.1 comes out with them.

This Issue was closed on December 11th 2019
Powered by GitHub Issue Mirror