Currently a lot of permission descriptions say the same as their titles, apart from some slight differences in word choice. This patch removes or changes a lot of redundant descriptions and clarifies titles, either by merging them with the descriptions or by applying some other minor changes, one of them is notably the change from "Access (...)" to "View (...)" or "Use (...)". View has been used for permissions that only allow users to view something, like content or Aggregator feeds. Use has been used for permissions that imply actions, like "Use site-wide contact form".
There are a few descriptions left, most of which warnings and notes. I am not sure if we can shorten or remove the "View printer-friendly books", "Administer image styles" and "Bypass content access control" descriptions.
| Comment | File | Size | Author |
|---|---|---|---|
| #18 | comment-post-permissions.png | 5.17 KB | sun |
| #12 | drupal.system-permission.patch | 725 bytes | sun |
| #8 | permissions_before.png | 797.21 KB | xano |
| #8 | permissions_after.png | 502.47 KB | xano |
| #8 | rewrite_permission_descriptions_03.patch | 29.82 KB | xano |
Comments
Comment #1
xanoNo screen shots, because it's a terribly long page, my laptop screen is very small and I have no way to stitch images here :P
Comment #2
seutje commentedthis is a big no-go, ur causing the 'Administer blocks' bit to be untranslatable
Comment #3
seutje commentedforgot status
Comment #4
xano/me headdesks like a ninja.
Comment #6
yoroy commentedhttps://addons.mozilla.org/nl/firefox/addon/1146 for full page screengrabs
Comment #7
xanoThanks for the tip. Submitting for retest because PHP errors don't usually pop up after five days.
Comment #8
xanoFollow-up patch. I also attached before and after screen shots. Note that the after screenshot is roughly 2000px shorter than the before screenshot.
Comment #9
whatdoesitwant commentedI have reviewed this patch. (In order to do so I activated all modules and used the dev version of devel to generate sufficient content).
I have doublechecked for language errors with focus on interpunction.
I have doublechecked for translation issues (see comment #2 by seutje).
I checked the functionality of the links:
- at line 143 (dashboard module).
- at line 636 (user module).
I checked the functionality of the taxonomy label.
The patch serves its purpose.
Comment #10
eigentor commentedgood work. A lot of the descriptions did not make sense and so it is good they are removed, and many are clarified a lot in the patch.
Comment #11
dries commentedCommitted to CVS HEAD. Thanks!
Comment #12
sunAward winning patch.
Comment #13
sunerrr.
Comment #14
dries commentedCommitted to CVS HEAD. Thanks. But alas, no award for this patch. Happy to give you an award for other patches though. ;-)
Comment #15
xanoNice catch, Sun!
Comment #16
David_Rothstein commentedThis is a big change that went in without much discussion. The original change, that is - not @sun's award-winning followup :)
It should be discussed more. While there are definitely some great changes in the patch, the overall result is a near-rollback of the permission descriptions, which were introduced in Drupal 7 for an important reason.
In addition, the actual effect of this patch is to make many of the permission titles longer, which seems backwards. The idea is supposed to be that the permission titles are very short because everyone is supposed to read them, whereas the descriptions are intended to be ignored except when the user needs to focus on and carefully understand that particular permission. We already have a "hide descriptions" link on the permissions page and other methods could be explored for themes to make them less prominent, so making the page shorter is not a good reason to remove them.
To take a couple examples from up near the top of the patch of why this is problematic:
These deletions are fine for experienced users, but for someone who is still shaky on what a "news feed" and "block" even are, they absolutely need some kind of extra text to remind them.
***
In addition, there are a few bugs here.
Seems like a copy-paste error: The "warning" text should not have been changed, since the security implications of this permission do not depend on any one particular text format.
There was a long discussion at #67234: Update script access rights of why it is appropriate to put "administer" in this permission name.
Also (not really caused by this patch), we need a new description here since it needs to be updated to reflect the way the update manager uses this permission to allow new modules to be uploaded to the site.
Comment #17
xanoMarking this a bug report because of the problems that have arisen.
- The main reason for using administer in the update permission title is to make clear it should only be given to site admins. However, the permission itself does not have to do with administering anything, but rather running/executing/performing it. This was why I chose for run instead of anything else. What about we keep Run software updates and add a warning in the description, just like we do with the other descriptions that may have security implications?
- I removed a lot of descriptions for administrative permissions because in general administrative permissions allow you to add, delete, configure and arrange stuff. They are 'super' permissions that allow you do to anything there is to do regarding the features described after the word Administer as opposed to more specific descriptions like Add new blocks (fictitious permission). Also, if we describe permissions in too much detail, this may not be correct anymore if contrib uses the same permissions for features it adds.
Comment #18
sunWTF?
If I wouldn't know that I can't, then I would only assign the one without approval. And even knowing the logic behind those labels, I took me a couple of seconds to understand what I want to do.
Comment #19
jeff124578 commentedIf the "Administer..." permissions are essentially meta-permissions -- that is, checking "Administer xyz" automatically checks each of "View xyz", "Post xyz", and "Edit xyz", then we really do need to include that fact in the permission descriptions.
To accomplish this,
Option 1 [easier]: Description for meta-permission "Administer xyz" should simply list which permissions it includes, similar to the initial patches here, but preferably with the conjunction "and" instead of "or".
e.g. "Add, edit, and delete news feeds that are aggregated to your site."
Where the Administer permission includes any permissions that subsume each other, list the least restrictive one.
e.g. "View and add comments to content (approval not required)."
Option 2: Just as the module listing page has "depends on" and "required by", add an extra tiny note to each permission that gets automatically checked (or unchecked) by an larger meta-permission. For example:
Administer comments and comment settings [x]
View comments [x] (included in "Administer comments and comment settings")
Ideally, checkboxes would never be disabled, but unchecking "View comments" would also automatically uncheck "Administer comments" while leaving "Post comments" checked.
Comment #20
xanoThe problem with option 1 is that module may reuse another module's permissions. I don't except things will get any simpler than they are now, but the page will surely get more cluttered.
Comment #21
Bojhan commentedThis is not critical.
Comment #22
amc commentedAll previous patches have been committed, and a rollback is under discussion but no patch yet...therefore setting to "active"
Comment #23
Stevel commented#16: 1 and 2 are changed in CVS HEAD. 3 is probably addressed as well by now, but if anyone feels a compelling need to grep the old permission names through core, please do.
#18: comment permissions are being addressed in #438224: "Post comments without approval" permission name is completely misleading, Administer software updates had gotten back in place already.
#19: hierarchical permissions for D8 are being discussed in #381584: Hierarchical Permissions System.
Therefore, setting this back to fixed. I suggest that a new issue is opened if there are more follow-ups needed.
Comment #25
xano