Support

Akeeba Backup for Joomla!

#39673 Cron Service Error 255

Posted in ‘Akeeba Backup for Joomla! 4 & 5’
This is a public ticket

Everybody will be able to see its contents. Do not include usernames, passwords or any other sensitive information.

Environment Information

Joomla! version
Joomla 5.0.0
PHP version
8.2.10
Akeeba Backup version
8.9.1

Latest post by nicholas on Thursday, 26 October 2023 06:00 CDT

deltapapa

Hi,
I make every night 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 { …}
}
}

 

Is this a issue from Astroid Framework / Template? I wrote a issue here too: Error after Cron - Backup · Issue #416 · templaza/astroid-framework (github.com)

 

Thank you very much and have a good weekend :-)

nicholas
Akeeba Staff
Manager

Yes, this is a problem from the Astroid framework. They can fix it very easily by updating their code to no longer use legacy class names. Please point them to https://www.dionysopoulos.me/book/plg-extension.html, https://github.com/nikosdion/joomlatypehints, and joomla_com_upgrader. This is documentation and tools I wrote to ease this transition with our own software (and part of the reason why we were able to be Joomla! 4 native two years ago exactly when Joomla! 4 launched).

As a temporary solution you can enable the “Behaviour - Backward Compatibility” plugin. This plugin adds support for the deprecated class names which will become obsolete in Joomla! 6.0 — this is something that was previously taking place in Joomla without a plugin.

Nicholas K. Dionysopoulos

Lead Developer and Director

🇬🇷Greek: native 🇬🇧English: excellent 🇫🇷French: basic • 🕐 My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

deltapapa

Hello Nicholas,
thank you very much for the quick reply.
The plugin is turned on, otherwise Astroid Framework would not work at all. Well, I have written to the developer, he wants to reprogram the template framework native promptly.
What surprised me a bit, that for example about the task planner in Joomla and the planners work externally in Backup Monkey without problems.

 

WBR,

deltapapa

nicholas
Akeeba Staff
Manager

So, this is one part problem with the third party plugin not being fully updated, and one part a Joomla! 5 major bug. Joomla! 5 under the CLI application (and only the CLI application) loads the system plugins before it loads the “Behaviour - Backward Compatibility” plugin. As a result, the Astrid framework's system plugin breaks.

I was able to reproduce this issue by creating an empty plugin consisting of just:

<?php
class plgSystemSabotage extends JPlugin {}

and its corresponding XML manifest file. I installed and enabled this pluign. The frontend, backend, and API application work great. The CLI application breaks with the same error you got about the JPlugin class not being found. If I disable Joomla's backwards compatibility plugin everything breaks, as expected. If I disable my sabotage plugin everything works, as expected.

This also explains why using the JSON API works. The JSON API run either in the frontend of the site, or through the API application (depending on whether you're using APIv2 or APIv3; I believe BackupMonkey is still using APIv2). Since the Joomla! bug does not exist in either ots frontend or the API application everything works.

All I can say is wait until Joomla! fixes this major bug.

Nicholas K. Dionysopoulos

Lead Developer and Director

🇬🇷Greek: native 🇬🇧English: excellent 🇫🇷French: basic • 🕐 My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

deltapapa

Hello Nicholas ,
quite excellent and many thanks for the always fast and very detailed description and help.
Is it okay for you if I open an issue about it, and link this thread here?

With best regards,
deltapapa

nicholas
Akeeba Staff
Manager

It's been already reported to the Joomla! project and there is already a Pull Request to fix it: https://github.com/joomla/joomla-cms/pull/42217

You can help by testing the PR. I did so too, reporting my result to the release lead via a different channel. The more people testing the change and reporting a success the faster it will become part of Joomla! itself. If you can test it, please do!

Nicholas K. Dionysopoulos

Lead Developer and Director

🇬🇷Greek: native 🇬🇧English: excellent 🇫🇷French: basic • 🕐 My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

deltapapa

Hi,

thank you very much, i install the patch via patchtester, and now it works fine :-)

I don't know where i have to report it, because the PR is closed.

Anyway, thank you very much :-)

nicholas
Akeeba Staff
Manager

Go to https://issues.joomla.org/tracker/joomla-cms/42217 and log into it using GitHub (top right, there's a Login with GitHub button). Then click on the blue Test This button, about two lines below the PR's header. Select "Tested successfully". You can type more info if you want, but it's optional. Then click on the blue Submit test result button. This magically counts the test result into the tally used by the automations Joomla! has set up on GitHub and will, therefore, mark the PR as a candidate for RTC (Ready To Commit). A human maintainer will go through it to make sure the reviews are legit and then they'll merge it. Which is great, because that's just in time to make it into Joomla! 5.0.1 :)

Nicholas K. Dionysopoulos

Lead Developer and Director

🇬🇷Greek: native 🇬🇧English: excellent 🇫🇷French: basic • 🕐 My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

deltapapa

Yeah, thank you very much, i reported my test, first i look direct in github and can't find the test - button :-)

 

WBR,

deltapapa

nicholas
Akeeba Staff
Manager

Awesome! Thank you very much for helping with this. I appreciate it a lot :)

Nicholas K. Dionysopoulos

Lead Developer and Director

🇬🇷Greek: native 🇬🇧English: excellent 🇫🇷French: basic • 🕐 My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

Support Information

Working hours: We are open Monday to Friday, 9am to 7pm Cyprus timezone (EET / EEST). Support is provided by the same developers writing the software, all of which live in Europe. You can still file tickets outside of our working hours, but we cannot respond to them until we're back at the office.

Support policy: We would like to kindly inform you that when using our support you have already agreed to the Support Policy which is part of our Terms of Service. Thank you for your understanding and for helping us help you!