Information Required ?
avatar jschmi102
jschmi102
5 Jul 2021

Steps to reproduce the issue

call to jooma 3.10 alpha 8 pre-checker may throw warning:
Warning: Creating default object from empty value in C:\myjoomla3\administrator\components\com_joomlaupdate\models\default.php on line 1470

to fix this e.g. add check for object property at line 1470:

if (isset($decode->description))
	   $decode->description = '';
avatar jschmi102 jschmi102 - open - 5 Jul 2021
avatar joomla-cms-bot joomla-cms-bot - change - 5 Jul 2021
Labels Added: ?
avatar joomla-cms-bot joomla-cms-bot - labeled - 5 Jul 2021
avatar ReLater
ReLater - comment - 5 Jul 2021

For me the message looks like that the object $decode isn't created correctly, not only this and all other properties. Or do I miss something?

Can you check in your database table if all extensions with package_id=0 have something in field manifest_cache?

Can you add a debug code in line
https://github.com/joomla/joomla-cms/blob/3.10-dev/administrator/components/com_joomlaupdate/models/default.php#L1468

if (!is_object($decode))
{
 echo $extension->name . '|' . $extension->extension_id;
exit;
}
avatar jschmi102
jschmi102 - comment - 5 Jul 2021

hi,
had to remove $extension->id from debug code but got "de-DEJEvents|" for $extension->name

Notice: Undefined property: stdClass::$id in C:\myjoomla3\administrator\components\com_joomlaupdate\models\default.php on line 1472
de-DEJEvents|

Founds 1 entry in database showing (surprise!) "de-DEJEvents|" (element "pkg_de-DEJEvents")

avatar jschmi102
jschmi102 - comment - 5 Jul 2021

hi,
deleted this (orphan) entry from database - this fixed the php-warning (same as my fix-code did)

avatar ReLater
ReLater - comment - 5 Jul 2021

I would say: Not a core issue when an 3rd extension has no ID and manifest_cache in db table.
EDIT: Nonsense. My debug code was wrong. Not $extension->id but $extension->extension_id is correct.

Maybe one could think about a Joomla warning if orphaned extensions are found in pre-checker but how friendly must Joomla be there.

To close or not to close?

avatar ReLater
ReLater - comment - 5 Jul 2021

I corrected my code in #34710 (comment)

avatar jschmi102
jschmi102 - comment - 6 Jul 2021

hi,
the question is should bad input (here caused by orphan extension) be handled by code (e.g. throw error message) or may one live with a php-warning (which can be understod and solved) - both OK for me - so I close this issue.

avatar ReLater
ReLater - comment - 6 Jul 2021

That has to decide somebody else. TBH I don't know what happens after this line
https://github.com/joomla/joomla-cms/blob/3.10-dev/administrator/components/com_joomlaupdate/models/default.php#L1477
where a NULL is passed over as $extension->manifest_cache.

Maybe @zero-24 knows that?

avatar zero-24
zero-24 - comment - 17 Jul 2021

Hi @ReLater @jschmi102 this issue should have been patched now by #34774 please check and than close here Thanks.

avatar Quy Quy - change - 17 Jul 2021
Labels Added: Information Required
avatar Quy Quy - labeled - 17 Jul 2021
avatar wilsonge wilsonge - change - 25 Jul 2021
Status New Closed
Closed_Date 0000-00-00 00:00:00 2021-07-25 22:28:23
Closed_By wilsonge
avatar wilsonge wilsonge - close - 25 Jul 2021
avatar wilsonge
wilsonge - comment - 25 Jul 2021

Haven't heard anything in regards to this. Closing this - if it's still in the next RC due on Tuesday (27 August) then we can reopen

Add a Comment

Login with GitHub to post a comment