From 10ead3aa7f81449bfe678cf2f77a0a1b22eaca4e Mon Sep 17 00:00:00 2001 From: Sebastian Mendel Date: Fri, 24 Jul 2026 15:46:50 +0200 Subject: [PATCH] fix(ruff): ruff 0.16.0 compatibility (I001/BLE001) The reusable validate.yml Python-lint step now pins ruff 0.16.0 (netresearch/skill-repo-skill#184), which surfaces findings the previous unpinned ruff did not flag in scripts/detect_missing_tool.py: - I001: import block un-sorted -> reordered (json/re/sys), safe autofix - BLE001: blind `except Exception` on stdin read -> annotated with `# noqa: BLE001`; the handler intentionally fails open (returns) so the hook never breaks the calling tool. Behaviour unchanged. No EXE001/FURB105 present in this repo. Signed-off-by: Sebastian Mendel --- scripts/detect_missing_tool.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/scripts/detect_missing_tool.py b/scripts/detect_missing_tool.py index 2136c47..cf3ce11 100755 --- a/scripts/detect_missing_tool.py +++ b/scripts/detect_missing_tool.py @@ -4,9 +4,9 @@ Outputs a system reminder suggesting the cli-tools skill when a missing tool is detected. """ -import sys -import re import json +import re +import sys # Patterns that indicate a missing command/tool MISSING_PATTERNS = [ @@ -40,7 +40,7 @@ def main(): # Read tool output from stdin (Claude Code passes tool result) try: input_data = sys.stdin.read() - except Exception: + except Exception: # noqa: BLE001 - hook must fail open on any stdin read error return if not input_data: