def grains():
    '''
    Get the grains from the proxied device
    '''
    if not DETAILS.get('grains_cache', {}):
        DETAILS['grains_cache'] = GRAINS_CACHE
        try:
            DETAILS['grains_cache'] = _get_grain_information()
        except salt.exceptions.CommandExecutionError:
            pass
        except Exception as err:
            log.error(err)
    return DETAILS['grains_cache']
def grains ( ) : if not DETAILS . get ( 'grains_cache' , { } ) : DETAILS [ 'grains_cache' ] = GRAINS_CACHE try : DETAILS [ 'grains_cache' ] = _get_grain_information ( ) except salt . exceptions . CommandExecutionError : pass except Exception as err : log . error ( err ) return DETAILS [ 'grains_cache' ]
Get the grains from the proxied device