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

More helpful error messages #2

Closed
boxed opened this issue Jan 29, 2018 · 1 comment
Closed

More helpful error messages #2

boxed opened this issue Jan 29, 2018 · 1 comment

Comments

@boxed
Copy link

boxed commented Jan 29, 2018

Traceback (most recent call last):
  File "/Users/andersh/Projects/moz-sql-parser/tests/test_simple.py", line 113, in test_bad_select1
    self.assertRaises('Expected select', lambda: parse("se1ect A, B, C from dual"))
  File "/Users/andersh/Projects/moz-sql-parser/venv/lib/python2.7/site-packages/mo_testing/fuzzytestcase.py", line 69, in assertRaises
    cause=f
  File "/Users/andersh/Projects/moz-sql-parser/venv/lib/python2.7/site-packages/mo_logs/__init__.py", line 398, in error
    raise e
Except: ERROR: expecting an exception returning "Expected select" got something else instead

That's a deeply unhelpful message. You should print what that "something else" is.

@klahnakoski
Copy link
Owner

Thank you for this. I copied this issue to moz-sql-parser, who is responsible for the poor message.

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