I suspect this is a duplicate bug report, but I searched and couldn't find anything, so I'm submitting this...
I just noticed on a new D7 test site I'm building that the order of things at admin/modules is somewhat non-deterministic. It appears that we start with a completely alphabetized list of module names, and as we process them, we stick them into buckets for each "Package" they belong to. But the resulting Package buckets remain in whatever order we defined them in, the packages themselves are not sorted, and therefore the package groupings are non-deterministic on the admin/modules page as you add new modules. Some examples to reproduce and see this in action:
A) Start with core. Then add http://drupal.org/project/advanced_help -- since "advanced_help" is earlier in the alphabet than "aggregator", you'll now have your "Other" package listed above "Core".
B) Install both http://drupal.org/project/cvs_deploy and http://drupal.org/project/group -- since "CVS" is earlier than "group" in the alphabet, your order of packages will be Core, Other, Group
It seems like we should really sort the package fieldsets themselves by name, so that you get consistent ordering, regardless of the module names on your site.
| Comment | File | Size | Author |
|---|---|---|---|
| #2 | 810484.patch | 595 bytes | Nick Lewis |
Comments
Comment #1
Nick Lewis commentedYeah you're right. And this is a regression... *I think* ... D6 has package alphabetizing correct... well, except for case tracker vs cck... (don't even want to know).
Pretty sure i got this one figured out.
In D7 the order is governed by the order of this array and how the formapi eventually *deals* with it. http://api.drupal.org/api/function/system_modules/7 (system.admin.inc line 933)
What's missing was a little thing that a seemingly killed theme function did in d6 http://api.drupal.org/api/function/theme_system_modules/6
That ksort right there is all that appears to be missing. The question is what impact ksort would have on a form array - given that this is merely a theme function... if you don't hear back from me, it means it wasn't good.
Comment #2
Nick Lewis commentedNothing appears to have blown up. Lets see what testbot thinks.
Comment #3
damien tournoud commentedThis is a duplicate of #800502: Module page is not ordered correctly.
Comment #4
Nick Lewis commented@dww yeah about search... lol :-D