def load_overrides(file_path, loaded_config=config):
 with open(file_path) as data_file:
  try:
   overrides = json.load(data_file)
  except ValueError:
   sys.exit('Failed parsing configuration file at {}'.format(file_path))
  if (not overrides):
   log.debug('No config overrides found.')
   return
  assert isinstance(overrides, dict), 'overrides must be dictionary'
  loaded_config.update(overrides)
  log.debug('Imported config overrides {}'.format(overrides.keys()))

def load_overrides ( file_path , loaded_config = config ) : with open ( file_path ) as data_file : try : overrides = json . load ( data_file ) except ValueError : sys . exit ( 'Failed parsing configuration file at {}' . format ( file_path ) ) if ( not overrides ) : log . debug ( 'No config overrides found.' ) return assert isinstance ( overrides , dict ) , 'overrides must be dictionary' loaded_config . update ( overrides ) log . debug ( 'Imported config overrides {}' . format ( overrides . keys ( ) ) )
convenience function for overriding default configuration .