avian2 / unidecode

ASCII transliterations of Unicode text - GitHub mirror
https://pypi.python.org/pypi/Unidecode
GNU General Public License v2.0
516 stars 62 forks source link

Input() Method #80

Closed OurCodeBase closed 2 years ago

OurCodeBase commented 2 years ago

Hello Sir

As you said in your documentation I used the code, and the code is working It successfully decode unicode escape characters.

>> from unidecode import unidecode
>> value="\u0048\u0065\u006c\u006c\u006f"
>> print(unidecode(value))
Hello

Problem

When i used input as a value unidecode prints the same value as i entered.

>> from unidecode import unidecode
>> value=input("Input: ")
Input: \u0048\u0065\u006c\u006c\u006f
>> print(unidecode(value))
\u0048\u0065\u006c\u006c\u006f
avian2 commented 2 years ago

Unidecode does not decode escape sequences. You are using a wrong library. See the "Why does Unidecode not replace \u and \U backslash escapes in my strings?" frequently asked question in the README.

OurCodeBase commented 2 years ago

Unidecode does not decode escape sequences. You are using a wrong library. See the "Why does Unidecode not replace \u and \U backslash escapes in my strings?" frequently asked question in the README.

Hello @avian2

I can understand what you told. But sir our tool was successfully worked with a defined string of escape sequences. The only problem appears with input() method. If you can, help me !