Skip to content
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

Proposal for new strings regarding the update channels (streams) #5308

Closed
smanzi opened this issue Dec 3, 2014 · 24 comments
Closed

Proposal for new strings regarding the update channels (streams) #5308

smanzi opened this issue Dec 3, 2014 · 24 comments

Comments

@smanzi
Copy link

smanzi commented Dec 3, 2014

This comes after a chat I had with @infograf768 on Slack:

The proposal is to modify the descriptions of the different updates options.

  • I changed the term "stream" to "channel", which IMHO is of more easily understanding. "server" too can be an option: although technically inaccurate it is of even easier understanding.
  • I introduced two new strings (the last two)

COM_JOOMLAUPDATE_VIEW_DEFAULT_UPDATES_INFO_CUSTOM="You are connected to a %s - This is not an official Joomla! update channel."

; @deprecated for 4.0 replace COM_JOOMLAUPDATE_VIEW_DEFAULT_UPDATES_INFO_LTS with COM_JOOMLAUPDATE_VIEW_DEFAULT_UPDATES_INFO_CURRENT
COM_JOOMLAUPDATE_VIEW_DEFAULT_UPDATES_INFO_LTS="You are connected to the %s update channel - This channel is designed for the current major release and provides all minor and patch updates of your version until the support for your version ends."

COM_JOOMLAUPDATE_VIEW_DEFAULT_UPDATES_INFO_NOCHANGE="You are not connected to an update channel and will not recieve updates. This setting will compromise the security of your site."

; @deprecated for 4.0 replace COM_JOOMLAUPDATE_VIEW_DEFAULT_UPDATES_INFO_STS with COM_JOOMLAUPDATE_VIEW_DEFAULT_UPDATES_INFO_ALL
COM_JOOMLAUPDATE_VIEW_DEFAULT_UPDATES_INFO_STS="You are connected to the %s update channel - This channel is designed for major releases and provides all major, minor and patch updates. So you are always on the last version of Joomla!."

COM_JOOMLAUPDATE_VIEW_DEFAULT_UPDATES_INFO_TESTING="You have chosen the %s update channel - This channel is designed for testing new releases and issues in Joomla!.
It is only intended for JBS (Joomla! Bug Squad) members and others within the Joomla! community who are testing upcoming releases. DO NOT USE THIS SETTING ON A PRODUCTION SITE."

COM_JOOMLAUPDATE_VIEW_DEFAULT_UPDATES_INFO_CURRENT="You have chosen the %s update channel - Through this channel you'll receive notfications for updates of the current major release (3.x) but you will NOT be notified of a possible new major releases (4.x)"

COM_JOOMLAUPDATE_VIEW_DEFAULT_UPDATES_INFO_ALL="You have chosen the %s update channel - Through this channel you'll receive notfications for updates of the current major release (3.x) and you will also be notified of a possible new major releases (4.x)"

If there is a consensus, I'll turn this into a PR (possibly together with other related strings). Suggestions and criticism are welcome (English is not my mother-tongue...)

@zero-24
Copy link
Contributor

zero-24 commented Dec 3, 2014

thanks @smanzi but we cant change the language constants to _ALL and _CURRENT. What is the problem with _Major and _minor? (as it say the same :D)

About the english i hope @brianteeman can have a look into it.

@zero-24
Copy link
Contributor

zero-24 commented Dec 3, 2014

BTW for B/C reasons we need to stay with _STS and _LTS anyway until 4.x is released.

Should read all bevor comment ... :D

@zero-24
Copy link
Contributor

zero-24 commented Dec 3, 2014

Suggestions and criticism are welcome

maybe „%s“ so the "Update channel name" is clear isolated.

@smanzi
Copy link
Author

smanzi commented Dec 3, 2014

@zero-24 Talking with @infograf768 I had the impression that he was open to new names for the constants, but I'm not opposing at all if this is for whatever reason a problem.

I also had the impression that the 2 new strings were meant to be used right now, with J! 3.4.0, but I prefer to leave him the word...

agreed for the quotes!

@smanzi
Copy link
Author

smanzi commented Dec 3, 2014

as for the constant names, _MAJOR can give the impression that it is related to new major releases only

@smanzi
Copy link
Author

smanzi commented Dec 3, 2014

... of course there is a typo notfications notifications

@smanzi
Copy link
Author

smanzi commented Dec 3, 2014

maybe, to be even more explicit:

