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

Fixed exception when menu config is Unicode #206

Merged
merged 2 commits into from
Mar 11, 2014
Merged

Fixed exception when menu config is Unicode #206

merged 2 commits into from
Mar 11, 2014

Conversation

kane-c
Copy link
Contributor

@kane-c kane-c commented Mar 7, 2014

If the menu config is Unicode (e.g. from __future__ import unicode_literals or u'string'), the Suit menu will trigger an exception. Tested on Python 2.7 with Django 1.6.

If the menu config is Unicode (e.g. `from __future__ import unicode_literals` or `u'string'`), the Suit menu will trigger an exception. Tested on Python 2.7 with Django 1.6.
@darklow
Copy link
Owner

darklow commented Mar 7, 2014

As you can see travis tests with Django 1.4 failed, because django.utils.six module was introduced starting Django 1.4.2. Can you refactor to support Django 1.4 using?

One option is to refactor conditions to basestring and do something like:

try:
     basestring
 except NameError:
    basestring = (str, bytes)

Or raise minimum requirements to 1.4.2.
What do you think?

@kane-c
Copy link
Contributor Author

kane-c commented Mar 10, 2014

Ah right. Haven't had to deal with Django 1.4 in a while! Fixed in 95ba602

darklow added a commit that referenced this pull request Mar 11, 2014
Fixed exception when menu config is Unicode
@darklow darklow merged commit 54fbb1e into darklow:develop Mar 11, 2014
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

Successfully merging this pull request may close these issues.

None yet

2 participants