Skip to content

Commit

Permalink
[Misc]Suppress irrelevant exception stack trace information when CUDA… (
Browse files Browse the repository at this point in the history
#11438)

Co-authored-by: shiquan <shiquan>
  • Loading branch information
shiquan1988 authored Dec 24, 2024
1 parent a491d6f commit 4f074fb
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion vllm/entrypoints/llm.py
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,8 @@ def __init__(
self.request_counter = Counter()

def __del__(self):
if self.llm_engine and hasattr(self.llm_engine, "shutdown"):
if hasattr(self, 'llm_engine') and self.llm_engine and hasattr(
self.llm_engine, "shutdown"):
self.llm_engine.shutdown()

@staticmethod
Expand Down

0 comments on commit 4f074fb

Please sign in to comment.