RTC Language Change Release Blocker PR-5.4-dev Pending

User tests: Successful: Unsuccessful:

avatar richard67
richard67
17 May 2025

Pull Request for Issue # .

Summary of Changes

This pull request (PR) adds 2 new checks to the "Required Settings" checks of the pre-update checker which are shown when an update to the next major version (here 6) is found:

  1. Check if the backward compatibility plugin of the current major version (here 5) is disabled.
  2. Check if the backward compatibility plugin of the next major version (here 6) is enabled.

If one of these checks fails, you cannot update to the next major version with Live Update.

You can bypass these tests by using the "Upload & Update" button, but that's already the case with other required settings checks and should be fixed with another PR, if ever.

In addition, this PR adds the same checks to the CLI's core::update command.

The first check has been agreed by the CMS Maintenance Team.

The plugin has to be disabled before the update so the user can see if the site crashes due to a 3rd party extension like e.g. a system plugin which requires the plugin so it very likely will not work anymore on Joomla 6.

If that happens, the user can enable it again in the database and the site is operable again, e.g. fopr updating or uninstalling that extension.

If we would not do that, the site would break during the update when files are already unpacked but the database has not been updated yet, and that would be fixed not that easy.

The second check is for the case that the admin has disabled the J6 b/c plugin, what one should not do, but we can't really prevent it.

Testing Instructions

Test 1: Update to 6.0 nightly build

  1. On a current 5.4-dev branch or latest 5.4 nightly build without the changed from this PR applied, make sure that automated updates are switched off and the "Behaviour - Backward Compatibility" plugin is enabled.

  2. In the options of the Joomla Update Component, set the update channel to "Custom URL" and enter the custom update URL of the 6.0 nightly builds: https://update.joomla.org/core/nightlies/next_major_list.xml

  3. Check for updates.
    Result: See section "Actual result BEFORE applying this Pull Request" below.

  4. In a command line in your Joomla root folder, run php ./cli/joomla.php core:update.
    Result: See section "Actual result BEFORE applying this Pull Request" below.

  5. Restore the starting conditions described in steps 1 and 2.

  6. Apply the changes from this PR.

  7. Check again for updates.
    Result: There are 2 new checks in the "Required Settings" section of the pre-update check.
    The first check for the J5 plugin has failed, and a notice is shown with a link to the plugin manager, telling to disable the plugin, and you can not update to Joomla 6 with Live Update.
    See first image "1. Both plugins enabled" in section "Expected result AFTER applying this Pull Request" below.

  8. In a command line in your Joomla root folder, run php ./cli/joomla.php core:update.
    Result: There is a new step for checking the pre-conditions for a major update after the dcheck of the database table structure.
    It shows an error message telling that the 'Behavior - Backward Compatibility' plugin is enabled and a message that the pre-conditions for a major upgrade are not fulfilled.
    See second image "1. Both plugins enabled" in section "Expected result AFTER applying this Pull Request" below.

  9. Disable the "Behaviour - Backward Compatibility 6" plugin.

  10. Check again for updates.
    Result: Both checks have failed, and for each of the 2 plugins a notice is shown with a link to the plugin manager, telling what to do with the particular plugin, and you can not update to Joomla 6 with Live Update.
    See first image "2. Joomla 5 plugin enabled and Joomla 6 plugin disabled" in section "Expected result AFTER applying this Pull Request" below.

  11. In a command line in your Joomla root folder, run php ./cli/joomla.php core:update.
    Result: The new check shows for each of the 2 plugins an error message with the plugin's translated name and its actual status, and finally a message that the pre-conditions for a major upgrade are not fulfilled.
    See second image "2. Joomla 5 plugin enabled and Joomla 6 plugin disabled" in section "Expected result AFTER applying this Pull Request" below.

  12. Disable the "Behaviour - Backward Compatibility" plugin.

  13. Check again for updates.
    Result: The second check for the J6 plugin has failed, and a notice is shown with a link to the plugin manager, telling to enable the plugin, and you can not update to Joomla 6 with Live Update.
    See first image "3. Both plugins disabled" in section "Expected result AFTER applying this Pull Request" below.

  14. In a command line in your Joomla root folder, run php ./cli/joomla.php core:update.
    Result: The new check shows an error message telling that the 'Behavior - Backward Compatibility 6' plugin is disabled and a message that the pre-conditions for a major upgrade are not fulfilled.
    See second image "3. Both plugins disabled" in section "Expected result AFTER applying this Pull Request" below.

  15. Enable the "Behaviour - Backward Compatibility 6" plugin.

  16. Check again for updates.
    Result: Both new checks have succeeded, and you could update to Joomla 6.
    See first image "4. Joomla 5 plugin disabled and Joomla 6 plugin enabled" in section "Expected result AFTER applying this Pull Request" below.

  17. In a command line in your Joomla root folder, run php ./cli/joomla.php core:update.
    Result: The update is executed.
    See second image "4. Joomla 5 plugin disabled and Joomla 6 plugin enabled" in section "Expected result AFTER applying this Pull Request" below.

