yiisoft / yii2-debug

Debug Extension for Yii 2
http://www.yiiframework.com
BSD 3-Clause "New" or "Revised" License
201 stars 149 forks source link

Remove unnecessary opis\closure wrapper for PHP 8.1 compatibility. It… #472

Closed sartor closed 2 years ago

sartor commented 2 years ago
Q A
Is bugfix? ✔️
New feature?
Breaks BC? Probably not
Fixed issues https://github.com/yiisoft/yii2-debug/pull/466

Dependency https://github.com/opis/closure was removed, because there is no cases where it was used since commit https://github.com/yiisoft/yii2-debug/commit/08feaca36d8081da9850bf5629781580f4b43f48?diff=split Closures are still able to log and dump. Test added to prove. Now it can be used with PHP 8.1

longthanhtran commented 2 years ago

Great to see one more dependency dropped, and the debug toolbar apprears again on yii2 2.0.45.

image

However, there are deprecate notices about

image

In particular, cases of deprecated notices / alerts are.

samdark commented 2 years ago

@sartor everything @longthanhtran mentioned is done, right?

sartor commented 2 years ago

Yes, but I can't properly check it.

longthanhtran commented 2 years ago

Can you please check src/views/default.php lines 68 and 113 also?

image

sartor commented 2 years ago

Can you please check src/views/default.php lines 68 and 113 also? Already fixed it: https://github.com/yiisoft/yii2-debug/pull/472/files#diff-4a27f20b45dee8998b5de1353ab655fc0b5ff60eaaa3b0c96623c2c62b866640

longthanhtran commented 2 years ago

Yes, it should be fixed, my bad for overlooking on this. The file should be src/views/default/view.php instead and your PR included those lines already.

Just a very little part, src/models/search/Base.php which I think still need on line 33 and 37 to fulfill mb_strpos function call.

image

mishamosher commented 2 years ago

I've experienced issues with some of the panels, specifically, with this change.

Here are my extra changes related to it: https://github.com/mishamosher/yii2-debug/pull/2

If they can be included in this PR, it would be awesome!

sartor commented 2 years ago

Just a very little part, src/models/search/Base.php which I think still need on line 33 and 37 to fulfill mb_strpos function call.

Type is already casted on line 31 and safe to use in any place here.

I found one more deprecation. Now looks like this pull request can be merged.

samdark commented 2 years ago

Thanks!

rumours86 commented 2 years ago

@samdark forgot to release?