shim: single attempt per request (retry loop burned 4 accounts on one empty answer)
This commit is contained in:
+3
-1
@@ -291,7 +291,9 @@ class H(BaseHTTPRequestHandler):
|
||||
return self._json(503, {"error": {"message": "no qwenwork account available "
|
||||
"(pool empty or all cooling)"}})
|
||||
tried, ans, sid, last_err = set(), None, None, None
|
||||
for _ in range(min(4, max(1, len(_accounts)))):
|
||||
# [NORETRY 1121] one account per request: every attempt creates a session and burns
|
||||
# the whole wallet, so a 4x retry loop cost 4 accounts per empty answer.
|
||||
for _ in range(1):
|
||||
try:
|
||||
ans, _thought, sid = run_turn(acc["jwt"], mode, text)
|
||||
if ans:
|
||||
|
||||
Reference in New Issue
Block a user