Test 2: Update to 5.4 nightly build

  1. On a current 5.4-dev branch or latest 5.4 nightly build, make sure that automated updates are switched off.

  2. Apply the changes from this PR.

  3. Edit file libraries/src/Version.php and change line 50 from public const MINOR_VERSION = 4; to public const MINOR_VERSION = 3;.
    This will fake the current version to be 5.3 so that an update to a 5.4 nightly can be found.

  4. Go to "Extensions - Manage - Database", select the CMS record and use the "Update Structure" button.
    This will apply the faked version from step 3 in the database.

  5. In the options of the Joomla Update Component, set the update channel to "Custom URL" and enter the custom update URL of the 5.4 nightly builds: https://update.joomla.org/core/nightlies/next_minor_list.xml

  6. Check for updates.
    Result: The new checks are not shown in the pre-update check as it is not a major upgrade.
    See Test 2 in section "Expected result AFTER applying this Pull Request" below.

  7. In a command line in your Joomla root folder, run php ./cli/joomla.php core:update.
    Result: There is no check of the pre-conditions for a major upgrade performed. The update is executed.
    See Test 2 in section "Expected result AFTER applying this Pull Request" below.

Actual result BEFORE applying this Pull Request

There is no check about backward compatibility plugins in the "Required Settings" checks of the pre-update checker, and you could update to J6.
pre-update-check-6_without-pr

When running the CLI core update command, the update is executed.
pre-update-check-6_without-pr_cli
There is not check for the prerequisites to upgrade to a new major version.

Expected result AFTER applying this Pull Request

Test 1: Update to 6.0 nightly build

When an update to a new major version has been found, there are 2 new checks shown in the "Required Settings" section of the pre-update check:

  • The Joomla 5 Backward Compatibility plugin is disabled
  • The Joomla 6 Backward Compatibility plugin is enabled

When one of these checks of both have failed, you can't update with Live Update.

If both checks succeed, the button to perform the update is shown, so you could perform the update.

In the core:update command of the CLI there is a new step for checking the pre-conditions of a major upgrade when an update to a new major version was found.

The 2 new checks mentioned above are performed with that new step. If any of the test fails, an error message is shown with the (translated) plugin name, a final message tells that the conditions are not fulfilled, and the update is not performed.

If both checks succeed, the update is performed by the CLI.

If the update which was found is not an upgrade to a new major version, the 2 nex checks are not shown in the pre-update check, and in the CLI the new step for checking the pre-conditions of a major upgrade is not executed.

1. Both plugins enabled

pre-update-check-6_with-pr

pre-update-check-6_with-pr_cli

2. Joomla 5 plugin enabled and Joomla 6 plugin disabled

pre-update-check-6_with-pr_4

pre-update-check-6_with-pr_4_cli

3. Both plugins disabled

pre-update-check-6_with-pr_3

pre-update-check-6_with-pr_3_cli

4. Joomla 5 plugin disabled and Joomla 6 plugin enabled

pre-update-check-6_with-pr_2

pre-update-check-6_with-pr_2_cli

Test 2: Update to 5.4 nightly build

When an update has been found which is not an upgrade to a new major version, the new checks are not shown in the pre-update check, and in the CLI update the new step for checking the pre-requisites is not executed, i.e. everything works the same as without this PR.

Link to documentations

Please select:

  • Documentation link for docs.joomla.org:

  • No documentation changes for docs.joomla.org needed

  • Pull Request link for manual.joomla.org:

  • No documentation changes for manual.joomla.org needed

