mirror of
https://github.com/hanzoai/dev.git
synced 2026-10-25 03:32:32 +00:00
fix(ci/issue-comment): make agent assertion non-fatal; fail only on proxy 5xx/upstream_error; keep fallback path working
This commit is contained in:
@@ -326,15 +326,11 @@ jobs:
|
||||
2>&1 | tee .github/auto/AGENT_OUT.txt
|
||||
true
|
||||
set -e
|
||||
- name: Assert agent success (fail on streaming/server errors)
|
||||
- name: Assert agent success (fail on server 5xx only; tolerate local stream errors)
|
||||
if: ${{ secrets.OPENAI_API_KEY != '' }}
|
||||
continue-on-error: true
|
||||
run: |
|
||||
set -euo pipefail
|
||||
if rg -n "^\\[.*\\] ERROR: (stream error|server error|exceeded retry limit)" .github/auto/AGENT_OUT.txt >/dev/null 2>&1; then
|
||||
echo "Agent reported a fatal error (stream/server). Failing job." >&2
|
||||
rg -n "^\\[.*\\] ERROR: (stream error|server error|exceeded retry limit)" .github/auto/AGENT_OUT.txt || true
|
||||
exit 1
|
||||
fi
|
||||
if [ -s .github/auto/openai-proxy.log ]; then
|
||||
if rg -n '"phase":"response_head".*"status":5\\d\\d' .github/auto/openai-proxy.log >/dev/null 2>&1; then
|
||||
echo "Proxy observed 5xx from upstream during agent run. Failing job." >&2
|
||||
|
||||
Reference in New Issue
Block a user