Skip to content

Commit 8f1b92a

Browse files
authored
👩‍🌾 Fix flake8: specify exception (#102)
Signed-off-by: Louise Poubel <[email protected]>
1 parent fff0989 commit 8f1b92a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

colcon_cmake/event_handler/compile_commands.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -68,13 +68,13 @@ def __call__(self, event): # noqa: D102
6868
try:
6969
workspace_level_mtime = os.path.getmtime(
7070
str(workspace_level_json_path))
71-
except Exception:
71+
except OSError:
7272
pass
7373
else:
7474
for json_path in sorted(package_level_json_paths):
7575
try:
7676
mtime = os.path.getmtime(str(json_path))
77-
except Exception:
77+
except OSError:
7878
continue
7979
if mtime > workspace_level_mtime:
8080
break

0 commit comments

Comments
 (0)