Feature RTC PR-5.3-dev Pending

User tests: Successful: Unsuccessful:

avatar laoneo
laoneo
24 Nov 2024

Summary of Changes

This pr adds the same logic for installer plugins to be able to modify the update site url and headers as when the extension is downloaded. A use case for this pr is to add some authentication before fetching the update site url like a bearer token, the download id or similar. For extension developers it has an additional benefit to install a plugin and modify update sites for specific clients without the extra step and a modification of the update site url in the database.

Testing Instructions

  • Install an older version of an extension or DPCalendar Free when you don't have one
  • Or you can add the following code to the file /plugins/installer/packageinstaller/src/Extension/PackageInstaller.php
public function onInstallerBeforeUpdateSiteDownload(\Joomla\CMS\Event\Installer\BeforeUpdateSiteDownloadEvent $event): void
{
        $event->updateUrl($event->getUrl().'demo=1');
}

and replace the line 47 with:

return ['onInstallerAddInstallationTab' => 'onInstallerAddInstallationTab', 'onInstallerBeforeUpdateSiteDownload' => 'onInstallerBeforeUpdateSiteDownload'];
  • Go to /administrator/index.php?option=com_installer&view=update
  • Click on "Check for updates"

Actual result BEFORE applying this Pull Request

  • DPCalendar update can be found.
  • No warning about an invalid url.

Expected result AFTER applying this Pull Request

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: joomla/Manual#340

  • No documentation changes for manual.joomla.org needed

avatar laoneo laoneo - open - 24 Nov 2024
avatar laoneo laoneo - change - 24 Nov 2024
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 24 Nov 2024
Category Libraries
avatar fgsw fgsw - test_item - 25 Nov 2024 - Tested successfully
avatar fgsw
fgsw - comment - 25 Nov 2024

I have tested this item ✅ successfully on 3bd616f

With Pull Request and without it an Update of 'DPCalendar Free' is found.


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

avatar laoneo laoneo - change - 25 Nov 2024
The description was changed
avatar laoneo laoneo - edited - 25 Nov 2024
avatar laoneo
laoneo - comment - 25 Nov 2024

I'v updated the testing instructions, to actually see if the event also works.

avatar laoneo laoneo - change - 25 Nov 2024
The description was changed
avatar laoneo laoneo - edited - 25 Nov 2024
avatar laoneo laoneo - change - 25 Nov 2024
The description was changed
avatar laoneo laoneo - edited - 25 Nov 2024
avatar HLeithner
HLeithner - comment - 25 Nov 2024

The event needs validation, if you set a url this should be validated, at least if it is a string hand has a proper schema set. Similar to the headers argument, needs to be an array of strings (with key?).

avatar laoneo
laoneo - comment - 25 Nov 2024

All of this should be done done in the parent class and is not in the scope of this pr.

avatar fgsw fgsw - test_item - 27 Nov 2024 - Not tested
avatar fgsw
fgsw - comment - 27 Nov 2024

I have not tested this item.


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

avatar laoneo laoneo - change - 2 Dec 2024
Labels Added: Feature PR-5.3-dev
avatar exlemor exlemor - test_item - 4 Dec 2024 - Tested successfully
avatar exlemor
exlemor - comment - 4 Dec 2024

I have tested this item ✅ successfully on aa23300

I have tested this successfully. Please see note below.

To be more precise in case this is important:

BEFORE the PATCH, there was a whole long list of error lines:

For the extension DPCalendar Free version 7.0.2 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 7.0.1 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 7.0.0 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 6.3.7 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 6.3.6 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 6.3.5 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 6.3.4 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 6.3.3 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 6.3.2 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 6.3.1 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 6.3.0 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 6.2.1 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 6.2.0 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 6.1.5 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 6.1.4 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 6.1.3 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 6.1.2 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 6.1.1 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 6.1.0 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 6.0.11 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 6.0.10 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 6.0.9 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 6.0.8 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 6.0.7 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 6.0.6 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 6.0.5 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 6.0.4 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 6.0.3 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 6.0.2 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 6.0.1 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 6.0.0 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.6.7 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.6.6 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.6.5 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.6.4 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.6.3 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.6.2 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.6.1 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.6.0 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.5.1 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.5.0 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.4.4 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.4.3 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.4.2 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.4.1 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.4.0 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.3.8 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.3.7 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.3.6 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.3.5 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.3.4 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.3.3 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.3.2 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.3.1 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.3.0 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.2.4 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.2.3 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.2.2 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.2.1 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.2.0 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.1.2 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.1.1 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.1.0 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.0.6 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.0.5 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.0.4 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.0.3 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.0.2 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.0.1 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 5.0.0 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 4.2.9 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 4.2.8 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 4.2.7 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 4.2.6 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 4.2.5 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 4.2.4 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 4.2.3 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 4.2.2 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 4.2.1 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 4.2.0 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 4.1.4 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 4.1.3 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 4.1.2 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 4.1.1 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 4.1.0 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 4.0.12 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 4.0.11 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 4.0.10 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 4.0.9 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 4.0.8 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 4.0.7 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 4.0.6 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 4.0.5 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 4.0.4 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 4.0.3 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 4.0.2 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 4.0.1 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
For the extension DPCalendar Free version 4.0.0 is available, but it requires at least PHP version 8.3 while your system only has 8.2.26
Before updating ensure that the update is compatible with your Joomla! installation.
You are strongly advised to make a backup of your site's files and database before you start updating.

what is odd is the version I installed was 9.2.1 but the messages stop at 7.0.2

AFTER the PATCH, the messages start with:

Update: Could not open update site #2 "Accredited Joomla! Translations", URL: https://update.joomla.org/language/translationlist_5.xmldemo=1
Update: Could not open update site #3 "Joomla! Update Component", URL: https://update.joomla.org/core/extensions/com_joomlaupdate.xmldemo=1
Update: Could not open update site #4 "Akeeba Backup Core for Joomla!", URL: https://cdn.akeeba.com/updates/pkgakeebabackupcore.xmldemo=1
Update: Could not open update site #5 "Patch Tester Component", URL: https://raw.githubusercontent.com/joomla-extensions/patchtester/master/manifest.xmldemo=1
plus the long list above...


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/44516.
avatar laoneo laoneo - change - 4 Dec 2024
Status Pending Ready to Commit
avatar laoneo
laoneo - comment - 4 Dec 2024

The DPCalendar warnings are not related to this pr. So we are RTC.


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

avatar laoneo laoneo - change - 4 Dec 2024
Labels Added: RTC
avatar laoneo laoneo - change - 7 Dec 2024
Title
Send an event before an update site is downloaded
[5.3] Send an event before an update site is downloaded
avatar laoneo laoneo - edited - 7 Dec 2024
avatar bembelimen bembelimen - change - 15 Dec 2024
Status Ready to Commit Fixed in Code Base
Closed_Date 0000-00-00 00:00:00 2024-12-15 16:22:22
Closed_By bembelimen
avatar bembelimen bembelimen - close - 15 Dec 2024
avatar bembelimen bembelimen - merge - 15 Dec 2024
avatar bembelimen
bembelimen - comment - 15 Dec 2024

Thx

Add a Comment

Login with GitHub to post a comment