avatar richard67 richard67 - open - 17 May 2025
avatar richard67 richard67 - change - 17 May 2025
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 17 May 2025
Category Administration com_joomlaupdate Language & Strings
avatar richard67 richard67 - change - 17 May 2025
Labels Added: Language Change Release Blocker PR-5.4-dev
avatar brianteeman
brianteeman - comment - 17 May 2025

Why should I have to enable the j6 compatible plugin. My sites only contain core, no extensions. I don't need to enable the plugin.
This requirement makes no sense.

avatar richard67
richard67 - comment - 17 May 2025

Why should I have to enable the j6 compatible plugin. My sites only contain core, no extensions. I don't need to enable the plugin. This requirement makes no sense.

@brianteeman Because we can not know if this is the case when someone updates to J6. Therefore it was decided by the CMS Maintenance Team that it shall be enabled on updates to 6, and the compat6 plugin is enabled by default in Joomla 5, see #45371 . You can later after the update disable in in J6.

avatar richard67
richard67 - comment - 17 May 2025

P.S.: Even if there are no 3rd party extensions at all, there still can be overrides using classes which were moved into the compat6 plugin in J6, e.g. from the CMS Filesystem stuff, and we can not really check all that.

avatar brianteeman
brianteeman - comment - 17 May 2025

Crazy

avatar richard67
richard67 - comment - 17 May 2025

Crazy

@brianteeman If you think making the update as safe as possible for as many users as possible is crazy then I cannot help you.

avatar brianteeman
brianteeman - comment - 17 May 2025

we are doing something very wrong if a site with only core requires this plugin

avatar richard67
richard67 - comment - 17 May 2025

we are doing something very wrong if a site with only core requires this plugin

It seems you did not understand my previous comment. It is not needed for the core but for the case someone has 3rd party extensions or overrides which require it.

avatar HLeithner
HLeithner - comment - 18 May 2025

thank you that pr looks good to me, will test later

avatar HLeithner HLeithner - test_item - 18 May 2025 - Tested successfully
avatar HLeithner
HLeithner - comment - 18 May 2025

I have tested this item βœ… successfully on 89b2893

Works as expected.


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/45493.

Compat Plugin for 5 is active and for 6 is disabled:
image

Compat Plugin for 5 is disabled and for 6 is active
image

avatar brianteeman brianteeman - test_item - 18 May 2025 - Tested unsuccessfully
avatar brianteeman
brianteeman - comment - 18 May 2025

I have tested this item πŸ”΄ unsuccessfully on 89b2893

Completely ignores the cli update


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/45493.

avatar brianteeman
brianteeman - comment - 18 May 2025

image

image

and it appears to have hung [update] just slow

avatar richard67
richard67 - comment - 19 May 2025

@brianteeman Thanks for testing. It seems that there is only the check for database schema in the CLI, all other checks (including those added by this PR) are not there. I wasn't aware of that.

Before I update this PR to work also with the CLI, I will investigate if there are other ways to handle the compatibility plugins.

We might also need to discuss it again in the maintainers team.

I'm setting this PR to draft in the mean time.

avatar brianteeman
brianteeman - comment - 19 May 2025

@brianteeman Thanks for testing. It seems that there is only the check for database schema in the CLI, all other checks (including those added by this PR) are not there. I wasn't aware of that.

It is a two year old bug
#40444

avatar richard67
richard67 - comment - 21 May 2025

Ok, we have discussed this PR in the maintainer meeting, and it is ok, so I change back from draft to ready for review.

avatar richard67
richard67 - comment - 21 May 2025

P.S.: I will see if I can add a check in the CLI in the next days.

avatar joomla-cms-bot joomla-cms-bot - change - 24 May 2025
Category Administration com_joomlaupdate Language & Strings Administration com_joomlaupdate Language & Strings Libraries
avatar richard67 richard67 - change - 24 May 2025
The description was changed
avatar richard67 richard67 - edited - 24 May 2025
avatar richard67 richard67 - change - 24 May 2025
The description was changed
avatar richard67 richard67 - edited - 24 May 2025
avatar richard67 richard67 - change - 24 May 2025
The description was changed
avatar richard67 richard67 - edited - 24 May 2025
avatar richard67 richard67 - change - 24 May 2025
The description was changed
avatar richard67 richard67 - edited - 24 May 2025
avatar richard67 richard67 - change - 24 May 2025
The description was changed
avatar richard67 richard67 - edited - 24 May 2025
avatar richard67
richard67 - comment - 24 May 2025

