Skip to content

Commit

Permalink
fix: change FileExistsError to a proper FileNotFoundError
Browse files Browse the repository at this point in the history
  • Loading branch information
KernAttila committed Mar 28, 2023
1 parent b5d21c9 commit df35cbb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions cuesubmit/cuesubmit/Config.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ def _loadYamlFile(yaml_file):
"""
_yaml_file = os.path.expandvars(yaml_file)
if not os.path.exists(_yaml_file):
raise FileExistsError(f'{_yaml_file=} not found')
raise FileNotFoundError(f'{_yaml_file=} not found')
config_data = {}
with open(_yaml_file, 'r') as data:
try:
Expand All @@ -77,7 +77,7 @@ def _expandRenderConfigValues(RENDER_CMDS):
continue
try:
RENDER_CMDS[job_type] = _loadYamlFile(yaml_file=_sub_config_file)
except FileExistsError as error:
except FileNotFoundError as error:
RENDER_CMDS[job_type] = {
'command': 'error',
'options': {
Expand Down

0 comments on commit df35cbb

Please sign in to comment.