-
Notifications
You must be signed in to change notification settings - Fork 20
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
Upgrade to Django 1.9 #283
Merged
+255
−953
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,15 @@ | ||
-r ./common.txt | ||
|
||
django-debug-toolbar | ||
django-debug-toolbar==1.4 | ||
django-profiler==2.0 | ||
|
||
#testing. | ||
coverage==3.7.1 | ||
#testing. | ||
coverage==4.0.3 | ||
webtest==2.0.9 | ||
django-webtest==1.7.5 | ||
model_mommy==1.2 | ||
mock==1.0.1 | ||
python-dbusmock==0.8 | ||
django-webtest==1.7.9 | ||
model_mommy==1.2.6 | ||
mock==2.0.0 | ||
python-dbusmock==0.16.3 | ||
|
||
#interactive interpreter for debugging | ||
ipython | ||
ipython==4.0.3 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1,4 @@ | ||
# Roundware Server is released under the GNU Affero General Public License v3. | ||
# See COPYRIGHT.txt, AUTHORS.txt, and LICENSE.txt in the project root directory. | ||
|
||
# Contains Roundware DRF REST API V2 signals. | ||
from __future__ import unicode_literals | ||
from django.contrib.auth import get_user_model | ||
from django.db.models.signals import post_save | ||
from rest_framework.authtoken.models import Token | ||
import logging | ||
|
||
logger = logging.getLogger(__name__) | ||
|
||
def create_auth_token(sender, instance=None, created=False, **kwargs): | ||
""" | ||
Create an access Token for every new user | ||
""" | ||
if created: | ||
Token.objects.create(user=instance) | ||
|
||
post_save.connect(create_auth_token, get_user_model) | ||
default_app_config = 'api2.apps.RoundwareApi2Config' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
# Roundware Server is released under the GNU Affero General Public License v3. | ||
# See COPYRIGHT.txt, AUTHORS.txt, and LICENSE.txt in the project root directory. | ||
|
||
from django.apps import AppConfig | ||
|
||
class RoundwareApi2Config(AppConfig): | ||
name = 'api2' | ||
|
||
def ready(self): | ||
import roundware.api2.signals |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
# Roundware Server is released under the GNU Affero General Public License v3. | ||
# See COPYRIGHT.txt, AUTHORS.txt, and LICENSE.txt in the project root directory. | ||
|
||
# Contains Roundware DRF REST API V2 signals. | ||
from __future__ import unicode_literals | ||
from django.contrib.auth import get_user_model | ||
from django.db.models.signals import post_save | ||
from rest_framework.authtoken.models import Token | ||
import logging | ||
|
||
logger = logging.getLogger(__name__) | ||
|
||
def create_auth_token(sender, instance=None, created=False, **kwargs): | ||
""" | ||
Create an access Token for every new user | ||
""" | ||
if created: | ||
Token.objects.create(user=instance) | ||
|
||
post_save.connect(create_auth_token, get_user_model) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
Please add the standard licensing lines that should be in all code files (including
__init.py__
above)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.
Good point. Now that I look around, however, it seems that many files are missing these licensing lines. If I make other changes to this pull request, I will certainly address this. For the more general case, see #284
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.
cool...since this PR doesn't pass Travis.ci, there will certainly need to be some updates, so you can add these changes then, as you say.