Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Invalid Syntax #9

Open
roberto-arista opened this issue Feb 23, 2024 · 1 comment
Open

Invalid Syntax #9

roberto-arista opened this issue Feb 23, 2024 · 1 comment
Assignees

Comments

@roberto-arista
Copy link

Hey @jenskutilek!

@typemytype and I are planning to improve the validation of code of extension listed in Mechanic. This function:
https://github.com/jenskutilek/RFUnicodeInfo/blob/master/UnicodeInfo.roboFontExt/lib/jkUnicode/tools/py2.py

Triggers the following exception:

  File "/Users/robertoarista/Documents/Repositories/extensionBundle/.extensions_cache/RFUnicodeInfo-master/UnicodeInfo.roboFontExt/lib/jkUnicode/tools/py2.py", line 5
    return eval("u'\U%08X'" % code)
                            ^
SyntaxError: (unicode error) 'unicodeescape' codec can't decode bytes in position 2-3: truncated \UXXXXXXXX escape

Could you help us fix it?

@jenskutilek
Copy link
Owner

Hi Roberto, that part of the code is a Python 2 compatibility function that is never called on Python 3.

The jkUnicode module has since been updated and this code was removed. I have now updated the bundled jkUnicode version in the UnicodInfo extension.

It should work for now, but the UI logic needs some love too. I'll see that I can find the time to update it.

@jenskutilek jenskutilek self-assigned this Feb 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants