fix(sandbox): 샌드박스 부팅 체인 무음 실패 대응 포팅 (#304) - #306
Merged
Conversation
main(1.20.9)에 반영한 수정을 미리 보기 레인에도 옮긴다. v1.21.0-preview.1 사용자도 동일한 무음 실패에 노출되어 있고, 조기 검증을 부탁한 사용자가 아무 단서 없이 막히는 상황은 피해야 한다. - citool.exe --refresh 를 <nul 로 호출. 이 명령이 작업 후 표준 입력을 기다리는 환경이 있으며(제보 환경에서 확인), batch 에서 블로킹될 수 있는 유일한 줄이라 그 자리에서 멈추면 바로 다음 줄의 Spork 실행에 영원히 도달하지 못한다. - 부팅 브레드크럼을 Data 마운트(영속)에 기록. Spork 가 뜨기 전에 실패하면 지금까지 아무 흔적도 남지 않았다. - Spork 가 비정상 종료 코드로 끝나면 콘솔에 안내 후 pause. - LogonCommand 를 C:\Windows\System32\cmd.exe /c 경유로 변경. .cmd 는 PE 이미지가 아니라 실행에 셸/파일 연결이 개입하는데, 그 경로가 깨지면 조용히 실행되지 않는다. - 앱 내 도움말 FAQ 에 자가 진단 안내 추가. - 회귀 테스트 6종(생성 스크립트 순수 ASCII 고정 포함). v1.21.x 고유의 AOT 변경(IL3000 억제, SporkJsonContext)과는 영역이 겹치지 않아 양쪽이 그대로 보존된다. Refs #304 Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
There was a problem hiding this comment.
Pull request overview
Ports the sandbox boot-chain “silent failure” mitigations (Issue #304) into the preview lane so v1.21.0-preview.1 users get actionable diagnostics when Windows Sandbox opens but Spork does not start.
Changes:
- Prevent potential
citool.exe --refreshstdin wait from blocking the batch chain by redirecting stdin fromnul. - Add persistent boot breadcrumbs (
tablecloth-boot.log) and show a console notice +pauseon abnormal Spork exit. - Update LogonCommand to invoke the startup script via absolute
C:\Windows\System32\cmd.exe /c, plus add FAQ guidance and regression tests.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| src/TableCloth.App/Components/Implementations/SandboxBuilder.cs | Adjusts Windows Sandbox LogonCommand invocation and hardens StartupScript.cmd generation with breadcrumbs + citool stdin redirection. |
| src/TableCloth.Test/SandboxStartupScriptTests.cs | Adds regression tests to lock in script ASCII-only constraint, citool stdin redirection, breadcrumb logging, and command ordering. |
| src/TableCloth/Help/manual.ko.html | Adds a Korean FAQ entry guiding users to self-diagnose and attach tablecloth-boot.log. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
+142
to
+145
| Assert.IsTrue(sacIndex >= 0 && citoolIndex >= 0 && sporkIndex >= 0, | ||
| "SAC 정책 / citool / spork 실행 중 하나가 스크립트에 없습니다."); | ||
| Assert.IsLessThan(citoolIndex, sacIndex, "SAC 레지스트리 설정이 citool refresh 보다 뒤에 있습니다."); | ||
| Assert.IsLessThan(sporkIndex, citoolIndex, "citool refresh 가 Spork 실행보다 뒤에 있습니다."); |
Comment on lines
+490
to
+492
| // 본 batch 는 UTF-8(Encoding.Default)로 기록되는데 cmd 는 이를 OEM 코드페이지로 읽는다. | ||
| // 따라서 **반드시 ASCII 만** 사용한다. 한글을 넣으면 바이트 정렬이 깨져 스크립트가 통째로 | ||
| // 무동작이 될 수 있다(이슈 #304 진단 중 실측). |
Comment on lines
+33
to
+37
| /// <summary> | ||
| /// 스크립트는 UTF-8(Encoding.Default)로 기록되지만 cmd 는 이를 OEM 코드페이지로 읽는다. | ||
| /// 비 ASCII 문자가 섞이면 바이트 정렬이 깨져 스크립트가 통째로 무동작이 될 수 있다 | ||
| /// (이슈 #304 진단 중 진단 하니스에서 실측한 현상). | ||
| /// </summary> |
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.
#305(main / 1.20.9)에 반영한 수정을 미리 보기 레인으로 옮깁니다.
v1.21.0-preview.1사용자도 동일한 무음 실패에 노출되어 있습니다. 조기 검증을 부탁드린 분들이 아무 단서 없이 막히는 상황은 피해야 해서 함께 포팅합니다.담긴 내용
citool.exe --refresh를<nul로 호출 — 이 명령이 작업 후 표준 입력을 기다리는 환경이 있고(이슈 [버그] Windows sandbox 실행되고 아무런 메시지 없이 Spork 설치 진행이 안됨 #304 제보 환경에서 확인·수정 후 해소 검증됨), batch 에서 블로킹될 수 있는 유일한 줄이라 여기서 멈추면 바로 다음 줄의 Spork 실행에 영원히 도달하지 못합니다pauseC:\Windows\System32\cmd.exe /c경유로 변경충돌 없음
v1.21.x고유의 AOT 변경(IL3000억제,SporkJsonContext)과 수정 영역이 겹치지 않아 양쪽이 그대로 보존됩니다. 패치는--3way로 깨끗하게 적용됐고, 포팅 후SandboxBuilder.cs의 main 대비 차이는 위 AOT 변경 2건뿐입니다.Refs #304
🤖 Generated with Claude Code