-
Notifications
You must be signed in to change notification settings - Fork 45
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
Updated to work around StrAndUnicode removal in 1.7 (fixes #61) #62
Conversation
I will take a look this weekend. I'm sorry I can't get it sooner. |
from django.utils.encoding import python_2_unicode_compatible | ||
|
||
@python_2_unicode_compatible | ||
class StrAndUnicode: |
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.
This should be a new-style class
I'm not 100% sure the monkeypatch is needed in 1.7, since Django started supporting the |
Updated based on comments. I can play with zamboni under Django 1.7 and without the monkey patch. I agree, it looks like it isn't needed now that there's this. |
Turns out the monkey patching is still needed. I found cases where forms rendered incorrectly without it. I didn't dig much further than that. |
Can you post the cases you found? I'll dig more this weekend but I want to understand why the code has to be there. Sent from my phone, please excuse the occasional typo. On Tue, Oct 21, 2014 at 7:15 PM, Rob Hudson notifications@github.com
|
I simply commented out the monkey patch and loaded a view with a form in zamboni and saw a bunch of unrendered HTML for the form elements. I'd have to look at how |
I'm wondering if we can get this merged? |
OK, I think I see what's happening: if I'm going to merge this as-is but eventually I'd like to not have the extra class with the runtime basis. Python is cray but that's a little far. |
Updated to work around StrAndUnicode removal in 1.7 (fixes #61)
No description provided.