Repository navigation
fix: bootstrap device Herdr before connecting its services - #1702
Merged
Merged
Conversation
yansfil
marked this pull request as ready for review
October 26, 2026 15:01
This was referenced Oct 26, 2026
yansfil
added a commit
that referenced
this pull request
Oct 27, 2026
…1722) Related: #1702, #1700 ## Summary - 기기에 서버가 없어도 Herdr가 고른 소켓을 유지하고, 못 읽으면 기기의 소켓·세션 환경 설정을 따릅니다. - 서버 시작 실패의 Retry는 연결을 다시 열어 pane 서비스와 터미널 경로도 복구합니다. - 보내기로 한 Herdr의 전송 실패는 기기 행의 설치 실패로 전달하고, 이전 유효 사본과 링크를 보존합니다. ## Review - **판단해 주세요**: 시작 실패 뒤 연결 전체를 다시 여는 복구 범위와, 필수 Herdr 전송 실패의 재시도 경로. - **조심해서 볼 파일**: `runtime/kit.rs`의 연결 복구, `ssh/host.rs`의 전송 오류, `hide-host/src/kit.rs`의 링크 교체 순서. - 기존 연결 worker를 사용하며 Runtime 잠금이나 session-sync에 I/O를 추가하지 않습니다. ## Evidence - **확인한 것**: 세 항목 모두 현재 main에서 확인했고, 수정 전 회귀 테스트가 각각 실패했습니다. - **확인한 것**: host/node 및 core Retry 테스트, 플랫폼 소켓 선택 검사와 전용 계정·소켓의 실제 SSH 6개가 통과했습니다. - **확인한 것**: 실패 뒤 재연결에서 pane 소켓 접속, 터미널 제어권, 입력한 명령의 출력까지 확인했습니다. - **확인한 것**: 최종 head의 계획된 CI lane 전체와 `verify`가 통과했습니다. 세 OS 계약, Rust, 원격 SSH, Linux/Windows 웹 및 macOS/Windows 데스크톱 E2E를 포함합니다. - **한계**: 별도 core-move 검사 두 개는 기존 이슈와 같은 오류 뒤 CI 재시도에서 통과했습니다. 아래 기록에서 구분합니다. - **확인하지 못한 것**: 실제 외부 기기와 네이티브 기기 행 클릭은 검증하지 않았습니다. - 화면 파일과 문구 변경은 없습니다. <details><summary>Verification record</summary> Base: `16f2f066b09b2ec7d95a3ede3ea7859c3447e092`. Head: `f5274f1d278c582a7ad07786050172171a5e2bdf`. CI checkout: `69892251f4591d0ae165c389ccc7e2d5ed866ea9`, the merge of that head with main `c88c8c470e14a712245fa6e3cc27c2faedc7aada`. The three original regression checks failed before production fixes. Focused hide-host (140 unit + 67 integration) and hide-node (214 unit + 1 integration) suites passed, with existing ignored tests unchanged. The core failed-start retry regression and platform host tests passed. At preceding head `9df8bf1b3`, the complete platform integration rerun passed 233 tests (2 existing ignored). The final resolver change passed 22 platform host tests and the pinned binary socket/session comparison; that comparison runs on every OS contract lane. All 6 isolated real-SSH bootstrap tests passed serially on the final candidate, including environment socket/session selection, required upload failure/re-send and usable terminals after failed startup. The initial platform and parallel SSH attempts hit ENOSPC; the parent freed space, and their final reruns above passed. The pinned schema contract, core machine-boundary check, pin single-source, attribution, design contract and diff whitespace checks passed. Full local lanes are deferred to CI at the parent's request because disk space is shared with concurrent work. Independent Code and Fidelity re-reviews passed the final head with no Fix now findings; the initial Code review's environment-session gap is resolved. Optional follow-up: direct pin-file upload and final rename fault injection; the current required-error propagation and preservation checks cover their shared failure path. Full final-head CI run [40445618782](https://github.com/with-hide/hide/actions/runs/40445618782) and its required `verify` passed. Executed lanes: Rust (5,822 tests plus 7 separate checks), Windows workspace/checks, remote mailbox/SSH, OS and SDK contracts on macOS/Linux/Windows, Linux web E2E (383), Windows web E2E (64), macOS desktop E2E (117) and Windows desktop E2E (19). All 6 real SSH bootstrap tests and the pinned socket/session comparison on every OS passed on their first attempt. All web and desktop E2E logs reported no flaky tests. Package and agent-journey lanes were not selected by the plan; this PR does not claim they ran. The remote lane also classified two core-move tests as flaky after helper-readiness timeouts; both passed their one CI retry. The same failures were already tracked from main in [#1663](#1663) and [#1428](#1428); CI appended this run to those issues. Issue #1428 is past its recorded expiry; this PR does not claim those two flows are stable. </details>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Related: mission-6 (local short PRD)
Summary
Review
hided/src/herdr_handoff.rs- 서버 준비 확인, 시작 실패 정리와 계정으로 소유권 이전.hide-node/src/ssh/host.rs,herdr-core/src/runtime/hosts.rs- kit 실행 순서와 대기 중 작업 처리.Evidence
Verification record
67bb2837b8f34bcf1260f39ad5ff1eac0b6daffa4c05d7681426621af07fa8a60e596a98004ee661bash scripts/verify-cargo.sh lint: PASS.bash scripts/verify-cargo.sh test -- --test-threads=8: PASS on product commit6a56a773b. 5847 passed, 120 ignored. The subsequent changes reclaim test servers by their private socket, register reported PIDs earlier and update the support table.bash scripts/verify-web.sh: PASS. Web 2165 passed, 1 skipped; desktop 260 passed, 4 skipped.kit_reinstall; English and Korean (125% text scale) were checked.6a56a773bthen passed all remote groups (6/23/44/2/8 tests), including the Herdr 0.8.2 device handoff, without retry. The initial upload slowdown is not conclusively attributed. Final-head CI is tracked in the PR checks. No test timeout, assertion or parallelism was relaxed.