-
Notifications
You must be signed in to change notification settings - Fork 65
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
Make sekizai tests work on Django 1.11 #75
Conversation
Django 1.11 doesn't allow Context classes to be used as, well, Contexts. Use a dictionary instead.
Great PR. Le's merge it. |
sekizai/tests.py
Outdated
ctx = ctx or {} | ||
return render_to_string(tpl, ctxclass(ctx)) | ||
ctx = dict(ctx) if ctx else {} | ||
if ctxclass == SekizaiContext: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
use issubclass(ctxclass, SekizaiContext)
Ok used |
Thank you for your pull request. Unfortunately, right now I'm in the process of transferring this repository to the divio organization (developers of django CMS) on Github, so it might take a little while for this to get accepted. Thank you for your patience. |
I submitted #79 to drop support for Django < 1.11 and add support for Django 1.11+. Maybe you could repurpose this branch to make the pycodestyle changes? |
The main issue is that Django 1.11 no longer allows Contexts to be used as, er, contexts.
It also required dealing with pep8's rename to pycodestyle.