Open-source AI penetration testing tool to find and fix your app’s vulnerabilities.
Python agentsai-hackingai-penetration-testingai-pentestingai-securityartificial-intelligencebug-bountycode-qualityctf-toolscybersecuritycybersecurity-toolsethical-hackinghackingllm-securityoffensive-securitypenetration-testingpentesting-toolsred-teamingsecuritysecurity-automation
fix(tools): halve the wait_for_message ceiling to 300s
Ahmed Allam49057f267f21
diff --git a/strix/core/execution.py b/strix/core/execution.pyindex d9f8c0a9..5862adb2 100644--- a/strix/core/execution.py+++ b/strix/core/execution.py@@ -540,7 +540,7 @@ async def _exhausted_recovery(return result-_WAITING_AUTO_RESUME_TIMEOUT_S = 600.0+_WAITING_AUTO_RESUME_TIMEOUT_S = 300.0async def _plain_waiting_timeout(diff --git a/strix/tools/agents_graph/tools.py b/strix/tools/agents_graph/tools.pyindex b5d1af9d..ec1e3912 100644--- a/strix/tools/agents_graph/tools.py+++ b/strix/tools/agents_graph/tools.py@@ -218,11 +218,18 @@ def _session_items_payload(items: list[Any]) -> list[dict[str, Any]]:return payload-@function_tool(timeout=601)+_WAIT_DEFAULT_TIMEOUT_S = 300+# Enforced by the SDK around the whole tool call, so it caps an oversized+# ``timeout_seconds`` the model asks for. One second of headroom lets the+# tool's own timeout fire first and return a clean result.+_WAIT_HARD_CEILING_S = _WAIT_DEFAULT_TIMEOUT_S + 1+++@function_tool(timeout=_WAIT_HARD_CEILING_S)async def wait_for_message( # noqa: PLR0911ctx: RunContextWrapper,reason: str = "Waiting for messages from other agents",- timeout_seconds: int = 600,+ timeout_seconds: int = _WAIT_DEFAULT_TIMEOUT_S,) -> str:"""Pause this agent until a message lands in its inbox (or timeout).@@ -255,7 +262,8 @@ async def wait_for_message( # noqa: PLR0911reason: One-line note shown in graph snapshots while you'rewaiting (helps a human or sibling agent debug who's stuckon what).- timeout_seconds: Max seconds to wait (default 600). This is only+ timeout_seconds: Max seconds to wait (default 300, and values above+ that are cut short by a hard ceiling). This is onlya cap — the tool returns the INSTANT a message arrives, so alarger value never makes you wait longer when the reply doescome. Right-size it to what you're waiting on: a short wait