-
Notifications
You must be signed in to change notification settings - Fork 67
Fixes for Django 3 #31
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
base: master
Are you sure you want to change the base?
Conversation
This looks like the fix that i need |
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.
Yesterday I made the same changes because reverse is not declared when evaluate the version of django if u use django 3. This package also works en python 3.4+
@ouhouhsami please merge this change! |
@@ -6,7 +6,8 @@ | |||
from django.forms.widgets import Media | |||
from django.utils.safestring import mark_safe | |||
|
|||
if DJANGO_VERSION[0] == 2: | |||
|
|||
if DJANGO_VERSION[0] in (2, 3): |
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.
To support also Django 4+ just use:
if DJANGO_VERSION[0] == 1:
from django.core.urlresolvers import reverse
else:
from django.urls import reverse
@@ -27,7 +27,7 @@ Quick start | |||
----------- | |||
|
|||
Requirements : | |||
* Django 1.7.4 or above. | |||
* Django 1.7.4 or above. (also 3.x) | |||
* Python 2.7 or 3.4 |
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.
Python 2.7 or 3.4+ should be fine and Django 4 either.
No description provided.