Skip to content

fix(scripts): bound android-release-signing exec operations - #110822

Merged
steipete merged 7 commits into
openclaw:mainfrom
wanyongstar:fix/bound-android-signing-exec
Jul 28, 2026
Merged

steipete merged 7 commits into
openclaw:mainfrom
wanyongstar:fix/bound-android-signing-exec

Conversation

@wanyongstar

@wanyongstar wanyongstar commented Jul 18, 2026 •

Copy link
Copy Markdown
Contributor

What Problem This Solves

Android release-signing sync used unbounded synchronous child processes. A stalled git, openssl, or related executable could therefore block the release lane indefinitely.

Why This Change Was Made

All external signing commands now run through one declared process helper with a 120-second deadline and SIGKILL termination. The helper preserves the existing cwd, environment, stdio, and text-encoding behavior used by both command call shapes. The production deadline constant stays module-private so the helper does not accidentally publish an unsupported API surface.

Node 24 documentation and v24.18.0 source were checked directly, then reverified against the current Node 26.5.0 API docs, source, and installed @types/node: execFileSync forwards timeout and killSignal to spawnSync; the sync runner validates both, records ETIMEDOUT, signals the child, and returns the underlying result. SIGKILL prevents a hung child from intercepting the deadline. This helper is private to the signing-sync script and wraps only Git plus small OpenSSL operations; Gradle and Fastlane release builds use separate entrypoints. A timed-out signing command is reported as:

Android release signing command timed out after 120000ms: <executable>

Only the executable name is included, not arguments or environment values, so signing secrets cannot be copied into the error. The original Node error remains attached as cause.

User Impact

Hung Android signing tools fail within a bounded deadline instead of consuming the release worker forever. Successful signing, encrypted-repository sync, and materialization behavior are unchanged.

Evidence

Prepared head: 02cdd7b617c98b14907e7e14e1d159c0d3345dbb.

  • A real indefinitely running Node child was terminated by the production helper at a 100ms test-only deadline.
  • test/scripts/android-release-signing.test.ts: 17/17 passed locally and on Blacksmith Testbox.
  • Blacksmith Testbox tbx_01kym5vn5bjdx4xpa0j4f77twf (run 30352715168) passed Knip production/full/script unused-export scans, 244 script declaration contracts, script typecheck, and the focused signing suite on the patch-identical signing diff.
  • Exact agentic-agents-core-models proof on Testbox tbx_01kym5nc7qsb1s7gcbwh92e4ce (run 30352485418) passed 53 files / 1,204 tests in 103 seconds while validating the canonical current-main repair inherited from fix: stop model transport tests from stalling CI #115139.
  • The final four-file whole-branch autoreview was clean at 0.93; the timeout-ownership clarification was independently clean at 0.99.
  • Oxfmt and git diff --check passed.
  • Exact-head CI run 30353457646 is green on 02cdd7b617c98b14907e7e14e1d159c0d3345dbb, including the repaired model shard and openclaw/ci-gate.

The broader successful path uses a temporary encrypted signing repository and exercises both fire-and-forget and text-returning command paths through the bounded helper without printing the test passwords.

ClawSweeper Rank-up Moves

The text-returning success path is covered by the full sync-push/sync-pull/materialize regression above. A live run against the real private Android signing repository was intentionally not performed: it would use production signing material and mutate an operational repository, which is outside a code-landing proof. No release credentials or signing artifacts were used, printed, or changed.

Earlier exact-head runs hit the shared bare-Ubuntu ripgrep fixture failure and an embedded-agent no-output stall; those generic repairs landed through #115035 and #110425. A later run exposed a current-main test-ownership bug where an SDK request-option test spent 77 seconds cold-loading provider plugins. That repair landed independently in #115139 while this PR was being prepared. The final merge takes the canonical main test byte-for-byte, so this PR remains a four-file signing change.

@openclaw-barnacle openclaw-barnacle Bot added scripts Repository scripts size: XS labels Jul 18, 2026
@clawsweeper clawsweeper Bot added rating: 🧂 unranked krab Not merge-ready due to missing proof or serious correctness/safety concerns. status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask. P2 Normal backlog priority with limited blast radius. merge-risk: 🚨 availability 🚨 May cause crashes, hangs, restart loops, stalls, or process outages. labels Jul 18, 2026
@clawsweeper

clawsweeper Bot commented Jul 18, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs real behavior proof before merge. Reviewed July 28, 2026, 7:38 AM ET / 11:38 UTC.

