#3850 Inherit group permissions
Merged by tkopecek. Opened by tkopecek.
tkopecek/koji permgroups  into  master

Download 3850.patch

Related: https://pagure.io/koji/issue/3849

I wonder if we should exclude admin, or possibly others based on a flag or similar.

I think grantPermission and revokePermission will need some updates to their sanity checks.

I'm wondering if the JOIN in the new perms query needs to be a left join

Also, I'm thinking admins will need an easy way to figure out exactly where inherited perms are coming. This would likely require a new option to provide without breaking the getUserPerms api

rebased onto fd4607cfc7466cfda1cbcc9b6a5284297e362a5c

1) I would handle them in same way just for the comprehensibility.
2) fixed
3) fixed
4) Do you mean new option for getUserPerms (extending to get_user_perms returning [{'name': 'admin', 'id': 1, 'source': None/group_id}] or new call?

My concern is this makes it too easy to grant admin to a very large group of people with a single erroneous command

Do you mean new option for getUserPerms (extending to get_user_perms returning [{'name': 'admin', 'id': 1, 'source': None/group_id}] or new call?

I could go either way on this. Main thing is not to duplicate the underlying query code. We have a tendency to introduce options and polymorphism, but I suppose a new call might be a little cleaner looking.

rebased onto 4c09e1360c81f0fce30b075db0adea9faaf45248

We're still duplicating the query code. When I wrote the above, I'd kind of envisioned having a single query call that returns the greater detail and have get_user_perms be a compat wrapper for that call

rebased onto b1b41ac872b9bbf72e8b5f5e483bdab9bf63ed9b

:thumbsup:

Metadata Update from @tkopecek:
- Pull-request tagged with: testing-ready

rebased onto 7b8643889f05044743a7abec398a96c3eb1d2397

Metadata Update from @relias-redhat:
- Pull-request tagged with: testing-done

Commit 7f8c75d9 fixes this pull-request

Pull-Request has been merged by tkopecek

Metadata