COM_JOOMLAUPDATE_VIEW_DEFAULT_UPDATES_INFO_ALL="You have chosen the %s update channel - Through this channel you'll receive notifications for updates of the current major release (3.x) and you will also be notified of a possible new major releases (4.x) whose compatibility with your environment must be thoroughly assessed"

@zero-24
Copy link
Contributor

zero-24 commented Dec 3, 2014

@smanzi if we use ALL and/or CURRENT we need to fix also here: https://github.com/joomla/joomla-cms/pull/3681/files

as for the constant names, _MAJOR can give the impression that it is related to new major releases only

This constand is never shown to the user. 😄

@zero-24
Copy link
Contributor

zero-24 commented Dec 3, 2014

@smanzi if we use ALL and/or CURRENT we need to fix also here: https://github.com/joomla/joomla-cms/pull/3681/files

and need to use / handle LTS/STS for B/C reasons until 4.x here: https://github.com/joomla/joomla-cms/pull/3917/files

@brianteeman
Copy link
Contributor

I wrote new string at @infograf768 request last week. Don't know what he
did with them
On 3 Dec 2014 20:52, "zero-24" notifications@github.com wrote:

@smanzi https://github.com/smanzi if we use ALL and/or CURRENT we need
to fix also here: https://github.com/joomla/joomla-cms/pull/3681/files

and need to use / handle LTS/STS for B/C reasons until 4.x here:
https://github.com/joomla/joomla-cms/pull/3917/files


Reply to this email directly or view it on GitHub
#5308 (comment).

@zero-24
Copy link
Contributor

zero-24 commented Dec 3, 2014

oh sorry @brianteeman than i have missunderstand you about this. Thanks.

@smanzi
Copy link
Author

smanzi commented Dec 3, 2014

... we seems to be a bit out of sync... 😕

@brianteeman
Copy link
Contributor

This is what I gave to @infograf768 at his request last week and he said he was doing a PR

" You are connected to the 3.x update stream - This stream is designed for major releases and provides all major, minor and patch updates. So you are always on the current version of Joomla! 3.x.

" This stream reserved for future use. - You are connected to the 4.x update stream - This stream is designed for future major release that may be backwards incompatible and is provided to enable you to update to the next major version of Joomla. Once you have updated your site to 4.x this stream provides all major, minor and patch updates. So you are always on the latest version of Joomla! 4.x."

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

@infograf768
Copy link
Member

It is OK to use new constants in 3.4.0. Therefore if a lang pack has not been updated, the user will at least get the information in English. As anyway we drop 3.2.x, it is really better.
@brianteeman
The point is, if I understand well, that the second choice will also propose the 3.x update, which makes it confusing. Therefore why I could not make up my mind.

@zero-24
Copy link
Contributor

zero-24 commented Dec 4, 2014

It is OK to use new constants in 3.4.0.

Sure but we need to take care of this: https://github.com/joomla/joomla-cms/blob/staging/administrator/components/com_joomlaupdate/views/default/tmpl/default.php#L14-16

So until 4.x we need to use LTS and STS anyway 😄

As that the values we have here: https://github.com/joomla/joomla-cms/blob/staging/administrator/components/com_joomlaupdate/config.xml#L16-18

@infograf768
Copy link
Member

If I understand well, we can change "COM_JOOMLAUPDATE_VIEW_DEFAULT_UPDATES_INFO_" to anyhting we like and is new, can't we?
Option may remains the same (sts, lts)

@zero-24
Copy link
Contributor

zero-24 commented Dec 4, 2014

@infograf768

If I understand well, we can change "COM_JOOMLAUPDATE_VIEW_DEFAULT_UPDATES_INFO_" to anyhting we like and is new, can't we?

hmm not so easy. Let me explain.

Current Joomla Installation has a Setup e.g. with the setting lts / sts

