COMPS.AuthManager module

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

Bases: object

Manage authentication to COMPS.

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

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)[source]

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