ACL processing should terminate at the AppConfig
return the URL for the app config. project parameter is for optimization
Projects contain tools, subprojects, and their own metadata. They live in exactly one
Return a dict[project_id] = list of accolades, efficiently
Convenience method to add member with the given role(s).
Find all the users who have ‘Admin’ role for this project
Returns a dict of human-readable root troves => [categories]
Return a filename (configurable) for this project export. The current timestamp may be included, so only run this method once per export.
Returns ‘busy’ if an export is queued or in-progress. Returns None otherwise
SitemapEntrylist suitable for rendering the project navbar with tools grouped together by tool type.
Return a dict[project_id] = icon_url, efficiently
install_app(ep_name, mount_point=None, mount_label=None, ordinal=None, **override_options)¶
Install an app
Install many apps at once.
Better than doing individually if you expect default name conflicts (e.g. “code” for both git & svn), by using the tool_label value.
Parameters: apps_params (list) – list of dicts, where each dict is the args used in install_app()
Return a dict[project_id] = sitemap of sitemaps, efficiently
Return the ordinal of the next open toolbar mount point for this project.
Returns an array of a projects mounts (tools and sub-projects) in toolbar order. Note that the top-level ‘ordinal’ field may be offset from the stored ordinal value, due to anchored tools
ACL processing should proceed up the project hierarchy.
Return True if this project is private, else False.
Skip index update if only last_updated has changed.
Value of last_updated is updated whenever any artifact that belongs to project is changed. This generates a lot of unnecessary add_projects tasks for every simple user action.
sitemap(excluded_tools=None, included_tools=None, tools_only=False, per_tool_limit=10)¶
Return the project sitemap.
- excluded_tools (list) – Tool names (AppConfig.tool_name) to exclude from sitemap.
- included_tools (list) – Tool names (AppConfig.tool_name) to include. Use None to include all tool types.
- tools_only (bool) – Only include tools in the sitemap (exclude subprojects).
- per_tool_limit (int) – Max number of entries included in the sitemap for a single tool type. Use None to include all.
Find all the users who have named roles for this project
Return all users in this project that have at least one of the roles specified.
- e.g., project.users_with_role(‘Admin’, ‘Developer’) -> returns all
- users in project having the Admin role or the Developer role, or both