ci: retry cross-os agent runtime deps staging

This commit is contained in:
Peter Steinberger
2026-04-28 06:50:53 +01:00
parent 4397717322
commit 2f2aee5fe8
2 changed files with 62 additions and 20 deletions

View File

@@ -41,6 +41,7 @@ import {
shouldSkipInstallerDaemonHealthCheck,
shouldStopManagedGatewayBeforeManualFallback,
shouldRunMainChannelDevUpdate,
shouldRetryCrossOsAgentTurnError,
shouldUseManagedGatewayForInstallerRuntime,
shouldUseManagedGatewayService,
verifyDevUpdateStatus,
@@ -83,6 +84,22 @@ describe("scripts/openclaw-cross-os-release-checks", () => {
}
});
it("retries transient bundled runtime deps staging failures during agent turns", () => {
expect(
shouldRetryCrossOsAgentTurnError(
new Error("document-extract: failed to install bundled runtime deps: npm install failed"),
),
).toBe(true);
expect(
shouldRetryCrossOsAgentTurnError(
new Error("document-extract failed to stage bundled runtime deps after 463ms"),
),
).toBe(true);
expect(shouldRetryCrossOsAgentTurnError(new Error("Agent output did not contain OK."))).toBe(
false,
);
});
it("treats explicit empty-string args as values instead of boolean flags", () => {
expect(parseArgs(["--ubuntu-runner", "", "--mode", "both"])).toEqual({
"ubuntu-runner": "",