Skip to content

Commit df182fd

Browse files
itssimonshin-
authored andcommitted
Change os.errno to errno for py3.7 compatibility
Signed-off-by: Simon Gurcke <[email protected]>
1 parent 4a8a86e commit df182fd

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

docker/credentials/store.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1+
import errno
12
import json
2-
import os
33
import subprocess
44

55
import six
@@ -84,15 +84,15 @@ def _execute(self, subcmd, data_input):
8484
[self.exe, subcmd], stdin=subprocess.PIPE,
8585
stdout=subprocess.PIPE, env=env,
8686
)
87-
output, err = process.communicate(data_input)
87+
output, _ = process.communicate(data_input)
8888
if process.returncode != 0:
8989
raise subprocess.CalledProcessError(
9090
returncode=process.returncode, cmd='', output=output
9191
)
9292
except subprocess.CalledProcessError as e:
9393
raise errors.process_store_error(e, self.program)
9494
except OSError as e:
95-
if e.errno == os.errno.ENOENT:
95+
if e.errno == errno.ENOENT:
9696
raise errors.StoreError(
9797
'{} not installed or not available in PATH'.format(
9898
self.program

0 commit comments

Comments
 (0)