-
-
Notifications
You must be signed in to change notification settings - Fork 3.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[5.2] Error handling on extension update #43321
Conversation
Try this test plugin - screenshots before applying the pull request changes.
|
Test does not work on Unix system! - must be filename case, investigating. |
I am using windows |
Sorted, no change to the above needed, can go ahead with testing. |
Changed. Sorry, copied the changed code across and forgot the use statement. |
administrator/components/com_installer/src/Model/UpdateModel.php
Outdated
Show resolved
Hide resolved
Co-authored-by: Quy <quy@nomonkeybiz.com>
You also forgot to check the language string you used and the string you created. |
administrator/components/com_installer/src/Model/UpdateModel.php
Outdated
Show resolved
Hide resolved
Retested as: #43321 (comment) With changes made the message is now: |
I am all in favour of meaningfull error messages but they also have to be helpful. In this example the advice is not helpful at all as it means nothing at all to the user. This is a message that is only useful to the original extension developer and is not something that an end user shoudl ever see. Extension developers dont release updates without testing they work do they |
Regardless of who is to blame for the error what I propose is better and more useful than what Joomla currently displays. This is actually not a plugin bug - the plugin is used by and depends on a 3rd party extension, it is that dependency which causes the problem when the update is attempted with the plugin enabled. Could modify such plugins to protect against such errors but I see that as unnecessary code in the plugin when Joomla can handle it more gracefully. I suppose could add another line to the error message: Could enhance further by adding contact information from current XML? |
The question is. Does the new message help the end user more than the original message. For me the answer is no |
The end user is an admin who hopefully knows the extensions installed on their site. The current error is missleading as it implies it is a bug in the Joomla installer ... which led to me being asked a question which started me on this. |
I think that this helps "Please contact the extension developer of the Plugin ... ". |
@chmst the problem is that according to @BrainforgeUK the problem is not with the developer of this plugin but with the developer of a completely different extension upon which it depends - so which extension developer am I going to contact? For me that is not the problem. The problem is that the extension that is being installed is not checking for the presence of the extension it is dependent upon. ergo nothing sensible can be changed in core to fix an extension developers errors |
@brianteeman - thanks, agreed. |
@TLWebdesign as this PR is for 5.1 and not 5.2 then you should be marking this as an unsuccessful test |
I have tested this item 🔴 unsuccessfully on bb1c6aa This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/43321. |
This pull request has been automatically rebased to 5.2-dev. |
I have tested this item ✅ successfully on bb1c6aa This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/43321. |
administrator/components/com_installer/src/Model/UpdateModel.php
Outdated
Show resolved
Hide resolved
administrator/components/com_installer/src/Model/UpdateModel.php
Outdated
Show resolved
Hide resolved
RTC This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/43321. |
Thanks @BrainforgeUK ! |
joomla/joomla-cms#44139 + joomla/joomla-cms#44286 + joomla/joomla-cms#44166 + joomla/joomla-cms#43321 + joomla/joomla-cms#44266 - (только для др. пакетов) joomla/joomla-cms#44452 - (только для др. пакетов) + испр. ошибки #118
Pull Request for Issue #43319 .
Summary of Changes
Catch errors from the extension being updated and abort update with a sensible message.
Testing Instructions
(a) Installed this Plugin.
plg_updatetest1.zip
(b) Enable the plugin.
(c) Go to Joomla updater and check for updates.
(d) Then select the plugin installed above PLG_HIKASHOPSHIPPING_BFEXTRAFEATURES and update it.
Actual result BEFORE applying this Pull Request
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:
No documentation changes for manual.joomla.org needed