Skip to content

fix(exec): default to GBK encoding on Windows (#50519)#1

Merged
Yaohua-Leo merged 1 commit intomainfrom
fix/50519-windows-encoding-gbk
Mar 20, 2026
Merged

fix(exec): default to GBK encoding on Windows (#50519)#1
Yaohua-Leo merged 1 commit intomainfrom
fix/50519-windows-encoding-gbk

Conversation

@Yaohua-Leo
Copy link
Copy Markdown
Owner

Summary

Fixes openclaw#50519 - Windows exec tool produces garbled Chinese characters due to hardcoded UTF-8 encoding

Changes

  • On Windows, cmd.exe outputs in GBK/CP936 by default, not UTF-8
  • Changed default encoding from UTF-8 to GBK for Windows platform
  • Added encoding option to allow override when needed

Testing

✅ Docker sandbox test passed

- On Windows, cmd.exe outputs in GBK/CP936 by default, not UTF-8
- Changed default encoding from UTF-8 to GBK for Windows platform
- Added encoding option to allow override when needed
- This fixes garbled Chinese characters in exec tool output on Windows

Fixes openclaw#50519
@Yaohua-Leo Yaohua-Leo merged commit ab077da into main Mar 20, 2026
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.

[Bug]: Windows exec tool produces garbled Chinese characters due to hardcoded UTF-8 encoding

1 participant