fixup! sim117

This commit is contained in:
Codex
2026-10-16 10:24:50 +09:00
parent 95fbc19f30
commit dc91205641
3 changed files with 1113 additions and 0 deletions
@@ -229,3 +229,33 @@ class AliyunLogStorePG:
for col, val in zip(columns, row, strict=False):
row_dict[col] = "" if val is None else str(val)
result.append(row_dict)
except psycopg2.Error as e:
if not self._is_retriable_error(e):
logger.exception(
"Failed to execute SQL on logstore %s (non-retriable error): sql=%s",
logstore,
sql,
)
raise
if attempt < max_retries - 1:
logger.warning(
"Failed to execute SQL on logstore %s (attempt %d/%d): %s. Retrying...",
logstore,
attempt + 1,
max_retries,
str(e),
)
time.sleep(retry_delay)
retry_delay *= 2
else:
logger.exception(
"Failed to execute SQL on logstore %s after %d attempts: sql=%s",
logstore,
max_retries,
sql,
)
raise
return []
@@ -295,3 +295,4 @@ def test_invoke_skips_forwarding_outside_enterprise_edition(config_overrides):
# Should not raise; should not call enterprise.
with contextlib.suppress(Exception):
tool.invoke_remote_mcp_tool({}, user_id=None, app_id=None)
inject.assert_not_called()
File diff suppressed because it is too large Load Diff