Add 'status report' for installer requirements

catch - July 11, 2008 - 15:53
Project:Drupal
Version:7.x-dev
Component:usability
Category:bug report
Priority:normal
Assigned:Unassigned
Status:closed
Description

Compare these screenshots:

status-report

installer

installer again

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.

AttachmentSizeStatusTest resultOperations
status-report.png27.47 KBIgnoredNoneNone
installer.png17.64 KBIgnoredNoneNone
installer2.png17.33 KBIgnoredNoneNone

#1

xqus - July 12, 2008 - 19:54
Status:active» needs review

Here is a patch. Works fine for me, but should probably be reviewed by someone else.

AttachmentSizeStatusTest resultOperations
drupal-281446.txt4.65 KBIgnoredNoneNone

#2

lilou - July 12, 2008 - 21:37
Status:needs review» needs work

Not tested, but small typo found :

$requirements['config file permissions']

#3

dropcube - July 12, 2008 - 22:15
Status:needs work» needs review

Some reviews to the above patch:

- Note that drupal_verify_profile can 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 the drupal_verify_profile.

The attached patch implements it in this way. It introduces a new function drupal_profile_modules that returns a list of modules required by a given profile and left drupal_verify_profile to verify the existence of the required modules. In consequence, simpletest should use this function as well. Both, install_check_requirements and drupal_verify_profile return 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.

AttachmentSizeStatusTest resultOperations
requirements-problems.png41 KBIgnoredNoneNone
installer-status-report-281446.patch8.86 KBIgnoredNoneNone

#4

catch - July 17, 2008 - 09:06
Status:needs review» needs work

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

xqus - July 17, 2008 - 14:25
Status:needs work» needs review

Here is a update that fixes the two issues mentioned by catch.

AttachmentSizeStatusTest resultOperations
drupal-281446.txt8.98 KBIgnoredNoneNone

#6

catch - July 17, 2008 - 14:34

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

catch - July 17, 2008 - 14:40
Status:needs review» needs work

Except 'missing' is spelt 'mising' in the patch.

#8

xqus - July 17, 2008 - 14:55
Status:needs work» needs review

Darn! Ok. Here it is once again.

AttachmentSizeStatusTest resultOperations
drupal-281446.patch8.98 KBIgnoredNoneNone

#9

Dries - July 19, 2008 - 12:55

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

dropcube - July 19, 2008 - 16:22

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.

AttachmentSizeStatusTest resultOperations
installer-status-report-281446-10.patch9.37 KBIgnoredNoneNone
requirements-problems-2.png40.67 KBIgnoredNoneNone

#11

dropcube - July 29, 2008 - 13:18

The patch still applies cleanly.

#12

webchick - September 4, 2008 - 20:57

This is interesting. Subscribing.

#13

catch - September 4, 2008 - 21:46
Component:install system» usability

Re-rolled for offset/fuzz/trailing whitespace.

AttachmentSizeStatusTest resultOperations
installer_status_report.patch9.4 KBIgnoredNoneNone

#14

dropcube - September 4, 2008 - 23:39

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.css that 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.

AttachmentSizeStatusTest resultOperations
installer-status-report-281446-14.patch10.36 KBIgnoredNoneNone

#15

meba - September 27, 2008 - 08:20

Didn't apply to HEAD anymore. Rerolling

AttachmentSizeStatusTest resultOperations
installer-status-report-2008-09-27.patch10.08 KBIgnoredNoneNone

#16

catch - September 27, 2008 - 08:42
Status:needs review» reviewed & tested by the community

Less code, more pretty, tested with various combinations of incorrect permissions/missing files. This is ready.

#17

dropcube - September 27, 2008 - 13:47

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

Bojhan - September 28, 2008 - 12:34

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

gaele - September 29, 2008 - 10:03

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

catch - September 29, 2008 - 10:31

There's an existing issue for colour contrast/accessibility here #8082: DROP Task: Improve accessibility of forms and messages.

#21

dropcube - September 29, 2008 - 12:52

The missing modules are themed using the CCS class .admin-missing from modules/system/admin.css, so the contrast/accessibility of the messages is other issue that should not block this one.

#22

catch - September 29, 2008 - 17:25
Status:reviewed & tested by the community» needs review

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.

AttachmentSizeStatusTest resultOperations
installer_status_report.patch10.12 KBIgnoredNoneNone

#23

catch - September 29, 2008 - 17:53

This patch actually works.

AttachmentSizeStatusTest resultOperations
installer_status_report.patch10.16 KBIgnoredNoneNone

#24

dropcube - September 29, 2008 - 23:36
Status:needs review» reviewed & tested by the community

Last patch applies cleanly and works as expected. RTBC as far as I can see.

Attached another screen shot showing the last changes.

AttachmentSizeStatusTest resultOperations
settings-file-status-report.png61.86 KBIgnoredNoneNone

#25

webchick - September 29, 2008 - 23:58
Status:reviewed & tested by the community» needs work

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

webchick - September 30, 2008 - 06:10

Sorry, ran out of steam for tonight ;( Will try again about 20 hours from now.

#27

catch - September 30, 2008 - 09:05
Status:needs work» needs review

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.

AttachmentSizeStatusTest resultOperations
installer_status_report.patch0 bytesIgnoredNoneNone

#28

catch - September 30, 2008 - 10:53

The internets is broken :(

AttachmentSizeStatusTest resultOperations
installer_status_report.patch10.35 KBIgnoredNoneNone

#29

catch - September 30, 2008 - 23:59

changes via webchick in irc.

AttachmentSizeStatusTest resultOperations
installer_status_report.patch10.4 KBIgnoredNoneNone

#30

catch - October 1, 2008 - 00:07

forgot one.

AttachmentSizeStatusTest resultOperations
installer_status_report.patch10.41 KBIgnoredNoneNone

#31

catch - October 1, 2008 - 00:36
Status:needs review» fixed

http://drupal.org/cvs?commit=143643

#32

Anonymous (not verified) - October 15, 2008 - 00:41
Status:fixed» closed

Automatically closed -- issue fixed for two weeks with no activity.

 
 

Drupal is a registered trademark of Dries Buytaert.