Repository navigation
Conversation
Path.write_text() defaults to the locale encoding. On Windows that is cp1252, and the report contains the ✅/❌ correctness markers from TASK_TEMPLATE. As soon as at least one task is marked incorrect, the run raises UnicodeEncodeError on the final write_text() call, and the entire paid-for evaluation result is discarded. PYTHONIOENCODING does not help (it governs stdio, not pathlib). Write the report with an explicit UTF-8 encoding so the result survives on any locale. Fixes anthropics#1669
|
Added independent verification of the failure mode, plus a sweep for sibling exposure. Reproduced on a Windows machine with a non-UTF-8 locale (cp936): The report content is Sibling sweep in |
Fixes #1669.
Path.write_text()defaults to the locale encoding. On Windows that is cp1252, and the report contains the ✅/❌ correctness markers fromTASK_TEMPLATE. As soon as at least one task is marked incorrect, the run raisesUnicodeEncodeErroron the finalwrite_text()call, and the entire paid-for evaluation result is discarded.PYTHONIOENCODINGdoes not help (it governs stdio, not pathlib).Pass an explicit
encoding="utf-8"so the report survives on any locale.