ClawSweeper review

What this changes

The PR routes Android release-signing Git and OpenSSL subprocesses through a private synchronous helper that kills commands after 120 seconds and emits a redacted timeout error.

Merge readiness

⛔ Blocked until real behavior proof from a real setup is added - 3 items remain

Keep this PR open. The patch is a focused, apparently correct reliability hardening for the Android signing workflow, but the available PR text supplies tests and CI claims rather than inspectable redacted after-fix runtime output; that remains the merge gate. The branch is also behind current main, so maintainer review should use the actual merge result after proof is posted.

Priority: P2
Reviewed head: 02cdd7b617c98b14907e7e14e1d159c0d3345dbb

Review scores

Measure Result What it means
Overall readiness 🦪 silver shellfish (2/6) The implementation is focused and has no supported code-level finding, but real after-fix behavior proof is still missing from the available review evidence.
Proof confidence 🦪 silver shellfish (2/6) Needs real behavior proof before merge: The PR describes unit tests, CI, and a disposable-repository exercise, but the supplied review context contains no inspectable redacted terminal output, log, recording, or linked artifact showing after-fix signing behavior. Add redacted runtime evidence; updating the PR body should trigger review, or a maintainer can request @clawsweeper re-review. After adding proof, update the PR body; ClawSweeper should re-review automatically. If it does not, the PR author or someone with repository write access can comment @clawsweeper re-review.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Needs proof Needs real behavior proof before merge: The PR describes unit tests, CI, and a disposable-repository exercise, but the supplied review context contains no inspectable redacted terminal output, log, recording, or linked artifact showing after-fix signing behavior. Add redacted runtime evidence; updating the PR body should trigger review, or a maintainer can request @clawsweeper re-review. After adding proof, update the PR body; ClawSweeper should re-review automatically. If it does not, the PR author or someone with repository write access can comment @clawsweeper re-review.
Evidence reviewed 5 items Focused implementation boundary: The branch changes the signing script’s two command wrappers to call one private helper, preserving their cwd, environment, stdio, and text-returning call shapes while adding timeout handling.
Timeout and secrecy behavior: The new helper passes a 120-second timeout and SIGKILL to Node’s synchronous process runner, then reports only the executable name when it receives ETIMEDOUT; it does not interpolate arguments or environment values into the new error.
Regression intent: The added test starts an indefinitely running Node child through the production helper with a test-only 100 ms deadline and asserts that the helper throws before five seconds.
Findings None None.
Security None None.

How this fits together

The Android release-signing script synchronizes encrypted signing material by invoking Git and OpenSSL. The added helper sits between that script and Node’s synchronous child-process API, turning indefinitely stalled commands into bounded release-workflow failures.

flowchart LR
  A[Signing manifest and encrypted repository] --> B[Android signing sync script]
  B --> C[Bounded process helper]
  C --> D[Git or OpenSSL command]
  D --> E{Completes within 120 seconds?}
  E -->|Yes| F[Continue signing sync]
  E -->|No| G[Kill process and return redacted error]
Loading

Before merge

  • Add real behavior proof - Needs real behavior proof before merge: The PR describes unit tests, CI, and a disposable-repository exercise, but the supplied review context contains no inspectable redacted terminal output, log, recording, or linked artifact showing after-fix signing behavior. Add redacted runtime evidence; updating the PR body should trigger review, or a maintainer can request @clawsweeper re-review. After adding proof, update the PR body; ClawSweeper should re-review automatically. If it does not, the PR author or someone with repository write access can comment @clawsweeper re-review.
  • Resolve merge risk (P2) - Merging changes timeout and forced-termination behavior for release-signing commands; a successful head-only CI run does not prove the current merge result while the branch is behind main.
  • Resolve merge risk (P1) - The PR body reports a disposable encrypted-repository exercise, but no inspectable redacted runtime artifact is available in the supplied review context to establish after-fix real behavior beyond tests and CI.
Agent review details

Security

None.

PR surface

Tests +14, Other +40. Total +54 across 4 files.

View PR surface stats
Area Files Added Removed Net
Source 0 0 0 0
Tests 1 14 0 +14
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 3 43 3 +40
Total 4 57 3 +54

Review metrics

None.

Merge-risk options

