You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Version python-rapidjson==1.14.
To reproduce: import rapidjson; rapidjson.loads('"\ud83c"')
Error message: UnicodeEncodeError: 'utf-8' codec can't encode character '\ud83c' in position 1: surrogates not allowed
\ud83c is not a valid unicode code point. Currently deserialization fails. This is uncommon behavior compared to other JSON parsers which deserialize it as an ASCII literal.
Consider the default Python JSON parser which returns the following given a valid and invalid unicode code point.
>>> rapidjson.loads('"\u266a"')
'♪'
>>> rapidjson.loads('"\ud83c"')
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
UnicodeEncodeError: 'utf-8' codec can't encode character '\ud83c' in position 1: surrogates not allowed
The text was updated successfully, but these errors were encountered:
Version
python-rapidjson==1.14
.To reproduce:
import rapidjson; rapidjson.loads('"\ud83c"')
Error message:
UnicodeEncodeError: 'utf-8' codec can't encode character '\ud83c' in position 1: surrogates not allowed
\ud83c
is not a valid unicode code point. Currently deserialization fails. This is uncommon behavior compared to other JSON parsers which deserialize it as an ASCII literal.Consider the default Python JSON parser which returns the following given a valid and invalid unicode code point.
As opposed to rapidjson which returns:
The text was updated successfully, but these errors were encountered: