RTC Release Blocker bug PR-5.1-dev Pending

User tests: Successful: Unsuccessful:

avatar richard67
richard67
10 Mar 2024

Pull Request for Issue #42993 .

Summary of Changes

This pull request (PR) fixes the new version check which was added with PR #42799 so it works with version strings which contain a "+" character. Currently these characters are stripped off by the $this->input->get call because that uses the "cmd" filter by default, so the check fails. Using the "string"filter fixes this issue.

This fixes Live Update currently not working for custom update URLs created by Drone for pull requests.

In addition, a default value \JVERSION is added to the same $this->input->get call so that the "Reinstall Joomla! core files" button works.

Otherwise, when using null or '', you can update to the patched package of a PR but then the "Reinstall Joomla! core files" button fails with the same error message as mentioned for the first issue, and debug shows that the input is not set so the default is used.

Testing Instructions

  1. On a current 5.1-dev branch or a 5.1.0.-beta1 or a current 5.1 nightly build, change the update channel in the Joomla Update component's options to "Custom URL" and enter the custom update URL created by drone for some current 5.1-dev PR. E.g. for PR #42992 use https://artifacts.joomla.org/drone/joomla/joomla-cms/5.1-dev/42992/downloads/74472/pr_list.xml .
    Result: An update to the patched package for that PR is found.

  2. Try to update.
    Result: See section "Actual result BEFORE applying this Pull Request" below.

  3. Apply the change of this PR.

  4. Reload the page and then try to update.
    Result: The update succeeds. See section "Expected result AFTER applying this Pull Request" below.

  5. Search again for updates or reload the page.
    Result: You are up to date, and the "Reinstall Joomla! core files" button is shown at the bottom.

  6. Use the "Reinstall Joomla! core files" button.
    Result: It works. See section "Expected result AFTER applying this Pull Request" below.

Actual result BEFORE applying this Pull Request

The update is not started. A red error message shows a version mismatch:
2024-03-10_j5 1 0-beta1_live-update-to-pr-package

The error message comes from a new version check implemented with PR #42799 here: https://github.com/joomla/joomla-cms/blob/5.1-dev/administrator/components/com_joomlaupdate/src/Controller/UpdateController.php#L65-L77

When adding some debug code at that place you can see that $result['version'] is 5.1.0-beta2-dev+pr.42992 and $this->input->get('targetVersion') is 5.1.0-beta2-devpr.42992, so the latter is missing the + between the devand the pr.

Expected result AFTER applying this Pull Request

Update is started and succeeds.

After that, the "Reinstall Joomla! core files" works, too.

Link to documentations

Please select:

  • No documentation changes for docs.joomla.org needed

  • No documentation changes for manual.joomla.org needed

avatar richard67 richard67 - open - 10 Mar 2024
avatar richard67 richard67 - change - 10 Mar 2024
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 10 Mar 2024
Category Administration com_joomlaupdate
avatar richard67 richard67 - change - 10 Mar 2024
The description was changed
avatar richard67 richard67 - edited - 10 Mar 2024
avatar richard67 richard67 - change - 10 Mar 2024
The description was changed
avatar richard67 richard67 - edited - 10 Mar 2024
avatar richard67 richard67 - change - 10 Mar 2024
The description was changed
avatar richard67 richard67 - edited - 10 Mar 2024
avatar richard67 richard67 - change - 10 Mar 2024
Labels Added: bug PR-5.1-dev
avatar richard67 richard67 - change - 10 Mar 2024
The description was changed
avatar richard67 richard67 - edited - 10 Mar 2024
avatar richard67 richard67 - change - 10 Mar 2024
The description was changed
avatar richard67 richard67 - edited - 10 Mar 2024
avatar richard67 richard67 - change - 10 Mar 2024
The description was changed
avatar richard67 richard67 - edited - 10 Mar 2024
avatar richard67 richard67 - change - 10 Mar 2024
Title
[5.1] Fix version check in Joomla Update component for PR packages with "+" in their version string
[5.1] Fix version check in Joomla Update component for live uptate to PR packages and reinstall core files
avatar richard67 richard67 - edited - 10 Mar 2024
avatar richard67 richard67 - change - 10 Mar 2024
Title
[5.1] Fix version check in Joomla Update component for live uptate to PR packages and reinstall core files
[5.1] Fix version check in Joomla Update component
avatar richard67 richard67 - edited - 10 Mar 2024
avatar SniperSister SniperSister - test_item - 10 Mar 2024 - Tested successfully
avatar SniperSister SniperSister - test_item - 10 Mar 2024 - Tested successfully
avatar SniperSister
SniperSister - comment - 10 Mar 2024

I have tested this item ✅ successfully on a1cf308

Works as described!


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

avatar SniperSister
SniperSister - comment - 10 Mar 2024

I have tested this item ✅ successfully on a1cf308

Works as described!


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

avatar alikon alikon - test_item - 10 Mar 2024 - Tested successfully
avatar alikon
alikon - comment - 10 Mar 2024

I have tested this item ✅ successfully on a1cf308


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

avatar alikon alikon - change - 10 Mar 2024
Status Pending Ready to Commit
avatar alikon
alikon - comment - 10 Mar 2024

RTC


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

avatar Quy Quy - change - 11 Mar 2024
Labels Added: RTC Release Blocker
avatar LadySolveig LadySolveig - change - 11 Mar 2024
Status Ready to Commit Fixed in Code Base
Closed_Date 0000-00-00 00:00:00 2024-03-11 18:26:47
Closed_By LadySolveig
avatar LadySolveig LadySolveig - close - 11 Mar 2024
avatar LadySolveig LadySolveig - merge - 11 Mar 2024
avatar LadySolveig
LadySolveig - comment - 11 Mar 2024

Thank you @richard67 ??

Add a Comment

Login with GitHub to post a comment