File tree Expand file tree Collapse file tree 3 files changed +4
-4
lines changed Expand file tree Collapse file tree 3 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -45,7 +45,7 @@ def _try_to_create_lock_file(self):
4545 timeout_end = current_time () + timeout
4646 while timeout_end > current_time ():
4747 try :
48- with open (self ._lockpath , 'x' ):
48+ with open (self ._lockpath , 'x' ): # pylint: disable=unspecified-encoding
4949 return True
5050 except ValueError : # This needs to be the first clause, for Python 2 to hit it
5151 logger .warning ("Python 2 does not support atomic creation of file" )
Original file line number Diff line number Diff line change @@ -113,14 +113,14 @@ def __init__(self, location):
113113 def save (self , content ):
114114 # type: (str) -> None
115115 """Save the content into this persistence"""
116- with open (self ._location , 'w+' ) as handle :
116+ with open (self ._location , 'w+' ) as handle : # pylint: disable=unspecified-encoding
117117 handle .write (content )
118118
119119 def load (self ):
120120 # type: () -> str
121121 """Load content from this persistence"""
122122 try :
123- with open (self ._location , 'r' ) as handle :
123+ with open (self ._location , 'r' ) as handle : # pylint: disable=unspecified-encoding
124124 return handle .read ()
125125 except EnvironmentError as exp : # EnvironmentError in Py 2.7 works across platform
126126 if exp .errno == errno .ENOENT :
Original file line number Diff line number Diff line change @@ -70,7 +70,7 @@ def protect(self, message):
7070
7171 if _CRYPT_PROTECT_DATA (
7272 ctypes .byref (message_blob ),
73- u"python_data" ,
73+ u"python_data" , # pylint: disable=redundant-u-string-prefix
7474 entropy ,
7575 None ,
7676 None ,
You can’t perform that action at this time.
0 commit comments