#NEWLINE# def _GetEnviron( self , name ) : #NEWLINE# #INDENT# 'Helper method ensures environment configured as expected.\n\n    Args:\n      name: Name of environment variable to get.\n\n    Returns:\n      Environment variable associated with name.\n\n    Raises:\n      ConfigurationError if required environment variable is not found.\n    ' #NEWLINE# try : #NEWLINE# #INDENT# return os . environ [ name ] #NEWLINE# #UNINDENT# except KeyError : #NEWLINE# #INDENT# raise ConfigurationError ( ( '%s is not set in environment.' % name ) )