Skip to content

Commit

Permalink
Exception on e.errno is None. Fixes wireviz#391.
Browse files Browse the repository at this point in the history
  • Loading branch information
martinrieder authored Jun 20, 2024
1 parent ba84c54 commit 5bb81bc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/wireviz/wireviz.py
Original file line number Diff line number Diff line change
Expand Up @@ -416,7 +416,7 @@ def _get_yaml_data_and_path(inp: Union[str, Path, Dict]) -> (Dict, Path):
# Catch this error, but raise any others
from errno import EINVAL, ENAMETOOLONG

if type(e) is OSError and e.errno not in (EINVAL, ENAMETOOLONG):
if type(e) is OSError and e.errno not in (EINVAL, ENAMETOOLONG, None):
raise e
# file does not exist; assume inp is a YAML string
yaml_str = inp
Expand Down

0 comments on commit 5bb81bc

Please sign in to comment.