Add 'status report' for installer requirements
| Project: | Drupal |
| Version: | 7.x-dev |
| Component: | usability |
| Category: | bug report |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | closed |
Compare these screenshots:



If you thought those last two were the same image, look again ;)
The status report gives you a nice friendly indication that certain things are working, notices for things you might want to look at, and warnings for things that are critical.
The installer gives you a big block of red text, that changes a couple of words, removes one block, maybe adds a different block until you get it right.
I'd be nice to replace all the drupal_set_message() with almost exactly the same presentation as admin/reports/status - that way, new users get immediate positive feedback that /something/ is working, and a nice green tick every time they change a permission or create a files folder or whatever.
Haven't yet looked to see how much of this is a presentation issue, or how much it'd require reworking. Afaik there's been no usability testing of the installer as yet - but this seems like an easy win.
| Attachment | Size | Status | Test result | Operations |
|---|---|---|---|---|
| status-report.png | 27.47 KB | Ignored | None | None |
| installer.png | 17.64 KB | Ignored | None | None |
| installer2.png | 17.33 KB | Ignored | None | None |

#1
Here is a patch. Works fine for me, but should probably be reviewed by someone else.
#2
Not tested, but small typo found :
$requirements['config file permissions']
#3
Some reviews to the above patch:
- Note that
drupal_verify_profilecan also set error messages and the patch is not including them in the report.- It uses hardcoded numbers instead of the constant
REQUIREMENT_ERROR.Does not seem to be a good idea to print and exit at
install_check_requirements, I suggest to return an array of requirements and process all the collected requirements later. The same for thedrupal_verify_profile.The attached patch implements it in this way. It introduces a new function
drupal_profile_modulesthat returns a list of modules required by a given profile and leftdrupal_verify_profileto verify the existence of the required modules. In consequence, simpletest should use this function as well. Both,install_check_requirementsanddrupal_verify_profilereturn an array of 'requirements'. The severity is checked and if there is a requirement error, a status report is displayed.See attached screenshot, it happens when trying to install a profile that requires the views module but it was not found.
#4
This looks great!
Couple of minor issues in the patch though. It removes the @drupal placeholder in messages so install profiles can't insert their own name. Also, there's a missing space here:
needs write permissions to') . $file#5
Here is a update that fixes the two issues mentioned by catch.
#6
Those changes look good. I also re-tested with 'views' added to the required modules and that works well too.
This could do with another set of eyes on it before being marked RTBC, but otherwise seems ready to go.
#7
Except 'missing' is spelt 'mising' in the patch.
#8
Darn! Ok. Here it is once again.
#9
We don't write "Config File Permission", we write "Settings file permission". ;-)
Also, the patch no longer applies to CVS HEAD. Can you try to reroll?
#10
Here is a patch rerolled against HEAD and fixing the message issue reported by Dries.
Also, other screen shoots where you can see how it looks like.

#11
The patch still applies cleanly.
#12
This is interesting. Subscribing.
#13
Re-rolled for offset/fuzz/trailing whitespace.
#14
The patch looks good. I have tested again and with other profiles with required modules and is working as expected. In this patch I am adding the
admin.cssthat got removed by mistake in one of the above patches. That CSS file is required to show the icons in the report table.As far as I can see, it is RTBC.
#15
Didn't apply to HEAD anymore. Rerolling
#16
Less code, more pretty, tested with various combinations of incorrect permissions/missing files. This is ready.
#17
Looks good to me as well. Tested with PDO unavailable, resulting in a fatal error, this requirement must be included later in the same way the requirements are handled in this patch (#299308: Add PDO to installation requirements)
#18
I think it looks good, I havn't been able to apply the patch myself but reviewing from the pictures. The contrast seems good, however is the red text(to highlight the required modules) we use accessible for those who have color disabilities / those in a hurry rushing over the page.
I like how you fixed the alignment and added space/indent, it made it completely more readable.
#19
Here is an online color contrast checker: http://snook.ca/technical/colour_contrast/colour.html
Red text is #FF0000, background is #FFCCCC. The color difference is too low. A text color of #A30000 would do. (Too me it's easier on the eye too.)
BTW this is set in admin.css
#20
There's an existing issue for colour contrast/accessibility here #8082: DROP Task: Improve accessibility of forms and messages.
#21
The missing modules are themed using the CCS class
.admin-missingfrom modules/system/admin.css, so the contrast/accessibility of the messages is other issue that should not block this one.#22
webchick asked for the settings file messages to be split into two in irc, I have to go out in a minute so this hasn't been tested extensively, but it ought to do it. If possible I'd love this change to go in before UNSTABLE-1 gets tagged so we can test it out on 'real people', so reviews welcome.
#23
This patch actually works.
#24
Last patch applies cleanly and works as expected. RTBC as far as I can see.
Attached another screen shot showing the last changes.
#25
Ok, well. ;) We don't need the thing about the settings permission there twice. Please re-word the first error so it's only about copying the file.
I'm going to try and give this a thorough "webchick" review in a couple of hours, so if you want to hold off until then that's cool.
#26
Sorry, ran out of steam for tonight ;( Will try again about 20 hours from now.
#27
Reworded these so they only deal with one thing each. This means we have two 'Settings file' headings, one of which can have a tick, one an x, which isn't ideal. However, if possible it'd be nice to postpone any further textual changes to a followup patch, since this one is really only concerned with conversion from drupal_set_message() to the status report layout.
#28
The internets is broken :(
#29
changes via webchick in irc.
#30
forgot one.
#31
http://drupal.org/cvs?commit=143643
#32
Automatically closed -- issue fixed for two weeks with no activity.