Skip to content

fix: Windows 경로 구분자 호환성 수정#1

Open
softdaddy-o wants to merge 1 commit into
dearcloud09:mainfrom
softdaddy-o:fix/windows-path-separator
Open

fix: Windows 경로 구분자 호환성 수정#1
softdaddy-o wants to merge 1 commit into
dearcloud09:mainfrom
softdaddy-o:fix/windows-path-separator

Conversation

@softdaddy-o

Copy link
Copy Markdown

Summary

  • validatePath()에서 하드코딩된 / 대신 path.sep을 사용하여 Windows/Unix 모두 지원

Problem

  • Windows에서 path.resolve()는 백슬래시(\)를 반환
  • 기존 코드는 슬래시(/)만 체크하여 Windows에서 모든 경로가 "Access denied: path outside graph directory" 오류 발생

Solution

// Before
if (!normalizedPath.startsWith(normalizedGraphPath + '/') ...

// After  
import { sep } from 'node:path';
if (!normalizedPath.startsWith(normalizedGraphPath + sep) ...

Test plan

  • Windows에서 read_page, update_page 등 정상 동작 확인
  • TypeScript 빌드 성공

🤖 Generated with Claude Code

validatePath()에서 '/' 대신 path.sep을 사용하여
Windows와 Unix 모두에서 정상 동작하도록 수정.

Windows에서 resolve()는 백슬래시(\)를 반환하는데,
기존 코드는 슬래시(/)만 체크하여 모든 경로 검증이 실패했음.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
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.

1 participant