database icon indicating copy to clipboard operation
database copied to clipboard

2.3.6: Argument 1 passed to Nette\Utils\ObjectMixin::getSuggestion() must be of the type array, null given

Open zraly opened this issue 10 years ago • 5 comments

Trying new 2.3.6 release with updated nette/utils to 2.3.5 and got this error.

Maybe it is somehow related to an error I had with previous version of database: Cannot read an undeclared column 'created_at'. Clear the cache helped, but just for some time, then error occured again.

snimek obrazovky 2015-09-15 v 11 37 58

zraly avatar Sep 15 '15 09:09 zraly

array_keys() can return NULL? Wow.

EDIT: in can

milo avatar Sep 15 '15 09:09 milo

Can when argument is not array (null, string, integer...), but it also throw warning.

nechutny avatar Sep 15 '15 11:09 nechutny

After so many years, PHP never stops surprise me.

milo avatar Sep 15 '15 12:09 milo

Can you try to find where the bad data comes from? Like this way https://github.com/dg/nette-database/commit/9130cfe24727a6b0d403e51d9762f7c98d4fee56

dg avatar Sep 15 '15 17:09 dg

Unfortunately I am not able to reproduce the error as I need, because it is probably caused by the "nette/database caching error" mentioned before. If the error occurs again, I'll try to get data you need.

zraly avatar Sep 16 '15 10:09 zraly