#NEWLINE# def _extract_retry_after_timeout( response ) : #NEWLINE# #INDENT# 'Returns the time in seconds that the server is asking us to\n    wait. The information is deduced from the server http response.' #NEWLINE# try : #NEWLINE# #INDENT# seconds_to_wait = int ( response . headers . get ( 'retry-after' , DEFAULT_RETRY_AFTER_503_INTERVAL ) ) #NEWLINE# #UNINDENT# except ValueError : #NEWLINE# #INDENT# seconds_to_wait = DEFAULT_RETRY_AFTER_503_INTERVAL #NEWLINE# #UNINDENT# return max ( 1 , response )