@lru_cache()
def _get_firebase_db_url():
 regex = re.compile('\\bdatabaseURL\\b.*?["\\\']([^"\\\']+)')
 cwd = os.path.dirname(__file__)
 try:
  with open(os.path.join(cwd, 'templates', _FIREBASE_CONFIG)) as f:
   url = next((regex.search(line) for line in f if regex.search(line)))
 except StopIteration:
  raise ValueError('Error parsing databaseURL. Please copy Firebase web snippet into templates/{}'.format(_FIREBASE_CONFIG))
 return url.group(1)

@ lru_cache ( ) def _get_firebase_db_url ( ) : regex = re . compile ( '\\bdatabaseURL\\b.*?["\\\']([^"\\\']+)' ) cwd = os . path . dirname ( __file__ ) try : with open ( os . path . join ( cwd , 'templates' , _FIREBASE_CONFIG ) ) as f : url = next ( ( regex . search ( line ) for line in f if regex . search ( line ) ) ) except StopIteration : raise ValueError ( 'Error parsing databaseURL. Please copy Firebase web snippet into templates/{}' . format ( _FIREBASE_CONFIG ) ) return url . group ( 1 )
grabs the databaseurl from the firebase config snippet .