Project

General

Profile

Actions

Bug #20958

closed

fix ENV.keys encoding on windows

Bug #20958: fix ENV.keys encoding on windows

Added by YO4 (Yoshinao Muramatsu) over 1 year ago. Updated 1 day ago.

Status:
Closed
Assignee:
Target version:
-
[ruby-core:120277]
Tags:

Description

github PR#12368
ENV.keys elements contain UTF-8 byte sequences with locale encoding on Windows.

> ruby -v -e "p ENV.keys.last; p ENV.keys.last.encoding; p ENV.keys.last.dup.force_encoding('utf-8')"
ruby 3.3.5 (2024-09-03 revision ef084cc8f4) [x64-mingw-ucrt]
"\x{E383}\x{86E3}\x{82B9}\x{E383}\x88"
#<Encoding:Windows-31J>
"ใƒ†ใ‚นใƒˆ"

This patch changes the encoding of ENV.keys to utf-8 on Windows.

Updated by hsbt (Hiroshi SHIBATA) over 1 year ago Actions #1

  • Tags set to win

Updated by hsbt (Hiroshi SHIBATA) 1 day ago Actions #2

  • Assignee set to windows

Updated by hsbt (Hiroshi SHIBATA) 1 day ago Actions #3 [ruby-core:126155]

  • Status changed from Open to Closed

Updated by hsbt (Hiroshi SHIBATA) 1 day ago Actions #4

  • Backport changed from 3.1: UNKNOWN, 3.2: UNKNOWN, 3.3: UNKNOWN to 3.3: WONTFIX, 3.4: REQUIRED, 4.0: REQUIRED
Actions

Also available in: PDF Atom