Maintainer options:

  1. Add redacted runtime proof and refresh the merge result (recommended)
    Provide inspectable after-fix disposable-repository output with secrets and private paths removed, then validate the clean merge result against current main before merge.
  2. Accept the test-only evidence deliberately
    A maintainer may decide that the focused hung-child regression and hosted checks are sufficient despite the lack of inspectable runtime output.

Technical review

Best possible solution:

Post a redacted terminal transcript or runtime log from the disposable signing-repository flow that shows a successful sync/materialization through the helper and a bounded timeout case, then refresh validation against the current merge result before landing.

Do we have a high-confidence way to reproduce the issue?

Yes from source, with medium confidence: invoking the helper on a child that never exits exercises its timeout path, and the added regression test uses exactly that mechanism. The supplied context does not provide an independently inspectable live signing-flow transcript.

Is this the best way to solve the issue?

Yes, provisionally: one private helper is the narrowest way to keep both existing signing command call shapes bounded without publishing a broader process API. The remaining question is proof of the real disposable-repository path and the current merge result, not an alternate implementation design.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against 20eda756fae6.

Labels

Label justifications:

  • P2: This is a bounded release-workflow reliability improvement rather than an active end-user runtime outage.
  • merge-risk: 🚨 availability: The patch changes how hung Git and OpenSSL child processes are terminated in the release-signing path.
  • rating: 🦪 silver shellfish: Overall readiness is 🦪 silver shellfish; proof is 🦪 silver shellfish and patch quality is 🐚 platinum hermit.
  • status: 📣 needs proof: The PR needs real behavior proof before ClawSweeper can clear the contributor ask. Needs real behavior proof before merge: The PR describes unit tests, CI, and a disposable-repository exercise, but the supplied review context contains no inspectable redacted terminal output, log, recording, or linked artifact showing after-fix signing behavior. Add redacted runtime evidence; updating the PR body should trigger review, or a maintainer can request @clawsweeper re-review. After adding proof, update the PR body; ClawSweeper should re-review automatically. If it does not, the PR author or someone with repository write access can comment @clawsweeper re-review.

Evidence

What I checked:

  • Focused implementation boundary: The branch changes the signing script’s two command wrappers to call one private helper, preserving their cwd, environment, stdio, and text-returning call shapes while adding timeout handling. (scripts/android-release-signing.mjs:188, 02cdd7b617c9)
  • Timeout and secrecy behavior: The new helper passes a 120-second timeout and SIGKILL to Node’s synchronous process runner, then reports only the executable name when it receives ETIMEDOUT; it does not interpolate arguments or environment values into the new error. (scripts/lib/android-release-signing-process.mjs:4, 02cdd7b617c9)
  • Regression intent: The added test starts an indefinitely running Node child through the production helper with a test-only 100 ms deadline and asserts that the helper throws before five seconds. (test/scripts/android-release-signing.test.ts:137, 02cdd7b617c9)
  • Available review-state evidence: The supplied PR state reports a clean but behind branch and successful exact-head checks, including process-exec-boundary security checks and ci-gate. The supplied body does not include an inspectable terminal transcript, runtime log, recording, or linked artifact for the disposable signing-repository execution it describes. (02cdd7b617c9)
  • Related PR separation: The PR body identifies merged CI repairs as unrelated to this four-file signing change; the referenced model-test and embedded-agent fixes address CI runtime duration rather than Android signing subprocess ownership. (a20c5550c874)

Likely related people:

  • steipete: Prepared the later timeout-scope, timeout-test, and current-main merge commits on this PR, and is assigned to the PR in the supplied timeline. (role: recent area contributor; confidence: high; commits: b657dfd64e5b, 6360a79db435, 4e7e0efd6ebe; files: scripts/android-release-signing.mjs, scripts/lib/android-release-signing-process.mjs, test/scripts/android-release-signing.test.ts)
  • wanyongstar: Authored the initial bounded-exec change that the later signing-specific commits refine. (role: original implementation contributor; confidence: medium; commits: 8fcbe6ec0b6b; files: scripts/android-release-signing.mjs, scripts/lib/android-release-signing-process.mjs)

Rank-up moves

Optional improvements that raise the rating; they are not merge blockers.

  • Attach a redacted terminal transcript or log showing the disposable signing-repository sync succeeds through the helper and a timed-out command is bounded.
  • Refresh the clean merge result against current main after adding the proof.

Rating scale

