kojismokydingo.users¶
Koji Smoki Dingo - users and permissions
- author:
Christopher O'Brien <obriencj@gmail.com>
- license:
GPL v3
- collect_cg_access(session, user)[source]¶
List of content generators user has access to run CGImport with.
- Parameters:
- Raises:
NoSuchUser -- if user is an ID or name which cannot be resolved
- Since:
1.0
- Return type:
- collect_cgs(session, name=None)[source]¶
- Parameters:
name (str | None) -- only collect the given CG. Default, collect all
session (ClientSession)
- Raises:
NoSuchContentGenerator -- if name is specified and no content generator matches
- Since:
1.0
- Return type:
- collect_perminfo(session, permission)[source]¶
Gather information about a named permission, including the list of users granted the permission, as well as the date that the permission was granted and the user that granted it.
- Parameters:
- Raises:
NoSuchPermission -- if there is no matching permission found
- Since:
1.0
- Return type:
- collect_userinfo(session, user, stats=False, members=False)[source]¶
Gather information about a named user, including the list of permissions the user has.
Will convert the older
'krb_principal'
value (koji < 1.19) into a'krb_principals'
list (koji >= 1.19) to provide some level of uniformity.- Parameters:
- Raises:
NoSuchUser -- if user is an ID or name which cannot be resolved
- Since:
2.2
- Return type:
- collect_userstats(session, user)[source]¶
Collects user statistics into a dict
- Parameters:
- Raises:
NoSuchUser -- if user is an ID or name which cannot be resolved
- Since:
2.0
- Return type:
- get_group_members(session, user)[source]¶
An anonymous version of the admin-only
getGroupMembers
hub API call. UsesqueryHistory
to gather still-active group additions