-
-
Notifications
You must be signed in to change notification settings - Fork 3.7k
[3.9] Log the from version on actionlogs when Joomla update #30714
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
Conversation
Co-authored-by: Richard Fath <[email protected]>
Co-authored-by: Richard Fath <[email protected]>
Co-authored-by: Richard Fath <[email protected]>
Co-authored-by: Richard Fath <[email protected]>
|
@alikon It seems that it needs to apply the patch of this PR before doing the update to that package which you have linked. |
|
Yes i forgot that, I'll add it
Il lun 21 set 2020, 16:05 Richard Fath <[email protected]> ha
scritto:
… @alikon <https://github.com/alikon> It seems that it needs to apply the
patch of this PR before doing the update to that package which you have
linked.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#30714 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AABMLMKAXH7KBVD463FQPOLSG5MR5ANCNFSM4RUKTPUA>
.
|
|
I have tested this item ✅ successfully on c3c8480 This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/30714. |
1 similar comment
|
I have tested this item ✅ successfully on c3c8480 This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/30714. |
|
RTC This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/30714. |
|
This could be a B/C break if |
|
Why should onJoomlaAfterUpdate be triggered by a 3rd party extension? I mean we have no way to protect events but do you think a 3rd party extension triggers this? Or do you mean the plugin should add a default value for the $oldVersion parameter? |
|
Given that this event was recently added, is undocumented and has a very limited use case, I don't think anyone is actually using it. But if you want to be really careful, adding a default value would be a sensible thing to do. |
|
did you mean someting like |
|
Maybe null or empty string as default, and in the code use a JTEXT for 'unknown' if the parameter is empty, so it can be translated? On the other hand, that seems to be a bit over-engineered for something which should never happen. So I'd be ok with anything, no default like now, or hard-coded like suggested above. |
|
Yes please add ="unknown" |
|
added |
|
Thanks, plz 2 tests and can be merged |
|
plz also with a plugin that triggers the event without parameter. |
|
Wouldn't is be better to use an empty string as default value for |
|
@HLeithner I don't have such plugin so I can't test. |
IMO should be |
|
@HLeithner Shouldn't a code review be sufficient for the default value part of this PR? Does it really need to write a plugin to test this? |
|
if you use null (without language) you will end in a broken text string "...updated Joomla from to 3.9.22" Actually while testing you see this broken string, so I would suggest to catch this case better and change the code from $oldVersion='unknown' to $oldVersion=null and test on if empty($oldVersion) and set the unkown version string... @richard67 no you don't need to create a plugin you only have to trigger the event for example in a template:
or |
Well, you wrote "plz also with a plugin that triggers the event without parameter." 😛 |
|
@alikon Could you change it to ? |
Co-authored-by: Richard Fath <[email protected]>
wrong wording sorry |
Now you say that? I almost have my plugin ready 🤣 . (joking) |
|
I've updated the custom update URL in the testing instructions to the one of the new build. |
|
I have tested this item ✅ successfully on ee6b10f Result: "User whoeveriamdoesnotmatter updated Joomla from 3.9.22-dev to 3.9.22-dev+pr.30714"
Result: 3 times "User whoeveriamdoesnotmatter updated Joomla from Unknown to 3.9.22-dev+pr.30714", one time "User whoeveriamdoesnotmatter updated Joomla from 5.0.0 to 3.9.22-dev+pr.30714" This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/30714. |
Pull Request for Issue #30499 .
Summary of Changes
Log the from version on Joomla update event on the Actionlogs
Testing Instructions
apply pr
joomlaupdate -> options
change to Custom URL
and put this manifest https://ci.joomla.org/artifacts/joomla/joomla-cms/staging/30714/downloads/35635/pr_list.xml
is the one available on bottom near Download — Prebuilt packages are available for download.
Actual result BEFORE applying this Pull Request
information about from version not available
Expected result AFTER applying this Pull Request
information about from version available

Documentation Changes Required