SWE-agent takes a GitHub issue and tries to automatically fix it, using your LM of choice. It can also be employed for offensive cybersecurity or competitive coding challenges. [NeurIPS 2024]
Enh(hp): Remove superfluous warnings
Kilian Lieretbf55d86da0f5
diff --git a/sweagent/agent/history_processors.py b/sweagent/agent/history_processors.pyindex 735b80e1..caeff198 100644--- a/sweagent/agent/history_processors.py+++ b/sweagent/agent/history_processors.py@@ -7,7 +7,6 @@ from typing import Annotated, Literal, Protocolfrom pydantic import BaseModel, ConfigDict, Fieldfrom sweagent.types import History, HistoryItem-from sweagent.utils.log import get_loggerclass AbstractHistoryProcessor(Protocol):@@ -206,7 +205,6 @@ class CacheControlHistoryProcessor(BaseModel):def __call__(self, history: History) -> History:new_history = []n_tagged = 0- logger = get_logger("hp")for entry in reversed(history):# Clear cache control from previous messagesself._clear_cache_control(entry)@@ -214,8 +212,6 @@ class CacheControlHistoryProcessor(BaseModel):self._set_cache_control(entry)n_tagged += 1new_history.append(entry)- if n_tagged != self.last_n_messages:- logger.warning(f"Expected {self.last_n_messages} messages tagged with cache_control, got {n_tagged}")return list(reversed(new_history))