Skip to content

fix(desktop): preserve completed SSH management results - #3552

Merged
jackwener merged 1 commit into
apache:mainfrom
M4n5ter:fix/runtime-host-ssh-frame-timeout
Aug 23, 2026
Merged

jackwener merged 1 commit into
apache:mainfrom
M4n5ter:fix/runtime-host-ssh-frame-timeout

Conversation

@M4n5ter

@M4n5ter M4n5ter commented Aug 23, 2026 •

Copy link
Copy Markdown
Member
English

Summary

Preserve a fully decoded Runtime Host setup or management frame when the SSH process misses its exit deadline. The SSH process is still terminated and reaped within the existing bounds; only the already-known remote operation outcome stops being replaced by a transport timeout.

Unframed upload and deployment-cleanup operations, malformed frames, and calls that time out before receiving a complete frame continue to fail.

Fixes #3546

Verification

  • npm --workspace @maka/desktop test — 1193 tests passed
  • npm --workspace @maka/desktop run typecheck
  • npm run lint
  • npm run format:check
  • npm run check:asf-headers
  • npx knip --workspace apps/desktop

AI use

  • No generative tool made a substantive contribution
  • Generative tooling made a substantive contribution

Tool(s) and scope: Codex implemented and verified the SSH management timeout fix under maintainer direction

Checklist

  • Tests cover the change and fail without it
  • Lint, format, typecheck and the affected suites pass locally

Does this PR entail a change in behavior?

  • Yes — described under Summary above
  • No
简体中文

摘要

当 Runtime Host setup 或 management frame 已完整解码后,即使 SSH 进程未能在退出期限内结束,也保留该远端操作结果。SSH 进程仍会按现有边界被终止并回收;本 PR 只防止已知的远端结果被传输收尾超时覆盖。

没有 frame 的上传与 deployment cleanup、畸形 frame,以及在收到完整 frame 前发生的超时仍然失败。

修复 #3546

验证

  • npm --workspace @maka/desktop test — 1193 项测试通过
  • npm --workspace @maka/desktop run typecheck
  • npm run lint
  • npm run format:check
  • npm run check:asf-headers
  • npx knip --workspace apps/desktop

AI 使用

Codex 在维护者指导下实现并验证了 SSH management timeout 修复

检查清单

  • 测试覆盖该变更,且在修复前会失败
  • lint、format、typecheck 与相关测试套件均已在本地通过
  • 本 PR 包含行为变更,已在摘要中说明

Treat a fully decoded remote management frame as the operation outcome even when the SSH transport misses its exit deadline. The transport is still terminated and reaped, while operations without a completed frame continue to fail on timeout.

Generated-by: Codex
@M4n5ter
M4n5ter marked this pull request as ready for review August 23, 2026 04:52

@jackwener jackwener left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed exact head 1e225cf. This resolves the shared teardown-timeout shape for both framed management and completed setup by returning a structured timeout outcome from the process waiter, while cleanup and upload remain fail-closed. The exact-head hosted test is terminal green. No P0-P2 findings. Two non-blocking test-shape follow-ups: wait for the fake PTY data listener before emitData for consistency, and consider avoiding a production factory timeout option used only by tests.

@jackwener
jackwener merged commit d774ae1 into apache:main Aug 23, 2026
1 check passed
@M4n5ter
M4n5ter deleted the fix/runtime-host-ssh-frame-timeout branch August 24, 2026 03:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Runtime Host SSH management: a fully received frame is discarded when the SSH process times out

2 participants