openclaw - 💡(How to fix) Fix edit tool corrupts Danish characters (æ, ø, å) due to Windows-1252 encoding [2 comments, 2 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
openclaw/openclaw#69636Fetched 2026-04-22 07:49:52
View on GitHub
Comments
2
Participants
2
Timeline
5
Reactions
0
Timeline (top)
commented ×2closed ×1mentioned ×1subscribed ×1

Fix Action

Fix / Workaround

Workaround: Use write tool instead of edit for files containing Danish/special characters.

Workaround: Brug write værktøjet i stedet for edit til filer med danske/specialtegn.

RAW_BUFFERClick to expand / collapse

Bug Report / Fejlrapport

English

Bug: The edit tool uses Windows-1252 encoding instead of UTF-8 when reading and writing files. This corrupts Danish characters (æ, ø, å) and other non-ASCII characters.

Steps to reproduce:

  1. Create a file with Danish characters (e.g., HB_LOG.md with æ, ø, å)
  2. Use the edit tool to make a change
  3. The file now contains corrupted characters

Expected behavior: Files should be read and written using UTF-8 encoding, preserving all Unicode characters.

Workaround: Use write tool instead of edit for files containing Danish/special characters.

Environment:

  • OS: Windows 10
  • OpenClaw: 2026.4.15
  • Node.js: v24.14.0

Dansk

Fejl: edit værktøjet bruger Windows-1252 encoding i stedet for UTF-8 når det læser og skriver filer. Dette ødelægger danske tegn (æ, ø, å) og andre ikke-ASCII tegn.

Reproduktion:

  1. Opret en fil med danske tegn (f.eks. HB_LOG.md med æ, ø, å)
  2. Brug edit værktøjet til at lave en ændring
  3. Filen indeholder nu corrupterede tegn

Forventet adfærd: Filer bør læses og skrives med UTF-8 encoding, som bevarer alle Unicode-tegn.

Workaround: Brug write værktøjet i stedet for edit til filer med danske/specialtegn.

Miljø:

  • OS: Windows 10
  • OpenClaw: 2026.4.15
  • Node.js: v24.14.0

extent analysis

TL;DR

The edit tool should be configured to use UTF-8 encoding instead of the default Windows-1252 to prevent corruption of non-ASCII characters.

Guidance

  • Verify the encoding used by the edit tool by checking its configuration or documentation to see if there's an option to specify the encoding.
  • Consider updating the edit tool to a version that supports UTF-8 encoding, if available.
  • As a temporary workaround, use the write tool instead of the edit tool for files containing special characters, as suggested in the issue report.
  • Test the workaround with different types of files and characters to ensure it works as expected.

Example

No code snippet is provided as the issue does not mention specific code or APIs.

Notes

The issue seems to be specific to the edit tool and its configuration, and the provided workaround using the write tool may not be a permanent solution. Further investigation into the edit tool's capabilities and configuration is needed.

Recommendation

Apply the workaround by using the write tool instead of the edit tool for files containing special characters, as it is a safe and temporary solution until the edit tool is updated or configured to use UTF-8 encoding.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

openclaw - 💡(How to fix) Fix edit tool corrupts Danish characters (æ, ø, å) due to Windows-1252 encoding [2 comments, 2 participants]