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

Appears to be incompatible with sqlparse version 0.2.0. #852

Closed
mlockett42 opened this issue Jul 20, 2016 · 9 comments
Closed

Appears to be incompatible with sqlparse version 0.2.0. #852

mlockett42 opened this issue Jul 20, 2016 · 9 comments

Comments

@mlockett42
Copy link

I get the following exception and stack trace on every page I try to view:

Traceback:
File "/usr/local/lib/python2.7/dist-packages/django/core/handlers/base.py" in get_response
  223.                 response = middleware_method(request, response)
File "/usr/local/lib/python2.7/dist-packages/debug_toolbar/middleware.py" in process_response
  129.                 panel.generate_stats(request, response)
File "/usr/local/lib/python2.7/dist-packages/debug_toolbar/panels/sql/panel.py" in generate_stats
  192.                     query['sql'] = reformat_sql(query['sql'])
File "/usr/local/lib/python2.7/dist-packages/debug_toolbar/panels/sql/utils.py" in reformat_sql
  27.     return swap_fields(''.join(stack.run(sql)))
File "/usr/local/lib/python2.7/dist-packages/sqlparse/engine/filter_stack.py" in run
  29.             stream = filter_.process(stream)

Exception Type: TypeError at /admin/mediasources/document/
Exception Value: process() takes exactly 3 arguments (2 given)

I can workaround by forcing the version to 0.1.19 via
sqlparse==0.1.19
in the requirements file.

sqlparse 0.2.0 was released today

@aaugustin
Copy link
Contributor

If someone feels like investigating how to update the DDT to work with sqlparse 0.2.0 that would be even better :-)

@gabber7
Copy link

gabber7 commented Jul 20, 2016

@tctimmeh
Copy link

+1. Upgrading my dev site today with DDT enabled made the site suddenly unusable.

@jllorencetti
Copy link

jllorencetti commented Jul 20, 2016

Well, that's funny haha

@valignatev
Copy link
Contributor

@dirtycoder you was the first though :)

@browniebroke
Copy link
Member

Maybe also update minimum version of sqlparse>=0.2.0 in setup.py?

valignatev added a commit to valignatev/django-debug-toolbar that referenced this issue Jul 20, 2016
@valignatev
Copy link
Contributor

@browniebroke good idea since it won't work with an old version anymore. I've updated PR accordingly.

@jllorencetti
Copy link

I don't see much sense in both of us doing the same stuff over and over so I'll close my PR.

aaugustin added a commit that referenced this issue Jul 21, 2016
Fix #852, anyway this parameter never used
@andialbrecht
Copy link
Contributor

Sorry guys, I've forgot to mention this change in the release notes for sqlparse ;)

nikolas added a commit to ccnmtl/uelc that referenced this issue Jul 23, 2016
we need to wait for a new release of django-debug-toolbar to use the new sqlparse: django-commons/django-debug-toolbar#852
ryneeverett pushed a commit to ryneeverett/django-debug-toolbar that referenced this issue Oct 2, 2016
ryneeverett pushed a commit to ryneeverett/django-debug-toolbar that referenced this issue Oct 2, 2016
ryneeverett pushed a commit to ryneeverett/django-debug-toolbar that referenced this issue Oct 2, 2016
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

8 participants