---
title: "Windows 검증 경로·환경 호환성과 NTFS migration identity"
type: "debugging"
status: "reviewed"
memory_type: "semantic"
last_updated: "2026-10-10"
last_verified: "2026-10-10"
description: "Windows 테스트 구성 오류와 실제 NTFS inode 정밀도 결함을 구분한 원인·수정·회귀 검증 기준."
aliases: ["Windows gate failure", "NTFS inode precision"]
keywords: [Windows, NTFS, inode, BigInt, migration, fileURLToPath, LOCALAPPDATA, PowerShell, PSModulePath, TAP, 실패진단, 교차플랫폼]
importance: 5
confidence: "high"
evidence_refs:
  - "file:src/migration-copy.js"
  - "file:src/io/private-permissions.js"
  - "file:test/hook.test.js"
  - "file:test/isolated-env.test.js"
  - "file:test/windows-runner.test.js"
  - "file:test/maintenance-preservation-regressions.test.js"
  - "file:scripts/windows-runner/verify-release.ps1"
  - "file:docs/plans/2026-10-10-purpose-defect-remediation.md"
---

# Windows 검증 경로·환경 호환성과 NTFS migration identity

## 직접 확인한 원인과 수정

| 원인 | 관측 | 수정과 유지할 계약 |
|---|---|---|
| file URL.pathname을 파일 경로로 사용 | Windows child Node가 C:\C:\...를 실행하여 MODULE_NOT_FOUND | fileURLToPath로 변환. 같은 CLI 경로 구성8곳 보정. |
| fixture가 XDG_DATA_HOME만 분리 | Windows의 LOCALAPPDATA 우선 규칙으로 다른 설치 의도·state를 공유하거나 잘못된 .data 경로를 검사 | LOCALAPPDATA도 분리하고 finally에서 복구. 제품의 provider 선택 유지 동작은 바꾸지 않음. |
| POSIX 전용 fake npm | Windows에서 확장자 없는 #!/bin/sh mock 실행 불가 | 동일한 view argv 계약을 npm.cmd로 검사. |
| PS7 모듈 경로/cache를 5.1에 전달 | Get-Acl의 Microsoft.PowerShell.Security autoload 실패가 ACL 검사 실패로 표시됨 | 기존 windowsPowerShellEnvironment로 edition-specific 변수를 정리하고 test cache를 host별로 분리. 실제 부모 SDDL 비교 유지. |
| NTFS inode를 Number로 읽은 뒤 BigInt 변환 | 이미 반올림된 inode를 exact handle ID와 비교해 정상 migration source를 변경된 것으로 거부 | source/destination lstat 및 handle.stat을 bigint:true로 통일. identity/realpath/변경시각 검사를 완화하지 않음. |
| 실제 오류 저장보다 pending matrix throw가 먼저 실행 | 실패한 test 이름이 사라지고 D04:pending만 먼저 표시됨 | helper 실패 정보를 안전하게 저장한 뒤 incomplete matrix 거부. |

NTFS 진단의 임시32파일 중17개에서 Number inode와 exact BigInt inode가 달랐다. 기존 원본 파일은 거부·보존되는 상황이었으며 데이터 손실을 확인한 것은 아니다. 회귀 검사는32-file capture와 정확한 bytes·unchanged 확인, 실제 원본 변경의 거부, 바이너리 및 ordinary .lock-named directory 데이터의 migration을 포함한다.

## 검증과 범위

2026-10-10 구현 기준 commit8f28530dd70011725fa9bf4764038d6777381f87은 미공개0.26.1이다. Linux source940/927PASS/0FAIL/13knownWindowsSKIP 및 installed580/567PASS/0FAIL/13knownWindowsSKIP, Windows PS7 package590/577PASS/0FAIL/13knownSKIP를 확인했다. Native migration6개 및 PS7 ACL/환경/validator3개 집중 검사가 통과했다. Source/Tarball SHA를 혼합하지 않는다.

D08 Windows 경로 추적 검사는 실제 Node 파일 수정·읽기와 controlled shell post-event를 사용한다. POSIX에서는 실제 Bash/Perl/rg 실행을 유지한다. 이를 Windows POSIX 도구 실행이나 실제 agent app E2E로 주장하지 않는다.

검증표의 한 test file exit1은 연결된 여러 계약 행을 fail로 만든다. 여러 행을 여러 독립 assertion 실패로 해석하지 않는다. 실제 validator 회귀 검사는 failed-name/file 보존과 helper success여도 pending required rows 거부를 모두 확인한다.

## 남은 불확실성

최초30-process registry 실패1회는 추가 단독·깊은 격리 경로 및 관측 full에서 재현되지 않았다. 최초 assertion은 남은 요약으로 확정할 수 없으므로 근본 원인 해결로 주장하지 않는다. 실제 app cwd와 실제 OpenCode app 검증은 native/component 검사와 별도다. 이 페이지는 제품에 이식 가능한 사실만 담고 host·credential·release 운영 근거는 ops wiki에 둔다.