This result into the Language String (see: https://github.com/joomla/joomla-cms/blob/staging/administrator/components/com_joomlaupdate/views/default/tmpl/default.php#L14-16):
COM_JOOMLAUPDATE_VIEW_DEFAULT_UPDATES_INFO_LTS or
COM_JOOMLAUPDATE_VIEW_DEFAULT_UPDATES_INFO_STS

If we add a language string for All/ Current or Major/Minor we can't use it as we have here:
https://github.com/joomla/joomla-cms/blob/staging/administrator/components/com_joomlaupdate/config.xml#L16-18

Only lts and sts and IIRC we can't Change this until 4.x for B/C

So sure we can add the strings but we never us it with the current code. (That is the reason why the *LTS and *STS strings are the same as the *Major and *Minor strings)

If we want to use it we need here: https://github.com/joomla/joomla-cms/blob/staging/administrator/components/com_joomlaupdate/views/default/tmpl/default.php#L14-16

Somthing like:

$updateOption = strtoupper($params->get('updatesource', 'lts')); 

if ($updateOption == 'LTS')
{
          $updateOption = 'CURRENT';
}
elseif ($updateOption == 'STS')
{
          $updateOption = 'ALL';
}
$langKey          = 'COM_JOOMLAUPDATE_VIEW_DEFAULT_UPDATES_INFO_' . $updateOption; 
$updateSourceKey  = JText::_('COM_JOOMLAUPDATE_CONFIG_UPDATESOURCE_' . $updateOption); 

This would also solove the current issue with
You are connected to the **Long Term Support (recommended)** update stream - This stream is designed for the current major release and provides all minor and patch updates of your version until the support for your version ends.

And convert them to
You are connected to the **Current Minor and patch Release** update stream - This stream is designed for the current major release and provides all minor and patch updates of your version until the support for your version ends.

@smanzi
Copy link
Author

smanzi commented Dec 4, 2014

Hello everybody!
I've looked at the code and now understand what the fuss is about: it all comes from the fact that we are building the language keys by a string concatenation of a base string and $updateOption.

As elegant as this can be, I think that by simply substituting that code with a switch($updateOption) {} block will solve this issue.

As far as regards the parameter values 'lts' and 'sts' there is not much we can do as they are stored as is (i.e. strings) and not numeric values as I expected. Unless we want to introduce some code to update the configuration we must live with those and call it a day... No big deal: only coders will see those and we can add a comment clarifying what their mean is in today context.

On the contrary I think that the language constant names have far more relevance as not only coders but translators too will be exposed to those names. For this reason I am strongly against the usage of terms containing "_MINOR" and "_MAJOR": a lesser skilled translator can misunderstand their significance and think that "_MINOR" means "will be updated to every version, even the minor ones (and of course the major ones!)" and "_MAJOR" means "will be updated only when a major release is available (and to the hell the minor ones!)" I think this can be an easy misunderstanding... we don't have to think with a "coder head" in those circumstances: translators (and end users) may don't know about semantic versioning!

One more (important) thing that I really don't understand is the 'nochange' value, whose description is:

COM_JOOMLAUPDATE_CONFIG_UPDATESOURCE_NOCHANGE="Currently configured (no change)"

if you choose that option, then you are told that: "You are not connected to an update stream and will not recieve updates. This setting will compromise the security of your site." I'm pretty sure there is something wrong with that!!

JM, may I give a try to fix all of the above and push a PR?

@smanzi
Copy link
Author

smanzi commented Dec 4, 2014

One more consideration: does it really makes any sense to propose now the option of an automatic update to a version which so far away and if automatically applied will likely send a site belly up and maybe find us in court defending in a civil cause (we will probably win, but anyway...)?

@smanzi
Copy link
Author

smanzi commented Dec 4, 2014

Please, also have a look at this (it comes from a message posted in joomla-dev-cms Google Group):

Under the update component. I've set the update source to "LTS". So I guess the source should offe 3.x then and not 2.5. This should be changed in 2.5.

I have to select STS to update to 3.x

-Vegard

@smanzi
Copy link
Author

smanzi commented Dec 4, 2014

About the "nochange" option, it seems that this is really broken and with a broken logic behind it:

  • The string "You are not connected to an update stream and will not recieve updates. This setting will compromise the security of your site." is wrong and misleading: actually you are still connected to the previously chosen update channel (or stream, whatever)
  • You don't know and can't know what that channel/stream is (unless you peek into the DB)
  • Having a "Do not change" option in a dropdown list is... incredible! A choice is a choice and it can't be a non-choice: "Cancel" buttons are here for that.
  • What is missing is an option for not receiving updates at all, but I think this is not needed now that we have the possibility to disable the Update Server itself.

Therefore, I propose to equate that "nochange" option to the default update channel (safer choice).

I'm preparing a PR... please hold on...

smanzi pushed a commit to smz/joomla-cms that referenced this issue Dec 4, 2014
This fixes issues raised in joomla#5308
@smanzi
Copy link
Author

smanzi commented Dec 4, 2014

We have PR #5324 - Tested for B/C

Strings are still preliminary and subjected to approval

@jissues-bot
Copy link

Set to "closed" on behalf of @zero-24 by The JTracker Application at issues.joomla.org/joomla-cms/5308

@zero-24
Copy link
Contributor

zero-24 commented Dec 4, 2014

closing since we have a PR here: #5324

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants