def find_mrjob_conf():
 def candidates():
  if ('MRJOB_CONF' in os.environ):
   (yield expand_path(os.environ['MRJOB_CONF']))
  (yield expand_path(os.path.join('~', '.mrjob.conf')))
  (yield '/etc/mrjob.conf')
 for path in candidates():
  log.debug(('Looking for configs in %s' % path))
  if os.path.exists(path):
   log.info(('Using configs in %s' % path))
   return path
 else:
  log.info('No configs found; falling back on auto-configuration')
  return None

def find_mrjob_conf ( ) : def candidates ( ) : if ( 'MRJOB_CONF' in os . environ ) : ( yield expand_path ( os . environ [ 'MRJOB_CONF' ] ) ) ( yield expand_path ( os . path . join ( '~' , '.mrjob.conf' ) ) ) ( yield '/etc/mrjob.conf' ) for path in candidates ( ) : log . debug ( ( 'Looking for configs in %s' % path ) ) if os . path . exists ( path ) : log . info ( ( 'Using configs in %s' % path ) ) return path else : log . info ( 'No configs found; falling back on auto-configuration' ) return None
look for :file:mrjob .