Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
beat.web
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
54
Issues
54
List
Boards
Labels
Milestones
Merge Requests
2
Merge Requests
2
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
beat
beat.web
Commits
c3223e69
Commit
c3223e69
authored
Apr 23, 2016
by
André Anjos
💬
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[many] Fixes for Django 1.9.x compatibility
parent
a03bc6a6
Changes
15
Hide whitespace changes
Inline
Side-by-side
Showing
15 changed files
with
29 additions
and
50 deletions
+29
-50
beat/web/accounts/apps.py
beat/web/accounts/apps.py
+3
-2
beat/web/accounts/urls.py
beat/web/accounts/urls.py
+3
-5
beat/web/algorithms/apps.py
beat/web/algorithms/apps.py
+1
-1
beat/web/attestations/apps.py
beat/web/attestations/apps.py
+1
-3
beat/web/backend/api.py
beat/web/backend/api.py
+0
-8
beat/web/dataformats/apps.py
beat/web/dataformats/apps.py
+3
-6
beat/web/experiments/api.py
beat/web/experiments/api.py
+6
-6
beat/web/experiments/apps.py
beat/web/experiments/apps.py
+2
-4
beat/web/libraries/apps.py
beat/web/libraries/apps.py
+2
-4
beat/web/plotters/apps.py
beat/web/plotters/apps.py
+1
-1
beat/web/plotters/urls.py
beat/web/plotters/urls.py
+1
-1
beat/web/search/apps.py
beat/web/search/apps.py
+1
-1
beat/web/team/apps.py
beat/web/team/apps.py
+2
-4
beat/web/toolchains/apps.py
beat/web/toolchains/apps.py
+1
-3
beat/web/ui/urls.py
beat/web/ui/urls.py
+2
-1
No files found.
beat/web/accounts/apps.py
View file @
c3223e69
...
...
@@ -27,8 +27,6 @@
from
django.apps
import
AppConfig
from
django.utils.translation
import
ugettext_lazy
as
_
from
django.contrib.auth.models
import
User
from
actstream
import
registry
class
AccountsConfig
(
AppConfig
):
...
...
@@ -36,5 +34,8 @@ class AccountsConfig(AppConfig):
verbose_name
=
_
(
'Accounts'
)
def
ready
(
self
):
super
(
AccountsConfig
,
self
).
ready
()
from
django.contrib.auth.models
import
User
from
actstream
import
registry
registry
.
register
(
User
)
from
.signals
import
setup_user
beat/web/accounts/urls.py
View file @
c3223e69
...
...
@@ -28,8 +28,6 @@
from
django.conf.urls
import
patterns
,
url
from
.
import
views
urlpatterns
=
patterns
(
''
,
url
(
r'^settings/$'
,
views
.
account_settings
,
name
=
'settings'
)
)
urlpatterns
=
[
url
(
r'^settings/$'
,
views
.
account_settings
,
name
=
'settings'
),
]
beat/web/algorithms/apps.py
View file @
c3223e69
...
...
@@ -27,7 +27,6 @@
from
..common.apps
import
CommonAppConfig
from
django.utils.translation
import
ugettext_lazy
as
_
from
actstream
import
registry
class
AlgorithmsConfig
(
CommonAppConfig
):
name
=
'beat.web.algorithms'
...
...
@@ -39,4 +38,5 @@ class AlgorithmsConfig(CommonAppConfig):
from
.signals
import
(
create_endpoints
,
delete_endpoints
,
auto_delete_file_on_delete
,
auto_delete_file_on_change
)
from
actstream
import
registry
registry
.
register
(
self
.
get_model
(
'Algorithm'
))
beat/web/attestations/apps.py
View file @
c3223e69
...
...
@@ -27,7 +27,6 @@
from
..common.apps
import
CommonAppConfig
from
django.utils.translation
import
ugettext_lazy
as
_
from
actstream
import
registry
class
AttestationsConfig
(
CommonAppConfig
):
name
=
'beat.web.attestations'
...
...
@@ -35,7 +34,6 @@ class AttestationsConfig(CommonAppConfig):
def
ready
(
self
):
super
(
AttestationsConfig
,
self
).
ready
()
from
.signals.handlers
import
on_unlocked
from
actstream
import
registry
registry
.
register
(
self
.
get_model
(
'Attestation'
))
beat/web/backend/api.py
View file @
c3223e69
...
...
@@ -29,16 +29,8 @@ from rest_framework.decorators import api_view, permission_classes
from
rest_framework.response
import
Response
from
rest_framework
import
permissions
from
..utils.api
import
send_email_to_administrators
from
..utils
import
scheduler
as
scheduler_api
from
.models
import
Environment
import
simplejson
as
json
#----------------------------------------------------------
@
api_view
([
'GET'
])
@
permission_classes
([
permissions
.
AllowAny
])
...
...
beat/web/dataformats/apps.py
View file @
c3223e69
...
...
@@ -27,7 +27,6 @@
from
..common.apps
import
CommonAppConfig
from
django.utils.translation
import
ugettext_lazy
as
_
from
actstream
import
registry
class
DataFormatsConfig
(
CommonAppConfig
):
...
...
@@ -35,9 +34,7 @@ class DataFormatsConfig(CommonAppConfig):
verbose_name
=
_
(
'Data Formats'
)
def
ready
(
self
):
super
(
DataFormatsConfig
,
self
).
ready
()
from
.signals
import
(
on_team_delete
,
auto_delete_file_on_delete
,
auto_delete_file_on_change
)
super
(
DataFormatsConfig
,
self
).
ready
()
from
.signals
import
on_team_delete
,
auto_delete_file_on_delete
,
auto_delete_file_on_change
from
actstream
import
registry
registry
.
register
(
self
.
get_model
(
'DataFormat'
))
beat/web/experiments/api.py
View file @
c3223e69
...
...
@@ -27,7 +27,8 @@
import
re
import
uuid
import
simplejson
as
json
import
simplejson
from
django.conf
import
settings
from
django.shortcuts
import
get_object_or_404
...
...
@@ -64,7 +65,6 @@ from ..algorithms.models import Algorithm
from
..toolchains.models
import
Toolchain
from
..utils.api
import
send_email_to_administrators
from
..utils
import
scheduler
#----------------------------------------------------------
...
...
@@ -214,7 +214,7 @@ class ListCreateExperimentsView(ListCreateContributionView):
else:
declaration_string = data['
declaration
']
try:
declaration = json.loads(declaration_string)
declaration =
simple
json.loads(declaration_string)
except:
return BadRequestResponse('
Invalid
declaration
data
')
...
...
@@ -388,11 +388,11 @@ class RetrieveUpdateDestroyExperimentView(RetrieveUpdateDestroyContributionView)
if isinstance(data['
declaration
'], dict):
declaration = data['
declaration
']
declaration_string = json.dumps(declaration, indent=4)
declaration_string =
simple
json.dumps(declaration, indent=4)
else:
declaration_string = data['
declaration
']
try:
declaration = json.loads(declaration_string)
declaration =
simple
json.loads(declaration_string)
except:
raise serializers.ValidationError({'
declaration
' :'
Invalid
declaration
data
'})
...
...
@@ -403,7 +403,7 @@ class RetrieveUpdateDestroyExperimentView(RetrieveUpdateDestroyContributionView)
short_description = declaration['
description
']
elif short_description is not None:
declaration['
description
'] = short_description
declaration_string = json.dumps(declaration, indent=4)
declaration_string =
simple
json.dumps(declaration, indent=4)
else:
declaration = None
...
...
beat/web/experiments/apps.py
View file @
c3223e69
...
...
@@ -27,15 +27,13 @@
from
..common.apps
import
CommonAppConfig
from
django.utils.translation
import
ugettext_lazy
as
_
from
actstream
import
registry
class
ExperimentsConfig
(
CommonAppConfig
):
name
=
'beat.web.experiments'
verbose_name
=
_
(
'Experiments'
)
def
ready
(
self
):
super
(
ExperimentsConfig
,
self
).
ready
()
super
(
ExperimentsConfig
,
self
).
ready
()
from
.signals
import
on_team_delete
from
actstream
import
registry
registry
.
register
(
self
.
get_model
(
'Experiment'
))
beat/web/libraries/apps.py
View file @
c3223e69
...
...
@@ -27,15 +27,13 @@
from
..common.apps
import
CommonAppConfig
from
django.utils.translation
import
ugettext_lazy
as
_
from
actstream
import
registry
class
LibrariesConfig
(
CommonAppConfig
):
name
=
'beat.web.libraries'
verbose_name
=
_
(
'Libraries'
)
def
ready
(
self
):
super
(
LibrariesConfig
,
self
).
ready
()
super
(
LibrariesConfig
,
self
).
ready
()
from
.signals
import
auto_delete_file_on_delete
,
auto_delete_file_on_change
from
actstream
import
registry
registry
.
register
(
self
.
get_model
(
'Library'
))
beat/web/plotters/apps.py
View file @
c3223e69
...
...
@@ -27,7 +27,6 @@
from
..common.apps
import
CommonAppConfig
from
django.utils.translation
import
ugettext_lazy
as
_
from
actstream
import
registry
class
PlottersConfig
(
CommonAppConfig
):
name
=
'beat.web.plotters'
...
...
@@ -35,4 +34,5 @@ class PlottersConfig(CommonAppConfig):
def
ready
(
self
):
super
(
PlottersConfig
,
self
).
ready
()
from
actstream
import
registry
registry
.
register
(
self
.
get_model
(
'Plotter'
))
beat/web/plotters/urls.py
View file @
c3223e69
...
...
@@ -31,7 +31,7 @@ from . import views
urlpatterns
=
[
url
(
r'^
/
$'
,
r'^$'
,
views
.
list_plotters
,
name
=
'list'
,
),
...
...
beat/web/search/apps.py
View file @
c3223e69
...
...
@@ -27,7 +27,6 @@
from
..common.apps
import
CommonAppConfig
from
django.utils.translation
import
ugettext_lazy
as
_
from
actstream
import
registry
class
SearchConfig
(
CommonAppConfig
):
name
=
'beat.web.search'
...
...
@@ -35,4 +34,5 @@ class SearchConfig(CommonAppConfig):
def
ready
(
self
):
super
(
SearchConfig
,
self
).
ready
()
from
actstream
import
registry
registry
.
register
(
self
.
get_model
(
'Search'
))
beat/web/team/apps.py
View file @
c3223e69
...
...
@@ -27,15 +27,13 @@
from
..common.apps
import
CommonAppConfig
from
django.utils.translation
import
ugettext_lazy
as
_
from
actstream
import
registry
class
TeamConfig
(
CommonAppConfig
):
name
=
'beat.web.team'
verbose_name
=
_
(
'Team'
)
def
ready
(
self
):
super
(
TeamConfig
,
self
).
ready
()
super
(
TeamConfig
,
self
).
ready
()
from
.signals.handlers
import
on_added_to_team
from
actstream
import
registry
registry
.
register
(
self
.
get_model
(
'Team'
))
beat/web/toolchains/apps.py
View file @
c3223e69
...
...
@@ -27,7 +27,6 @@
from
..common.apps
import
CommonAppConfig
from
django.utils.translation
import
ugettext_lazy
as
_
from
actstream
import
registry
class
ToolchainsConfig
(
CommonAppConfig
):
...
...
@@ -37,8 +36,7 @@ class ToolchainsConfig(CommonAppConfig):
def
ready
(
self
):
super
(
ToolchainsConfig
,
self
).
ready
()
from
.signals
import
auto_delete_file_on_delete
,
auto_delete_file_on_change
from
actstream
import
registry
registry
.
register
(
self
.
get_model
(
'Toolchain'
))
beat/web/ui/urls.py
View file @
c3223e69
...
...
@@ -28,6 +28,7 @@
from
django.conf.urls
import
url
from
django.conf
import
settings
from
django.views.generic.base
import
TemplateView
from
django.contrib.auth.views
import
logout
from
.
import
views
...
...
@@ -53,7 +54,7 @@ urlpatterns = [
),
url(r'
^
logout
/
$
',
'
django
.
contrib
.
auth
.
views
.
logout
'
,
logout
,
{'
next_page
': '
index
'},
name='
logout
',
),
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment