Problem/Motivation
A non-Drupal user notes concerning language regarding module updates:
On the Home >> Administer >> Site building page, there's a real need for the present subjunctive.
It now says "It is important that update.php is run every time a module is updated to a newer version." That means "The following fact is important: update.php is run [ambiguous passive-tense statement] every time..."
If you want to say "You had better run it", change the "is" to a "be". Or just rephrase the whole line.
Proposed resolution
Ticket author noted:
Drupal knows when update.php needs to be run, so instead of just announcing the important fact that update.php needs to be run at the right time, it could not display the message at all when update.php does not need to be run and say "You need to run update.php right now because you upgraded modules X, Y, and Z" when it does need to be run.
Remaining tasks
We need to agree on the appropriate language for this notice.
API changes
As the patch has changes in text, any translations will need to be redone.
Screenshots
Update disabled
Before:
After:
Update enabled
Before:
After:
Comment | File | Size | Author |
---|---|---|---|
#26 | disabled-after.png | 62.96 KB | John Cook |
#26 | disabled-before.png | 61.77 KB | John Cook |
#26 | enabled.after_.png | 62.47 KB | John Cook |
#26 | enabled-before.png | 62.69 KB | John Cook |
#23 | update-notice-477356-23.patch | 3.23 KB | Screenack |
Comments
Comment #1
bjaspan CreditAttribution: bjaspan commentedTagging.
Comment #2
yoroy CreditAttribution: yoroy commentedActive and specific wording is always good.
"Update to apply the upgrades of modules X, Y, and Z."
Not great yet, but trying to get the "you put the new module files in place but you're not finished yet" in there.
Comment #3
brianV CreditAttribution: brianV commentedPerhaps the following is better. In addition to more specific language, it also makes the user aware of the consequences of *not* running update.php.
'You must run update.php every time a module is upgraded to complete the upgrade. Failure to do so may result in broken modules.'
What may be best, from a usability perspective, would be to store the installed module version in the system table. When loading the module page, check if the version in the .info file is greater than the version stored in the system table. If this is the case, it indicates that a new version has been uploaded to the site, in which case we would display this using a drupal_set_message() warning.
Hmmm... I'd like some feedback on this idea. If it has a positive reception, I will implement it.
Comment #4
yoroy CreditAttribution: yoroy commentedI'd like to hear which approach would bjaspan's friend help best. I think suggestion in #3 removes the part that explicitily "now" is the time you update etc.
Comment #5
birdmanx35 CreditAttribution: birdmanx35 commentedI endorse #3.
Comment #7
dbeall CreditAttribution: dbeall commentedProposed in #3:
Maybe add a little why do we do it:
EDIT: I removed the first person as is in the handbook guidelines but keep the importance or urgency of the update action.
Comment #8
dbeall CreditAttribution: dbeall commentedshouldn't this be task?
Comment #9
brianV CreditAttribution: brianV commentedPatch attached to modify the wording. New wording is:
The bolding is to help show which portions have changed from the current text. The current text (for comparison's sake) is:
Comment #10
brianV CreditAttribution: brianV commentedComment #11
yoroy CreditAttribution: yoroy commented"You must", "Failure to do so"… This is turning into very condescending language. As important as it is to run update.php, Drupal should not have to use this tone of voice to get the point across. Adding more words is not the way to convince people either. People don't read, they scan. Strategy should be to put the most important part first, use simple language and omit needless words.
I propose:
Run update.php each time a module is updated. It updates the database and prevents errors or broken modules. Use the Update status module to recieve information about new versions of modules and themes. Review the available updates regularly to keep your site current and secure.
Comment #12
dbeall CreditAttribution: dbeall commentedagree, sounds friendly and has added information.
I am not much on structured grammar..
Just a thought, Maybe condense it:
Run update.php each time a module is updated to update the database, prevent errors and broken modules.
Edit, that's not right, maybe:
Run update.php each time a module is updated to prevent errors, broken modules and update the database.
there just isn't a shorter way of saying it, thinking about the idea of people scanning instead of reading.
Comment #13
dbeall CreditAttribution: dbeall commentedunless, maybe taking out the broken part..
Run update.php each time a module is updated to prevent errors and update the database.
Comment #14
dbeall CreditAttribution: dbeall commentedDon't why i just keep getting ideas..
Run update.php each time a module is updated to prevent errors, update modules and the database.
it's up to you folks, I appreciate being able to participate. Drupal Rocks!
Comment #16
Tor Arne Thune CreditAttribution: Tor Arne Thune commentedStill a valid issue. Moving to 8.x, as no new UX changes will be committed to 7.x. See attached screenshot or the text below for the text displayed on admin/modules in 7.0.
Comment #18
Screenack CreditAttribution: Screenack as a volunteer commentedAs part of the DrupalCon 2016 Mentored sprint, I am reviewing this ticket.
Comment #19
Screenack CreditAttribution: Screenack as a volunteer and commentedThe language essentially the same after this 5-year old comment;
My simple recommendation: change: "Always run the update script each time a module is updated." to "Always run the update script every time you update any module."
Comment #20
eporama CreditAttribution: eporama as a volunteer and at Acquia commentedThere are three places in code where this happens, once in
system.module
and twice inupdate.module
.In checking the Content Style Guide and other samples of text, especially in the
system_help()
the voice change does seem appropriate. I am attaching a patch for reviewing that makes the currently proposed changes so we have something to test and alter.I am not including an interdiff because the text has changed dramatically from the previous patches due to changes from other issues.
Comment #21
eporama CreditAttribution: eporama as a volunteer and at Acquia commentedAs another point, many important actions are modified with "should" and I was wondering if "must" might be a more appropriate term for this. As an example, "must" is used only once in system_help to describe the need to run cron regularly:
(emphasis added by me for demonstration).
The issue with changing to "must" is that there are, of course, instances when running update.php is not necessary (i.e., no modules made hook_update_n changes). In that case, running update.php does not cause problems, it will simply tell you that there are no updates to process. This makes me wonder what folks think of:
While it is not absolutely necessary, it is quite important for the script to run if there actually are updates and I could see that the emphasis could be more important than the technical outliers.
Comment #22
Screenack CreditAttribution: Screenack as a volunteer and at Duke University commentedI made my patches against 8.2.x-dev, as the language is still present in this branch.
Comment #23
Screenack CreditAttribution: Screenack as a volunteer and at Duke University commentedI do not wish to step on eporama's fine work, but I do wish to submit my patch, if for academic purposes. I've read eporama's commit, and I prefer the language in that commit.
Comment #24
eporama CreditAttribution: eporama as a volunteer and at Acquia commented@screenack, thanks for continuing the work! I didn't realize you were looking to complete the patch process, so wanted to make sure your work was testable and committable. Our patches don't differ from what I can see (for anyone else reviewing this), so no disagreement here.
Comment #26
John Cook CreditAttribution: John Cook commentedI've checked the patch and ensured that text is changed where appropriate. Screenshots have been added.
This will break translations as existing text is being changed.
Comment #27
John Cook CreditAttribution: John Cook commentedComment #30
eporama CreditAttribution: eporama as a volunteer and at Acquia commentedBtw, the test failures appear to be a by product of #2724871: Random failure in \Drupal\migrate_drupal_ui\Tests\d7\MigrateUpgrade7Test