diff options
author | Milas Bowman <milas.bowman@docker.com> | 2022-08-12 09:43:20 -0400 |
---|---|---|
committer | Milas Bowman <milas.bowman@docker.com> | 2022-08-12 09:43:20 -0400 |
commit | 45bf9f9115e6a3a455d8cc947790b64f8c7101a7 (patch) | |
tree | 647785f265640afa192470390ee83e442808dfd8 /docker/utils/config.py | |
parent | 19171d0e1e81c1070f213a576e9a37ef0df1209d (diff) | |
parent | c03aeb659e2ac996aa69927e928b73d2979b9fce (diff) | |
download | docker-py-45bf9f9115e6a3a455d8cc947790b64f8c7101a7.tar.gz |
Merge remote-tracking branch 'upstream/main' into patch-1
Diffstat (limited to 'docker/utils/config.py')
-rw-r--r-- | docker/utils/config.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/docker/utils/config.py b/docker/utils/config.py index 82a0e2a..8e24959 100644 --- a/docker/utils/config.py +++ b/docker/utils/config.py @@ -18,11 +18,11 @@ def find_config_file(config_path=None): os.path.join(home_dir(), LEGACY_DOCKER_CONFIG_FILENAME), # 4 ])) - log.debug("Trying paths: {0}".format(repr(paths))) + log.debug(f"Trying paths: {repr(paths)}") for path in paths: if os.path.exists(path): - log.debug("Found file at path: {0}".format(path)) + log.debug(f"Found file at path: {path}") return path log.debug("No config file found") @@ -57,7 +57,7 @@ def load_general_config(config_path=None): try: with open(config_file) as f: return json.load(f) - except (IOError, ValueError) as e: + except (OSError, ValueError) as e: # In the case of a legacy `.dockercfg` file, we won't # be able to load any JSON data. log.debug(e) |