Since the switch to git, the link to all "committers" will include users who have a commit attributed via git commit --author, even though they cannot push commits themselves. Thus, there is no easy way to see who the actual maintainers are.

An easy and potentially useful solution would be to expose the maintainers tab to all users or based on an added permissions, but with the form disabled. That way any user could see the actual maintainers and who, for example, is able to make releases.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

dww’s picture

Yup, I'm down with this. Could be useful to see who's a maintainer and what per-project perms they have. This patch should probably introduce a new site-wide perm to control access to the tab.

The form and such lives in includes/project_maintainers.inc
obviously the menu item from project.module will need a little help, too (along with project_perm() itself).

Should be a relatively easy patch if anyone wants to work on it.

pwolanin’s picture

Status: Active » Needs review
FileSize
5.64 KB

untested, but simple, patch.

dww’s picture

Status: Needs review » Needs work
Issue tags: +Needs tests

Code looks great. Just missing a hunk for project.test to touch testProjectMaintainerPermissions and verify all this stuff works as expected. ;)

dww’s picture

FileSize
30.58 KB

Okay, code needs some help, too. It looks like the rows in the table for non-maintainers still have the extra column such that the column is wider than the header. Plus, for non-maintainers, there's a final empty dummy row. See attached screenie.

pwolanin’s picture

Status: Needs work » Needs review
FileSize
7.09 KB

this should at least fix the extra row at bottom.

pwolanin’s picture

does this fix the formatting?

dww’s picture

Status: Needs review » Needs work

Sorry, just now had a chance to look at this again. Yes, the empty row at the bottom is now gone. However, the rows still have an empty td for the operations column that doesn't exist.

dww’s picture

Ahh, b/c of a bug in theme_project_maintainers_form(). Here's a new patch that fixes it. Leaving needs work since we're still missing tests in here. Otherwise, I think this is pretty close.

pwolanin’s picture

What kind of tests would make sense?

miro_dietiker’s picture

I'd love to see project (maintainer) permissions exposed to all users.

Sometimes users/co-maintainers are confused (do i really have that permission?) or in case of incident you want to contact possibly responsible people.

Thank you guys for working on this.

Regarding those permissions, we even could show a readonly list on a user page where you can see the project permission table.
This time one project per list and the chosen users permissions on that specific project. This might still help to gain overview for administration, maintainer-requests / reputation, and information for the user itself about his current permission state.

dww’s picture

@miro_dietiker: That's a neat idea about having some page associated with each user's profile to show their per-project permissions on all projects. Please open a separate issue about that and reference this one. ;)

@pwolanin: Tests that ensure that the form elements are enabled for the right kinds of users, and disabled for everyone else. They should also ensure that the final row for adding new maintainers appears/disappears for the right people, along with the "Operations" column and links to delete a maintainer, etc. Given the sorts of bugs we hit while working on the patch, for extra credit it might also be slick to have a test verify that the table doesn't have empty columns for any rows. But that's definitely above-and-beyond what's needed to get this in.

Thanks all,
-Derek

miro_dietiker’s picture

pwolanin’s picture

What's the setup for writing or running project module tests? just stand-alone with simpletest?

dww’s picture

The test bot is enabled here. You just need to set this issue to needs review and the bot should fire. However, yeah, local simpletest is also good, since I think the bot is confused about some project* stuff (especially module dependencies) so often the bot cries failure when the code and tests are actually working. :/

pwolanin’s picture

I guess we still need a test?

dww’s picture

Yeah, I guess so. "Need" is maybe a strong word. ;) But, I'd rather have simpletests for this than someone's claim to have tested it thoroughly by hand.

Sorry this fell off my radar...

pwolanin’s picture

still need to get my head around how to test this....

mgifford’s picture

Version: 6.x-1.x-dev » 7.x-2.x-dev
Issue summary: View changes

Would be great if this patch were updated for D7 too.