JoomGalleryfriends / JG4-dev

Development repository for JoomGallery v4.x
GNU General Public License v3.0
10 stars 6 forks source link

Attempt to assign property "jg_staticprocessing" on bool #146

Closed TobiMidi closed 8 months ago

TobiMidi commented 11 months ago

Hello,

i install the component. I go to the Components, select the Control-center? (in German Kontrollzentrum) Systeminformation Joomla: Joomla! 4.3.4 Stable [ Bora ] 22-August-2023 16:00 GMT PHP: 8.1.22 MySQL: 5.7.38-log OR 8.0.32 Database-Typ: mysql

Error: Attempt to assign property "jg_staticprocessing" on bool Call stack

| Function | Location

1 | () | JROOT/administrator/components/com_joomgallery/src/Model/ConfigModel.php:177 2 | Joomgallery\Component\Joomgallery\Administrator\Model\ConfigModel->getItem() | JROOT/administrator/components/com_joomgallery/src/Service/Config/Config.php:205 3 | Joomgallery\Component\Joomgallery\Administrator\Service\Config\Config->getParamsByID() | JROOT/administrator/components/com_joomgallery/src/Service/Config/DefaultConfig.php:53 4 | Joomgallery\Component\Joomgallery\Administrator\Service\Config\DefaultConfig->__construct() | JROOT/administrator/components/com_joomgallery/src/Service/Config/ConfigServiceTrait.php:65 5 | Joomgallery\Component\Joomgallery\Administrator\Extension\JoomgalleryComponent->createConfig() | JROOT/administrator/components/com_joomgallery/src/Helper/JoomHelper.php:101 6 | Joomgallery\Component\Joomgallery\Administrator\Helper\JoomHelper::getService() | JROOT/administrator/components/com_joomgallery/src/View/Control/HtmlView.php:54 7 | Joomgallery\Component\Joomgallery\Administrator\View\Control\HtmlView->display() | JROOT/libraries/src/MVC/Controller/BaseController.php:645 8 | Joomla\CMS\MVC\Controller\BaseController->display() | JROOT/administrator/components/com_joomgallery/src/Controller/DisplayController.php:118 9 | Joomgallery\Component\Joomgallery\Administrator\Controller\DisplayController->display() | JROOT/libraries/src/MVC/Controller/BaseController.php:678 10 | Joomla\CMS\MVC\Controller\BaseController->execute() | JROOT/libraries/src/Dispatcher/ComponentDispatcher.php:143 11 | Joomla\CMS\Dispatcher\ComponentDispatcher->dispatch() | JROOT/libraries/src/Component/ComponentHelper.php:361 12 | Joomla\CMS\Component\ComponentHelper::renderComponent() | JROOT/libraries/src/Application/AdministratorApplication.php:143 13 | Joomla\CMS\Application\AdministratorApplication->dispatch() | JROOT/libraries/src/Application/AdministratorApplication.php:186 14 | Joomla\CMS\Application\AdministratorApplication->doExecute() | JROOT/libraries/src/Application/CMSApplication.php:293 15 | Joomla\CMS\Application\CMSApplication->execute() | JROOT/administrator/includes/app.php:61 16 | require_once() | JROOT/administrator/index.php:32

MrMusic commented 11 months ago

Thank you for testing. I had this same error when I tested with Joomla 5 beta1. This error has not yet occurred with Joomla 4.3.4. Can you check whether the root entries (id=1) are present in the database in the table #__joomgallery_categories and #__joomgallery_configs?

TobiMidi commented 11 months ago

Hello, Unfortunately, I have already uninstalled Joomgallery.

Now I have reinstalled the component, now the site works and I have no error message.

I have now uninstalled the component again. I deleted all joomgallery tables in the database.

New test:

  1. Install German language pack
  2. Install component

-> ERROR JInstaller: :Install: The XML installation file could not be found.

Error when reading the xml file. info Plugin with name joomgalleryimages was installed successfully. Plugin with name joomgallery was installed successfully. Plugin with name joomgallerycategories was installed successfully. success The component installation has been completed.

Deprecated: json_decode(): Passing null to parameter #1 ($json) of type string is deprecated in /mnt/web403/e0/98/59518598/htdocs/website-j4/libraries/src/Installer/InstallerScript.php on line 304


Now I have the original error message again " Attempt to assign property "jg_staticprocessing" on bool "

--

Your question: Can you check whether the root entries (id=1) are present in the database in the table #__joomgallery_categories and #__joomgallery_configs?

Answer: Every #__joomgallery entry is empty!

__joomgallery_categories -> Empty!

__joomgallery_configs -> Empty!


Joomla backend Then I go to the Configuration Manager -> No entry. -> Add entry -> ERROR: "Attempt to assign property "jg_staticprocessing" on bool "


I have now installed and uninstalled the component and the language file several times.

Whenever I install the language file first and the component second, the error message comes up and often a big MySQL conflict.

If I install the component first, the language file second, it works.

Maybe I can narrow down the search for you now.

Best regards

MrMusic commented 11 months ago

I have now installed and uninstalled the component and the language file several times.

Whenever I install the language file first and the component second, the error message comes up and often a big MySQL conflict.

If I install the component first, the language file second, it works.

Confirmed. Obviously, sometimes the 'update' method is executed even though the component was not installed. jg4-install-error

Elfangor93 commented 11 months ago

I guess the update methdod is called, if the extension beeing installed already exists in the #__extensions table in the db. This could happen if the uninstallation was not successful. If you are once there you should manually uninstall the extension and restart testing to find out what the first issue was.

I know debugging the install/update/deinstall process is tedious...

Elfangor93 commented 8 months ago

This issue has its root in a messed up Joomla installation resulting from testing code with errors. Setting up a new, fresh Joomla installation solves the problem. Since this is not an issue of its own, but comes from executing code with previous issues, I will close this.