[Bug] UTF-8 byte boundary panic with multibyte characters in filenames

Resolved 💬 3 comments Opened Jan 5, 2026 by d-miyazawa Closed Jan 8, 2026

Bug Description
Japanese filename causes panic - UTF-8 byte boundary error

Error occurred when Claude tried to edit a file with Japanese characters in the filename.

Error message:
thread '<unnamed>' panicked at library\core\src\str\mod.rs:833:21:
byte index 8 is not a char boundary; it is inside '義' (bytes 6..9) of ト定義.md

Cause: Rust code slices filename string at byte index instead of character boundary. Japanese UTF-8 characters are 3 bytes each, so slicing at byte 8 falls inside character '義' (bytes 6-8).

Steps to reproduce:

  1. Create a file with Japanese filename (e.g., "〇〇定義.md")
  2. Ask Claude Code to edit that file
  3. Panic occurs

Expected: Claude Code should handle UTF-8 multibyte filenames correctly.

Workaround: Rename files to ASCII-only names.

OS: Windows
IDE: VS Code

Environment Info

  • Platform: win32
  • Terminal: vscode
  • Version: 2.0.76
  • Feedback ID: a7cf5384-4fdc-401d-a32c-4ad1ecb3bc80

Errors

[{"error":"Error: 1: 1 self signed certificate in certificate chain\nFailed Installing Extensions: anthropic.claude-code\n    at sX1 (B:/~BUN/root/claude.exe:1022:4019)\n    at async oX1 (B:/~BUN/root/claude.exe:1022:1623)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-01-05T02:14:23.821Z"}]

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