Spaces:
Sleeping
Sleeping
Commit History
-
Harden the local solver (ticket 01)
- Retry-with-backoff for transient model/network errors: _call_with_retry + _is_retryable_error applied to answer cleaning, /questions fetch, and each agent model call via _RetryingOpenAIServerModel (preserves ReAct memory). - Per-Task timeout: _run_with_timeout runs each Agent call on a daemon helper thread joined with TASK_TIMEOUT_SEC; a wedged call is recorded as a timeout row without blocking the worker or process exit. - Worker pool: agents returned in try/finally (no lost worker/deadlock on a throwing Task); a timed-out Agent is discarded and replaced with a fresh one. - Answer cleaning: prompt built via replacement (safe for braces) instead of .format(); cleaning max_tokens raised to 1024 (CLEANING_MAX_TOKENS). - Safe archive extraction: _safe_extract_all replaces extractall() and rejects path traversal (.., absolute paths, symlink escapes). - Unit tests (36) for answer normalization, prompt building, safe zip, retry, per-task timeout, and local-file resolution. …43598fd