We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Describe the bug Using token_matching with index None generates an TypeError exception
token_matching
None
TypeError
To Reproduce Executing the following code
import sqlparse p = sqlparse.parse("SELECT id FROM table")[0] p.token_matching([lambda x: isinstance(x, sqlparse.sql.Token)], None)
generates an exception
Traceback (most recent call last): File "/repositories/github/sqlparse/t.py", line 4, in <module> p.token_matching(lambda x: isinstance(x, sqlparse.sql.Token), None) File "/repositories/github/sqlparse/sqlparse/sql.py", line 277, in token_matching return self._token_matching(funcs, idx)[1] TypeError: 'NoneType' object is not subscriptable
Expected behavior token_matching should return None
Versions (please complete the following information):
The text was updated successfully, but these errors were encountered:
Successfully merging a pull request may close this issue.
Describe the bug
Using
token_matching
with indexNone
generates anTypeError
exceptionTo Reproduce
Executing the following code
generates an exception
Expected behavior
token_matching
should return NoneVersions (please complete the following information):
The text was updated successfully, but these errors were encountered: