#NEWLINE# def get_status( host , path , file ) : #NEWLINE# #INDENT# try : #NEWLINE# #INDENT# conn = HTTPConnection ( host ) #NEWLINE# conn . request ( 'HEAD' , '/{0}/{1}' . format ( host , file ) ) #NEWLINE# res = conn . getresponse ( ) #NEWLINE# #UNINDENT# except ( HTTPException , socket . timeout , socket . error ) : #NEWLINE# #INDENT# return 0 #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# return res . status