From 4dc0d606b78eb8dbb5e833ab45d3fbb1378edf35 Mon Sep 17 00:00:00 2001 From: Kevin McKay Date: Fri, 9 Jan 2026 20:39:22 -0600 Subject: [PATCH] [Bugfix] Narrow broad exceptions in compilation backends (#31616) Signed-off-by: c0de128 Co-authored-by: Claude Opus 4.5 Co-authored-by: Cyrus Leung --- vllm/compilation/backends.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vllm/compilation/backends.py b/vllm/compilation/backends.py index 5262e39b2a5..dec20cdc806 100644 --- a/vllm/compilation/backends.py +++ b/vllm/compilation/backends.py @@ -606,7 +606,7 @@ class VllmBackend: try: with open(filepath) as f: hash_content.append(f.read()) - except Exception: + except OSError: logger.warning("Failed to read file %s", filepath) continue code_hash = hashlib.sha256("\n".join(hash_content).encode()).hexdigest()