I've refactored this PR to use more general language string names so the language strings can also be used to check other plugins, modified the links in the pre-update check notices so they show the plugin list filtered for the particular plugin, and I've added an additional step to the CLI core update for checking pre-conditions in case of a major upgrade to check the 2 b/c plugins.

@HLeithner Could you test again, also the CLI?

@brianteeman Could you also test again tomorrow?

@Kostelano Maybe you can test, too?

Thanks in advance.

avatar ceford ceford - test_item - 25 May 2025 - Not tested
avatar ceford
ceford - comment - 25 May 2025

I have not tested this item.

I found the instructions a little confusing at first and did not want to actually update a newly installed test site. The confusing bit was this in the Summary at the start:

  • Check if the backward compatibility plugin of the current major version (here 5) is disabled.
  • Check if the backward compatibility plugin of the next major version (here 6) is enabled.

It seems you need to set both values for the update to go ahead but reverse the settings to ensure they fail.

Otherwise it is well explained and looks good to me. I would set it to Success except that I did not go through with the update (and now have to go out).


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/45493.

avatar richard67
richard67 - comment - 26 May 2025

Because I was a bit late with the latest changes on this PR, it will not be in 5.4.0-alpha1 release tomorrow.

But we still need it for 5.4.0-alpha2.

So human tests are still welcome and needed.

avatar ceford ceford - test_item - 26 May 2025 - Tested successfully
avatar ceford
ceford - comment - 26 May 2025

I have tested this item βœ… successfully on 649c764

Seems OK. I got the blocking messages for major update but not minor update and completed both the major update and the 'fixed' minor update.


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/45493.

avatar SniperSister SniperSister - test_item - 31 May 2025 - Tested successfully
avatar SniperSister
SniperSister - comment - 31 May 2025

I have tested this item βœ… successfully on 649c764

Works as described!


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/45493.

avatar alikon alikon - change - 31 May 2025
Status Pending Ready to Commit
avatar alikon
alikon - comment - 31 May 2025

RTC


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/45493.

avatar muhme
muhme - comment - 31 May 2025

Great test description πŸ‘

Tested 5.4-dev branch with JBT:

  • βœ… 17 steps from Test 1 'Update to 6.0 nightly build' successful tested, updated to 6.0.0-alpha2-dev, 'Behaviour - Backward Compatibility' is deleted
  • βœ… Additional tested: Reinstalling and update from administrator backend
  • βœ… 7 steps from Test 2 'Update to 5.4 nightly build' tested successfully
    • explicit with disabled 'Behaviour - Backward Compatibility 6'
  • ❌ Additional tested: With installed PR and disabled 'Behaviour - Backward Compatibility 6' plugin tested manual update by upload Joomla_6.0.0-alpha1-Alpha-Update_Package.zip from administrator backend and it is installing without any checks – Shouldn't the checks also run for installations via file upload?
avatar richard67
richard67 - comment - 31 May 2025
  • ❌ Additional tested: With installed PR and disabled 'Behaviour - Backward Compatibility 6' plugin tested manual update by upload Joomla_6.0.0-alpha1-Alpha-Update_Package.zip from administrator backend and it is installing without any checks – Shouldn't the checks also run for installations via file upload?

@muhme Thatβ€˜s expected. Read the description of this PR:

You can bypass these tests by using the "Upload & Update" button, but that's already the case with other required settings checks and should be fixed with another PR, if ever.

avatar muhme muhme - change - 31 May 2025
Labels Added: RTC
avatar muhme
muhme - comment - 31 May 2025

System Tests already known error 'PHP Warning: Undefined array key "status"' ignored

avatar muhme muhme - change - 31 May 2025
Status Ready to Commit Fixed in Code Base
Closed_Date 0000-00-00 00:00:00 2025-05-31 10:51:30
Closed_By muhme
avatar muhme muhme - close - 31 May 2025
avatar muhme muhme - merge - 31 May 2025
avatar muhme
muhme - comment - 31 May 2025

Thank you for your contribution and thank you to all testers for testing.

avatar richard67
richard67 - comment - 31 May 2025

Thanks to all testers.

Add a Comment

Login with GitHub to post a comment