COMPS.AuthManager module

class COMPS.AuthManager.AuthManager(hoststring, verify_certs=False, credential_prompt=None)

Bases: object

Manage authentication to COMPS.

property username
property hoststring
property groups
property environments
has_auth_token()
get_auth_token()
clear_auth_token()
static get_environment_macros(environment_name)

Retrieve the environment macros for a COMPS environment.

This may be a somewhat temporary requirement until the Asset Service handles file dependencies more completely (allows uploads, etc).

Parameters

environment_name – the COMPS environment to retrieve macros for

Returns

a dictionary of environment macro key/value pairs

static get_group_name_for_environment(environment_name)

Retrieve the Group associated with a particular COMPS environment.

Parameters

environment_name – the COMPS environment to retrieve the Group for

Returns

a string of the Group name