Skip to content

Use a custom error rather than SyntaxError in Python wrapper - #283

Open
frankier wants to merge 1 commit into
wilsonzlin:masterfrom
frankier:custom-syntaxerror-exception
Open

Use a custom error rather than SyntaxError in Python wrapper#283
frankier wants to merge 1 commit into
wilsonzlin:masterfrom
frankier:custom-syntaxerror-exception

Conversation

@frankier

Copy link
Copy Markdown

SyntaxError is for Python syntax errors and uses custom formatting relying on certain slots being set. This results in the error not being printed in some cases. This commit creates MinifyError which is thrown instead.

By the way, here's where SyntaxError is custom cased in CPython: https://github.com/python/cpython/blob/2ffab083782968a4d732738f4f1dff6bbd69d2b0/Lib/traceback.py#L1532-L1623

SyntaxError is for Python syntax errors and uses custom formatting relying on
certain slots being set. This results in the error not being printed in some cases.
This commit creates MinifyError which is thrown instead.
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

Successfully merging this pull request may close these issues.

1 participant