templaza / astroid-framework

Powerful framework for designers and developers to create responsive, fast & robust Joomla based websites and templates.
https://astroidframe.work/
GNU General Public License v3.0
77 stars 12 forks source link

Error after Cron - Backup #416

Open deltapapa01 opened 8 months ago

deltapapa01 commented 8 months ago

Hi, I make every after via cronjob a backup of my Joomla site with Akeeba Backup. After the conversion to Joomla 5 and Astroid V3.0.2 ran today after the backup but not through, and generated the following error:

`Symfony\Component\ErrorHandler\Error\ClassNotFoundError {#569

message: """

Attempted to load class "JPlugin" from the global namespace.\n
Did you forget a "use" statement?
"""

code: 0

file: "/html/petersen-webdesign/plugins/system/astroid/astroid.php"

line: 25

trace: { /html/petersen-webdesign/plugins/system/astroid/astroid.php:25 { require_once › */ › class plgSystemAstroid extends JPlugin › { } /html/petersen-webdesign/libraries/src/Extension/ExtensionManagerTrait.php:217 { …} /html/petersen-webdesign/libraries/src/Extension/ExtensionManagerTrait.php:160 { …} /html/petersen-webdesign/libraries/src/Extension/ExtensionManagerTrait.php:99 { …} /html/petersen-webdesign/libraries/src/Plugin/PluginHelper.php:232 { …} /html/petersen-webdesign/libraries/src/Plugin/PluginHelper.php:192 { …} /html/petersen-webdesign/libraries/src/Application/ConsoleApplication.php:255 { …} /html/petersen-webdesign/cli/joomla.php:77 { …} } }`

Can anyone do anything with it? For me it reads somehow that this generates the error in line 25: plugins/system/astroid/astroid.php

Otherwise, I'll go to the Akeeba Backup Forum and ask there.

My Server tools:

ImageMagick 7.1.1 mit HEIC und AVIF Support PHP 8.2-latest FPM (8.2.10) (P+) Aspell 0.60.6 cURL 8.4.0 MySQL-Client 8.0.34 Unrar 6-latest (6.11) Zip 3.0-latest (3.0-12)

WBR, deltapapa

deltapapa01 commented 8 months ago

Hi, i get an answer from akeeba backup (Nicholas K. Dionysopoulos):

https://www.akeeba.com/support/akeeba-backup/39673-cron-service-error-255.html#p215754

The problem is that astroid is using legacy class names (i.t.c JPlugin), what an error makes when i make CLI Backups. Did you have a roadmap, to make astroid native J5 without the use from Behaviour - Backward Compatibility Plugin?

sonvnn commented 8 months ago

Thank you! I will check and update asap.

deltapapa01 commented 8 months ago

Hi, good news: It's a Joomla Bug, the PR is here: https://github.com/joomla/joomla-cms/pull/42217 What exactly happend, is here: https://www.akeeba.com/support/akeeba-backup/39673-cron-service-error-255.html

But best thing is also in view of Joomla 6, to make Astroid a native Joomla 5 extension without the using of B/C Plugin :-)

Thank you very much and with best regards, deltapapa

sonvnn commented 8 months ago

Thank you! I am working to migrate all function to Joomla 5 and Joomla 6.

sonvnn commented 8 months ago

@deltapapa01 I am working to migrate all function to Joomla 6. Please help me download v3 and test on your site https://github.com/templaza/astroid-framework/archive/refs/heads/v3.zip

You can disable Backward Compatible Plugin and test on your site. Please tell me if you find any issue with Joomla 5 and Joomla 6.

Best Regards, Sonny

deltapapa01 commented 8 months ago

Hi Sonny, I have installed the new version on a Joomla 5.0.1DEV Nightly Build. With or without b/c plugin I have the following error in FE:

`Exception Type: Error File: /html/cms/libraries/astroid/framework/library/astroid/Helper/Font.php Line: 280 Message: Class "Astroid\Helper\Uri" not found

0 /html/cms/libraries/astroid/framework/library/astroid/Helper/Font.php(228): Astroid\Helper\Font::loadLocalFont('...')

1 /html/cms/libraries/astroid/framework/library/astroid/Helper/Style.php(298): Astroid\Helper\Font::getFontFamily('...')

2 /html/cms/libraries/astroid/framework/library/astroid/Helper/Style.php(286): Astroid\Helper\Style::getFontFamilyValue('...', '...')

3 /html/cms/libraries/astroid/framework/library/astroid/Component/Utility.php(201): Astroid\Helper\Style::renderTypography('...', Object(stdClass), Object(stdClass))

4 /html/cms/libraries/astroid/framework/library/astroid/Site.php(25): Astroid\Component\Utility::typography()

5 /html/cms/plugins/system/astroid/astroid.php(67): Astroid\Site->onAfterRender()

6 /html/cms/libraries/src/Plugin/CMSPlugin.php(289): plgSystemAstroid->onAfterRender(Object(Joomla\CMS\Application\SiteApplication))

7 /html/cms/libraries/vendor/joomla/event/src/Dispatcher.php(454): Joomla\CMS\Plugin\CMSPlugin->Joomla\CMS\Plugin{closure}(Object(Joomla\CMS\Event\Application\AfterRenderEvent))

8 /html/cms/libraries/vendor/joomla/application/src/AbstractApplication.php(99): Joomla\Event\Dispatcher->dispatch('...', Object(Joomla\CMS\Event\Application\AfterRenderEvent))

9 /html/cms/libraries/src/Application/CMSApplication.php(1079): Joomla\Application\AbstractApplication->dispatchEvent('...', Object(Joomla\CMS\Event\Application\AfterRenderEvent))

10 /html/cms/libraries/src/Application/SiteApplication.php(732): Joomla\CMS\Application\CMSApplication->render()

11 /html/cms/libraries/src/Application/CMSApplication.php(311): Joomla\CMS\Application\SiteApplication->render()

12 /html/cms/includes/app.php(58): Joomla\CMS\Application\CMSApplication->execute()

13 /html/cms/index.php(32): require_once('...')

14 {main}

` Good news: The backend works without b/c plugin.

WBR

deltapapa01 commented 8 months ago

Hi @sonvnn, ich test the V3 branch from tody, now it looks very good. In Joomla Backend is still Astroid 3.0.2, i think you have to modify the template.xml

I will more testing and come back here,

THANK YOU VERY MUCH :-)