def _extract_spreadsheet_key_from_url(url):
 result = url
 if ('key=' in url):
  result = url.split('key=')[(-1)].split('#')[0].split('&')[0]
 return result

def _extract_spreadsheet_key_from_url ( url ) : result = url if ( 'key=' in url ) : result = url . split ( 'key=' ) [ ( - 1 ) ] . split ( '#' ) [ 0 ] . split ( '&' ) [ 0 ] return result
extracts a key from a url in the form .