@@ -201,7 +201,7 @@ def __init__(self, hostname, login=None, password=None, timeout=60, port=443, pr
201201 self .hponcfg = "/sbin/hponcfg"
202202 hponcfg = 'hponcfg'
203203 if platform .system () == 'Windows' :
204- self .hponcfg = 'C:\Program Files\HP Lights-Out Configuration Utility\cpqlocfg.exe'
204+ self .hponcfg = r 'C:\Program Files\HP Lights-Out Configuration Utility\cpqlocfg.exe'
205205 hponcfg = 'cpqlocfg.exe'
206206 for path in os .environ .get ('PATH' ,'' ).split (os .pathsep ):
207207 maybe = os .path .join (path , hponcfg )
@@ -333,7 +333,7 @@ def _upload_file(self, filename, progress):
333333 body = re .search ('<body>(.*)</body>' , data , flags = re .DOTALL ).group (1 )
334334 body = re .sub ('<[^>]*>' , '' , body ).strip ()
335335 body = re .sub ('Return to last page' , '' , body ).strip ()
336- body = re .sub ('\s+' , ' ' , body ).strip ()
336+ body = re .sub (r '\s+' , ' ' , body ).strip ()
337337 raise IloError (body )
338338 self .cookie = re .search ('Set-Cookie: *(.*)' , data ).group (1 )
339339 self ._debug (2 , "Cookie: %s" % self .cookie )
@@ -429,7 +429,7 @@ def _communicate(self, xml, protocol, progress=None, save=True):
429429 if self .protocol != ILO_LOCAL :
430430 sock .write (self .XML_HEADER )
431431 if b'$EMBED' in xml :
432- pre , name , post = re .compile (b '(.*)\$EMBED:(.*)\$(.*)' , re .DOTALL ).match (xml ).groups ()
432+ pre , name , post = re .compile (rb '(.*)\$EMBED:(.*)\$(.*)' , re .DOTALL ).match (xml ).groups ()
433433 sock .write (pre )
434434 sent = 0
435435 fwlen = os .path .getsize (name )
0 commit comments