User tests: Successful: Unsuccessful:
Pull Request for Issue #43591 .
Alternative to PR #43717 .
This pull request (PR) does 2 things:
The reason for this is that with the change to TUF-based updates in 5.1.0, the update channels are handled differently to how it was done before (and still is done with 4.4).
JVERSION . '.x'
for the "Default" and JVERSION+1 . '.x'
for "Joomla Next".And when your update source was "Joomla Next" before the update you can only have come from the previous major version. E.g. when you have updated to 5.1 with "Joomla Next" you for sure came from 4.4, and when you have updated to 6.0 with "Joomla Next" you for sure came from the latest 5.x (currently 5.2. but will be 5.4 at the end of the 5.x cycle).
Therefore we can reset from "Joomla Next" to "Default" after every update, there is no need for additional version checks.
The change mentioned above with change number 2, the new installer script for the component, will be removed again with 6.0 because it will not be needed anymore with 6.0. Therefore this part is already marked as deprecated, and when this PR here will be merged and be merged up into 6.0-dev (via 5.2-dev) I will make a PR for 6.0-dev for the removal.
For the stand-alone update mentioned with change number 2 see also joomla/update.joomla.org#366 .
Update: Meanwhile I've made the alternative PR #43717 which does only part 1 of this PR here and can be used if it turns out that it does not need the extra update for the Joomla Update Component because we can offer the core update to 5.1.2 on both channels so people will find it also when being on "Joomla Next".
Pre-condition: You have to be on Joomla version 5.1.0, 5.1.1 or 5.1.2-dev.
Update the Joomla Update Component either by uploading the patched zip package in the extensions installer or by changing the update site URL for the Joomla Update Component e.g. with phpMyadmin and then checking for extension updates.
The patched package can be downloaded from here: https://test5.richard-fath.de/com_joomlaupdate-5.1.2.zip
The custom update site URL which points to this package can be found here: https://test5.richard-fath.de/com_joomlaupdate_test-5-1-2.xml
Do several tests with different starting conditions regarding the update source set in the Joomla Update Component's options:
In addition, do the same different tests using the following patched package for upload in the extensions installer: https://test5.richard-fath.de/com_joomlaupdate-5.1.2-test-error.zip
The patched package provokes a database error for checking what happens when the reset of the update source fails. It can also be used to check that the reset does not take place when the update source is not "Joomla Next" before the update.
It does not need to fall back to the same starting conditions after each test, you can just upload the package again in the extension installer or when using the custom update URL, patch the version in the manifest cache of the component's record in the extension table. But you should at least use a new browser tab or logout and in again after each test to make sure you do not see any old but still enqueued messages (which is another issue when doing several core or extension update attempts in a row and which is not related to this PR).
Update the CMS core by uploading in the Joomla Update Component the patched zip package created by Drone for this PR.
You can download that package here: https://artifacts.joomla.org/drone/joomla/joomla-cms/5.1-dev/43695/downloads/76879/
Do several tests with different starting conditions regarding the update source set in the Joomla Update Component's options:
When using "Custom URL" you can use the custom URL created by Drone for this PR instead of uploading the package. You can find that custom URL at the same place where you could find the patched package.
In addition, do the same different tests using the following patched package for upload: https://test5.richard-fath.de/Joomla_5.1.2-dev+pr.43695-Development-Update_Package_test-error.zip
The patched package provokes a database error for checking what happens when the reset of the update source fails. It can also be used to check that the reset does not take place when the update source is not "Joomla Next" before the update.
It does not need to fall back to the same starting conditions after each test, you can just upload the package again in the update component. But you should at least use a new browser tab or logout and in again after each test to make sure you do not see any old but still enqueued messages (which is another issue when doing several core or extension update attempts in a row and which is not related to this PR).
Change the update site URL for the Joomla Update Component e.g. with phpMyadmin to the following URL and then check for extension updates: https://test5.richard-fath.de/com_joomlaupdate_test-5-1-2.xml
Do that on different Joomla CMS versions, e.g. 4.4.x, 5.1.0, 5.1.1 or a 5.2.0-alpha1 or a 5.2-dev or 6.0-dev nightly.
When you are still on the "Joomla Next" update channel after an update from 4.4 to 5.1, there will not be any update found for the CMS core until 6.0.0-alpha1 will be released, and then only updates to 6.0 releases will be found, so you will miss any further updates for 5.1 until that time has come.
There is no notification about that and no automatic reset after the update.
Updating the Joomla Update Component component works.
When having the update source (update channel) set to "Joomla Next" in the Joomla Update Component's options before that update, the update source is rest to "Default" at the end of the update, and an information message is shown about that:
When under the same conditions an error happens with that reset, e.g. due to a database problem, a warning message is shown, which tells the user to manually reset the update source:
The update of the component is shown as success as nothing else is broken.
When the update source is not "Joomla Next" so it is "Default" or "Custom URL", the update source is not changed, and the update of the components works as it does without this PR:
Updating the Joomla CMS core works.
When having the update source (update channel) set to "Joomla Next" in the Joomla Update Component's options before that update, the update source is rest to "Default" at the end of the update, and a success message is shown about that:
When under the same conditions an error happens with that reset, e.g. due to a database problem, the usual error layout is shown with all details, and in addition a warning message is shown at the top, telling the user to manually reset the update source:
In this case the Joomla Update log administrator/logs/joomla_update.php
contains details like for other errors:
2024-06-22T16:44:16+00:00 INFO 192.168.98.1 update Test logging
2024-06-22T16:44:16+00:00 INFO 192.168.98.1 update Uploading update file
2024-06-22T16:44:18+00:00 INFO 192.168.98.1 update File [ROOT][TMP]/juRNnKH5 downloaded.
2024-06-22T16:44:18+00:00 INFO 192.168.98.1 update Starting installation of new version.
2024-06-22T16:44:25+00:00 INFO 192.168.98.1 update Finalising installation.
2024-06-22T16:44:26+00:00 INFO 192.168.98.1 update Start of SQL updates.
2024-06-22T16:44:26+00:00 INFO 192.168.98.1 update The current database version (schema) is 5.1.1-2024-04-18.
2024-06-22T16:44:26+00:00 INFO 192.168.98.1 update End of SQL updates.
2024-06-22T16:44:26+00:00 INFO 192.168.98.1 update Uninstalling extensions
2024-06-22T16:44:26+00:00 INFO 192.168.98.1 update Deleting removed files and folders.
2024-06-22T16:44:26+00:00 ERROR 192.168.98.1 update An error has occurred while running "resetUpdateSource". Code: 1054. Message: Unknown column 'paramsx' in 'field list'.
2024-06-22T16:44:26+00:00 INFO 192.168.98.1 update Cleaning up after installation.
2024-06-22T16:44:26+00:00 INFO 192.168.98.1 update Update to version 5.1.2-dev is complete.
When the update source is not "Joomla Next" so it is "Default" or "Custom URL", the update source is not changed, and the update of the CMS core works as it does without this PR:
The update for the Joomla Update Component will only be found when the CMS version is 5.1.0, 5.1.1 or 5.1.2(-dev) but not e.g. on 4.4.x or 5.2.0(-dev).
When later 5.1.2 stable is released and you have updated the CMS to 5.1.2, the targetplatform for the component update would still match, but there will not be an update found anymore for the component because it will already be up to date with its version 5.1.2.
Please select:
No documentation changes for docs.joomla.org needed
No documentation changes for manual.joomla.org needed
Status | New | ⇒ | Pending |
Category | ⇒ | Administration com_joomlaupdate Language & Strings |
Test 1 - Successful according to what is expected
Test 2 - @richard67 I can't seem to be able to find https://test5.richard-fath.de/Joomla_5.1.2-dev-Development-Update_Package_test-pr-43695.err.zip
Test 3 - Seems to work :-)
Test 2 - @richard67 I can't seem to be able to find https://test5.richard-fath.de/Joomla_5.1.2-dev-Development-Update_Package_test-pr-43695.err.zip
@obuisard Sorry, my mistake, had forgotten to upload it. I've meanwhile created a new one based on the one cleared by Drone for this PR. Please use https://test5.richard-fath.de/Joomla_5.1.2-dev+pr.43695-Development-Update_Package_test-error.zip . I've updated the testing instructions with the new link. Thanks for testing so far.
@obuisard Sorry, my mistake, had forgotten to upload it. I've meanwhile created a new one based on the one cleared by Drone for this PR. Please use https://test5.richard-fath.de/Joomla_5.1.2-dev+pr.43695-Development-Update_Package_test-error.zip . I've updated the testing instructions with the new link. Thanks for testing so far.
Thank you, Richard!
For Test 2, I cannot get it to fail with the latest package.
Meanwhile I've made the alternative PR #43717 which does only part 1 of this PR here (which is tested with Test 2 here) and can be used if it turns out that it does not need the extra update for the Joomla Update Component because we can offer the core update to 5.1.2 on both channels so people will find it also when being on "Joomla Next".
Status | Pending | ⇒ | Closed |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2024-07-02 17:01:08 |
Closed_By | ⇒ | richard67 | |
Labels |
Added:
Language Change
PR-5.1-dev
|
Thank you!