-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Migrate to Django2, drop Python2 support
- Loading branch information
1 parent
f438256
commit 0adce5c
Showing
70 changed files
with
382 additions
and
291 deletions.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,10 +2,10 @@ language: python | |
cache: pip | ||
|
||
python: | ||
- 2.7 | ||
- 3.4 | ||
- 3.5 | ||
- 3.6 | ||
- 3.7 | ||
|
||
addons: | ||
mariadb: '10.1' | ||
|
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,21 @@ | ||
# Generated by Django 2.1.3 on 2018-11-05 16:59 | ||
|
||
from django.db import migrations | ||
|
||
|
||
class Migration(migrations.Migration): | ||
|
||
dependencies = [ | ||
('daiquiri_archive', '0004_python3'), | ||
] | ||
|
||
operations = [ | ||
migrations.AlterModelOptions( | ||
name='archivejob', | ||
options={'ordering': ('start_time',), 'verbose_name': 'ArchiveJob', 'verbose_name_plural': 'ArchiveJobs'}, | ||
), | ||
migrations.AlterModelOptions( | ||
name='collection', | ||
options={'ordering': ('name',), 'verbose_name': 'Collection', 'verbose_name_plural': 'Collections'}, | ||
), | ||
] |
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,5 +1,3 @@ | ||
from __future__ import absolute_import, unicode_literals | ||
|
||
import logging | ||
import os | ||
import zipfile | ||
|
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 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,17 @@ | ||
# Generated by Django 2.1.3 on 2018-11-05 16:59 | ||
|
||
from django.db import migrations | ||
|
||
|
||
class Migration(migrations.Migration): | ||
|
||
dependencies = [ | ||
('daiquiri_auth', '0011_meta'), | ||
] | ||
|
||
operations = [ | ||
migrations.AlterModelOptions( | ||
name='profile', | ||
options={'ordering': ('user__last_name', 'user__last_name', 'user__username'), 'verbose_name': 'Profile', 'verbose_name_plural': 'Profiles'}, | ||
), | ||
] |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,21 @@ | ||
from django.conf.urls import url, include | ||
from django.urls import include, re_path | ||
from django.views.generic import TemplateView | ||
|
||
from .views import profile_update, profile_json, token, logout, password_change, password_set | ||
|
||
|
||
urlpatterns = [ | ||
url(r'^profile/$', profile_update, name='account_profile'), | ||
url(r'^profile.json/$', profile_json, name='account_profile_json'), | ||
url(r'^token/$', token, name='account_token'), | ||
url(r'^pending/$', TemplateView.as_view(template_name='account/account_pending.html'), name='account_pending'), | ||
re_path(r'^profile/$', profile_update, name='account_profile'), | ||
re_path(r'^profile.json/$', profile_json, name='account_profile_json'), | ||
re_path(r'^token/$', token, name='account_token'), | ||
re_path(r'^pending/$', TemplateView.as_view(template_name='account/account_pending.html'), name='account_pending'), | ||
|
||
# override login by allauth to remove wordpress cookies | ||
url(r"^logout/$", logout, name="account_logout"), | ||
re_path(r"^logout/$", logout, name="account_logout"), | ||
|
||
# include allauth patterns | ||
url(r'^password/change/$', password_change, name='account_change_password'), | ||
url(r'^password/change/done/$', TemplateView.as_view(template_name='account/password_change_done.html'), name='account_change_password_done'), | ||
url(r'^password/set/$', password_set, name='account_password_set'), | ||
url(r'^', include('allauth.urls')), | ||
re_path(r'^password/change/$', password_change, name='account_change_password'), | ||
re_path(r'^password/change/done/$', TemplateView.as_view(template_name='account/password_change_done.html'), name='account_change_password_done'), | ||
re_path(r'^password/set/$', password_set, name='account_password_set'), | ||
re_path(r'^', include('allauth.urls')), | ||
] |
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,18 +1,21 @@ | ||
from django.conf.urls import url, include | ||
from django.urls import include, path | ||
|
||
from rest_framework import routers | ||
|
||
from .views import UsersView | ||
from .viewsets import ProfileViewSet, GroupViewSet | ||
|
||
|
||
app_name = 'auth' | ||
|
||
router = routers.DefaultRouter() | ||
router.register(r'profiles', ProfileViewSet) | ||
router.register(r'groups', GroupViewSet) | ||
|
||
urlpatterns = [ | ||
# user management | ||
url(r'^users/', UsersView.as_view(), name='users'), | ||
path('users/', UsersView.as_view(), name='users'), | ||
|
||
# rest api | ||
url(r'^api/', include(router.urls)), | ||
path('api/', include(router.urls)), | ||
] |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,9 @@ | ||
from django.conf.urls import url | ||
from django.urls import re_path | ||
|
||
from .viewsets import ConeSearchView | ||
|
||
app_name = 'conesearch' | ||
|
||
urlpatterns = [ | ||
url(r'^api/(?P<resource>.+)/$', ConeSearchView.as_view(), name='search'), | ||
re_path(r'^api/(?P<resource>.+)/$', ConeSearchView.as_view(), name='search'), | ||
] |
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,17 @@ | ||
# Generated by Django 2.1.3 on 2018-11-05 16:59 | ||
|
||
from django.db import migrations | ||
|
||
|
||
class Migration(migrations.Migration): | ||
|
||
dependencies = [ | ||
('daiquiri_contact', '0004_meta'), | ||
] | ||
|
||
operations = [ | ||
migrations.AlterModelOptions( | ||
name='contactmessage', | ||
options={'ordering': ('-created', 'author'), 'verbose_name': 'Contact message', 'verbose_name_plural': 'Contact messages'}, | ||
), | ||
] |
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,18 +1,21 @@ | ||
from django.conf.urls import url, include | ||
from django.urls import include, path | ||
|
||
from rest_framework import routers | ||
|
||
from .views import contact, MessagesView | ||
from .viewsets import ContactMessageViewSet, StatusViewSet | ||
|
||
|
||
app_name = 'contact' | ||
|
||
router = routers.DefaultRouter() | ||
router.register(r'messages', ContactMessageViewSet, base_name='message') | ||
router.register(r'status', StatusViewSet, base_name='status') | ||
|
||
urlpatterns = [ | ||
url(r'^$', contact, name='contact'), | ||
url(r'^messages/', MessagesView.as_view(), name='messages'), | ||
path('', contact, name='contact'), | ||
path('messages/', MessagesView.as_view(), name='messages'), | ||
|
||
# rest api | ||
url(r'^api/', include(router.urls)), | ||
path('api/', include(router.urls)), | ||
] |
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
Oops, something went wrong.