Fixed PLW1514 (unspecified-encoding): open in text mode without explicit encoding argument

This commit is contained in:
Teal Dulcet
2024-03-10 07:56:49 -04:00
committed by Joshua Tauberer
parent a02b59d4e4
commit 0e9193651d
12 changed files with 44 additions and 44 deletions
+1 -1
View File
@@ -47,7 +47,7 @@ def read_password():
return first
def setup_key_auth(mgmt_uri):
with open('/var/lib/mailinabox/api.key') as f:
with open('/var/lib/mailinabox/api.key', encoding='utf-8') as f:
key = f.read().strip()
auth_handler = urllib.request.HTTPBasicAuthHandler()