mirror of
https://github.com/jxxghp/MoviePilot.git
synced 2026-11-03 13:55:00 +08:00
eval: add Codex OAuth parity comparison
This commit is contained in:
@@ -223,7 +223,10 @@ async def _run_codex(scenario_id: str, settings: ModelSettings, executable: str,
|
||||
failure = result.get("error_type")
|
||||
except (RuntimeError, TimeoutError, OSError) as error:
|
||||
failure = type(error).__name__
|
||||
local_tokens = (proxy.bearer_token, server.bearer_token)
|
||||
local_tokens = tuple(
|
||||
value for value in (proxy.bearer_token, server.bearer_token, settings.account_id)
|
||||
if isinstance(value, str) and value
|
||||
)
|
||||
usage = proxy.snapshot()
|
||||
server_stats = server.stats
|
||||
skill_sha256 = server.skill_sha256
|
||||
@@ -252,7 +255,9 @@ async def _run_codex(scenario_id: str, settings: ModelSettings, executable: str,
|
||||
report["task_passed"] = report["passed"]
|
||||
report["passed"] = bool(report["passed"] and completed and result.get("returncode") == 0 and not failure)
|
||||
report["probe_ready"] = bool(probe_only and not failure and _probe_ready(usage, server_stats))
|
||||
checked: dict[str, Any] = _validate_report(_redact(report, local_tokens), settings.api_key)
|
||||
checked: dict[str, Any] = _validate_report(
|
||||
_redact(report, local_tokens), settings.api_key, settings.account_id,
|
||||
)
|
||||
checked["native_stderr_sha256"] = hashlib.sha256(checked["native_stderr"].encode()).hexdigest()
|
||||
return checked
|
||||
|
||||
|
||||
Reference in New Issue
Block a user