From 9cef19d9d2495c9ac70fa81ea19885fc1c979041 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sat, 17 Jul 2021 09:06:16 +0200 Subject: Merging upstream version 3.3.0. Signed-off-by: Daniel Baumann --- cfgv.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'cfgv.py') diff --git a/cfgv.py b/cfgv.py index f0b9eff..2a9ceab 100644 --- a/cfgv.py +++ b/cfgv.py @@ -392,8 +392,8 @@ def load_from_filename( exc_tp=ValidationError, ): with reraise_as(exc_tp): - if not os.path.exists(filename): - raise ValidationError(f'{filename} does not exist') + if not os.path.isfile(filename): + raise ValidationError(f'{filename} is not a file') with validate_context(f'File {filename}'): try: -- cgit v1.2.3