From cb827ae0b2806349688b54e7c8bd3e4a846ee010 Mon Sep 17 00:00:00 2001 From: Pouyanpi <13303554+Pouyanpi@users.noreply.github.com> Date: Fri, 17 Oct 2025 12:07:39 +0200 Subject: [PATCH] style(cache): replace pass with ellipsis in abstract methods Updates abstract method implementations in CacheInterface to use ellipsis (...) instead of pass, following modern Python conventions for abstract method stubs. --- nemoguardrails/llm/cache/interface.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/nemoguardrails/llm/cache/interface.py b/nemoguardrails/llm/cache/interface.py index 9533d9ef5..ee8368a3d 100644 --- a/nemoguardrails/llm/cache/interface.py +++ b/nemoguardrails/llm/cache/interface.py @@ -44,7 +44,7 @@ def get(self, key: Any, default: Any = None) -> Any: Returns: The value associated with the key, or default if not found. """ - pass + ... @abstractmethod def put(self, key: Any, value: Any) -> None: @@ -58,7 +58,7 @@ def put(self, key: Any, value: Any) -> None: key: The key to store. value: The value to associate with the key. """ - pass + ... @abstractmethod def size(self) -> int: @@ -68,7 +68,7 @@ def size(self) -> int: Returns: The number of items currently stored in the cache. """ - pass + ... @abstractmethod def is_empty(self) -> bool: @@ -78,7 +78,7 @@ def is_empty(self) -> bool: Returns: True if the cache contains no items, False otherwise. """ - pass + ... @abstractmethod def clear(self) -> None: @@ -87,7 +87,7 @@ def clear(self) -> None: After calling this method, the cache should be empty. """ - pass + ... def contains(self, key: Any) -> bool: """ @@ -115,7 +115,7 @@ def maxsize(self) -> int: Returns: The maximum number of items the cache can hold. """ - pass + ... def get_stats(self) -> dict: """