Score Internal tier Crab rank Meaning
6/6 S 🦀 challenger crab Exceptional readiness
5/6 A 🦞 diamond lobster Very strong readiness
4/6 B 🐚 platinum hermit Good normal PR; ordinary maintainer review
3/6 C 🦐 gold shrimp Useful, but confidence is limited
2/6 D 🦪 silver shellfish Proof or implementation needs work
1/6 F 🧂 unranked krab Not merge-ready
N/A NA 🌊 off-meta tidepool Rating does not apply

Overall follows the weaker of proof and patch quality.
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics.

Workflow

  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.

History

Review history (11 earlier review cycles; latest 8 shown)
  • reviewed 2026-07-18T21:12:43.210Z sha cde4d668c837c0d465db3a7af263d47301b19c79 :: needs real behavior proof before merge. :: none
  • reviewed 2026-07-18T21:35:31.753Z sha 339f7a322f45b3869817b579df0b3c0401282fb6 :: needs real behavior proof before merge. :: none
  • reviewed 2026-07-18T21:46:04.911Z sha 8fcbe6e :: needs real behavior proof before merge. :: none
  • reviewed 2026-07-18T22:28:33.510Z sha 8fcbe6e :: needs real behavior proof before merge. :: none
  • reviewed 2026-07-19T13:48:45.693Z sha 8fcbe6e :: needs real behavior proof before merge. :: none
  • reviewed 2026-07-28T05:38:41.733Z sha b657dfd :: needs real behavior proof before merge. :: none
  • reviewed 2026-07-28T09:58:01.772Z sha 4e7e0ef :: needs real behavior proof before merge. :: none
  • reviewed 2026-07-28T11:12:18.752Z sha 02cdd7b :: needs real behavior proof before merge. :: none

@wanyongstar
wanyongstar force-pushed the fix/bound-android-signing-exec branch from bfec248 to c1eba30 Compare July 18, 2026 17:11
@wanyongstar wanyongstar reopened this Jul 18, 2026
@wanyongstar
wanyongstar force-pushed the fix/bound-android-signing-exec branch from 33663b7 to 5fe8d6a Compare July 18, 2026 21:09
@wanyongstar wanyongstar reopened this Jul 18, 2026
@clawsweeper clawsweeper Bot added rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. and removed rating: 🧂 unranked krab Not merge-ready due to missing proof or serious correctness/safety concerns. labels Jul 18, 2026
@wanyongstar
wanyongstar force-pushed the fix/bound-android-signing-exec branch from cde4d66 to 77a42ad Compare July 18, 2026 21:32
@wanyongstar wanyongstar reopened this Jul 18, 2026
@wanyongstar
wanyongstar force-pushed the fix/bound-android-signing-exec branch from 339f7a3 to fa9ae68 Compare July 18, 2026 21:43
@wanyongstar wanyongstar reopened this Jul 18, 2026
@wanyongstar

Copy link
Copy Markdown
Contributor Author

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Jul 19, 2026 •

Copy link
Copy Markdown
Contributor

🦞🧹
ClawSweeper re-review requested.

I asked ClawSweeper to review this item again.
Action: item re-review queued (workflow sweep.yml, event repository_dispatch).
Result: the existing ClawSweeper review comment will be edited in place when the review finishes.

Re-review progress:

@clawsweeper clawsweeper Bot added rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. and removed rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. labels Jul 19, 2026
@steipete steipete self-assigned this Jul 28, 2026
@clawsweeper clawsweeper Bot added rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. and removed rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. labels Jul 28, 2026
@openclaw-barnacle openclaw-barnacle Bot added the agents Agent runtime and tooling label Jul 28, 2026
@openclaw-barnacle openclaw-barnacle Bot removed the agents Agent runtime and tooling label Jul 28, 2026
@steipete
steipete merged commit 89b6d85 into openclaw:main Jul 28, 2026
113 of 117 checks passed
@steipete

Copy link
Copy Markdown
Contributor

Merged via squash.

github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Jul 29, 2026
…#110822)

* fix(scripts): bound android-release-signing exec operations

* fix(scripts): test Android signing timeouts

Co-authored-by: wanyongstar <[email protected]>

* fix(scripts): keep signing timeout internal

* docs(scripts): clarify signing timeout scope

* test(agents): isolate transport timeout proof

---------

Co-authored-by: Peter Steinberger <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

merge-risk: 🚨 availability 🚨 May cause crashes, hangs, restart loops, stalls, or process outages. P2 Normal backlog priority with limited blast radius. rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. scripts Repository scripts size: S status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants