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
It seems like the parser isn't properly handling a UTF-16 surrogate pair and tries to create an illegal character.
This precludes the use of the hy package (which implements the Hy language). It includes some exotic characters to test if a specific behavior of ast.parse occurs.
Traceback (most recent call last):
File "/home/robbie/bookshelf/main.py", line 1, in <module>
import hy, hy_main # type: ignore
File "/home/robbie/bookshelf/.venv/lib/python3.11/site-packages/hy/__init__.py", line 11, in <module>
import hy.importer # NOQA
File "/home/robbie/bookshelf/.venv/lib/python3.11/site-packages/hy/importer.py", line 13, in <module>
from hy.compiler import hy_compile
File "/home/robbie/bookshelf/.venv/lib/python3.11/site-packages/hy/compiler.py", line 14, in <module>
from hy.errors import HyCompileError, HyLanguageError, HySyntaxError
File "/home/robbie/bookshelf/.venv/lib/python3.11/site-packages/hy/errors.py", line 9, in <module>
from hy.compat import PYPY, PY3_13
File "/home/robbie/bookshelf/.venv/lib/python3.11/site-packages/hy/compat.py", line 22, in <module>
if "def" in ast.unparse(ast.parse("𝕕𝕖𝕗 = 1")):
File "/home/robbie/graalpy-24.2.1-linux-amd64/lib/python3.11/ast.py", line 50, in parse
return compile(source, filename, mode, flags,
File "<unknown>", line 1
𝕕𝕖𝕗 = 1
^
SyntaxError: invalid character '\udd55' (U+DD55)
The text was updated successfully, but these errors were encountered:
I tried to run hy's tests and I made a fix for this and few other things. I got the tests to pass 597 out of 609 tests. The REPL works, although readline support is limited (no autocomplete etc.). PR in #500
It seems like the parser isn't properly handling a UTF-16 surrogate pair and tries to create an illegal character.
This precludes the use of the
hy
package (which implements the Hy language). It includes some exotic characters to test if a specific behavior ofast.parse
occurs.The text was updated successfully, but these errors were encountered: