fix(qa-matrix): cap live timeout env · openclaw/openclaw@fc90f0f
steipete
·
2026-05-30
·
via Recent Commits to openclaw:main
File tree
extensions/qa-matrix/src/runners/contract
| Original file line number | Diff line number | Diff line change |
|---|
|
1 | 1 | import type { OpenClawConfig } from "openclaw/plugin-sdk/config-contracts"; |
| 2 | +import { MAX_TIMER_TIMEOUT_MS } from "openclaw/plugin-sdk/number-runtime"; |
2 | 3 | import { renderQaMarkdownReport } from "openclaw/plugin-sdk/qa-runtime"; |
3 | 4 | import { afterEach, describe, expect, it, vi } from "vitest"; |
4 | 5 | import { testing as liveTesting } from "./runtime.js"; |
@@ -104,6 +105,8 @@ describe("matrix live qa runtime", () => {
|
104 | 105 | expect(liveTesting.createMatrixQaRunDeadline().timeoutMs).toBe(30 * 60_000); |
105 | 106 | process.env.OPENCLAW_QA_MATRIX_TIMEOUT_MS = "1.5"; |
106 | 107 | expect(liveTesting.createMatrixQaRunDeadline().timeoutMs).toBe(30 * 60_000); |
| 108 | +process.env.OPENCLAW_QA_MATRIX_TIMEOUT_MS = String(Number.MAX_SAFE_INTEGER); |
| 109 | +expect(liveTesting.createMatrixQaRunDeadline().timeoutMs).toBe(MAX_TIMER_TIMEOUT_MS); |
107 | 110 | } finally { |
108 | 111 | if (previous === undefined) { |
109 | 112 | delete process.env.OPENCLAW_QA_MATRIX_TIMEOUT_MS; |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -4,7 +4,10 @@ import path from "node:path";
|
4 | 4 | import { setTimeout as sleep } from "node:timers/promises"; |
5 | 5 | import type { OpenClawConfig } from "openclaw/plugin-sdk/config-contracts"; |
6 | 6 | import { formatErrorMessage } from "openclaw/plugin-sdk/error-runtime"; |
7 | | -import { parseStrictPositiveInteger } from "openclaw/plugin-sdk/number-runtime"; |
| 7 | +import { |
| 8 | +parseStrictPositiveInteger, |
| 9 | +resolveTimerTimeoutMs, |
| 10 | +} from "openclaw/plugin-sdk/number-runtime"; |
8 | 11 | import { loadQaRuntimeModule } from "openclaw/plugin-sdk/qa-runner-runtime"; |
9 | 12 | import { |
10 | 13 | appendQaLiveLaneIssue as appendLiveLaneIssue, |
@@ -196,7 +199,7 @@ function parsePositiveMatrixQaEnvMs(name: string, fallback: number) {
|
196 | 199 | if (raw === undefined) { |
197 | 200 | return fallback; |
198 | 201 | } |
199 | | -return parseStrictPositiveInteger(raw) ?? fallback; |
| 202 | +return resolveTimerTimeoutMs(parseStrictPositiveInteger(raw), fallback); |
200 | 203 | } |
201 | 204 | |
202 | 205 | function createMatrixQaRunDeadline() { |
|
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。