简体   繁体   中英

PHP 8 shell: can't input non-Ascii chars

After upgrading to PHP 8 in my WSL 2 I stuck with a strange problem: I can't input any non-ASCII character in shell, nor in interactive shell and PsySH.

I tried Russian, Serbian and some unicode symbols.

In simple words: if I try to input in shell " Привет " - russian letters just not get in terminal.

I have this behavior in Ubuntu 21.10 (bare metal) and 20.04 (WSL2). In Mac OS - everything fine.

Does anyone encounter this problem or have workaround for it?

You may give a try on Windows Terminal . Here I use Traditional Chinese as an example:

在此处输入图片说明

It works perfectly with WSL 2 and I think Russian should work in your case too.

It is a bug in PHP 8 version. https://bugs.php.net/bug.php?id=81598

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM