Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
LOFAR
Manage
Activity
Members
Labels
Plan
Issues
Wiki
Jira issues
Open Jira
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
RadioObservatory
LOFAR
Commits
b89d1cae
Commit
b89d1cae
authored
4 years ago
by
Jörn Künsemöller
Browse files
Options
Downloads
Patches
Plain Diff
TMSS-162
: process review comments
parent
b3f4b9a9
No related branches found
No related tags found
2 merge requests
!119
Cob 90 buffers for quantized TAB output
,
!109
Resolve TMSS-162
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
SAS/TMSS/src/remakemigrations.py
+2
-3
2 additions, 3 deletions
SAS/TMSS/src/remakemigrations.py
SAS/TMSS/src/tmss/tmssapp/models/scheduling.py
+9
-4
9 additions, 4 deletions
SAS/TMSS/src/tmss/tmssapp/models/scheduling.py
with
11 additions
and
7 deletions
SAS/TMSS/src/remakemigrations.py
+
2
−
3
View file @
b89d1cae
...
@@ -38,15 +38,15 @@ def execute_and_log(cmd):
...
@@ -38,15 +38,15 @@ def execute_and_log(cmd):
if
err
is
not
None
:
if
err
is
not
None
:
logger
.
info
(
"
STDERR: %s
"
%
err
.
decode
(
'
utf-8
'
).
strip
())
logger
.
info
(
"
STDERR: %s
"
%
err
.
decode
(
'
utf-8
'
).
strip
())
def
delete_old_migrations
():
def
delete_old_migrations
():
logger
.
info
(
'
Removing old migrations...
'
)
logger
.
info
(
'
Removing old migrations...
'
)
files
=
glob_migrations
()
files
=
glob_migrations
()
for
f
in
[
path
for
path
in
files
if
(
"
auto
"
in
path
or
"
populate
"
in
path
)]:
for
f
in
[
path
for
path
in
files
if
(
"
auto
"
in
path
or
"
populate
"
in
path
)]:
logger
.
info
(
'
Deleting: %s
'
%
f
)
logger
.
info
(
'
Deleting: %s
'
%
f
)
os
.
remove
(
f
)
os
.
remove
(
f
)
#execute_and_log('git rm %s' % f)
def
make_django_migrations
():
def
make_django_migrations
():
...
@@ -92,7 +92,6 @@ def remake_migrations():
...
@@ -92,7 +92,6 @@ def remake_migrations():
delete_old_migrations
()
delete_old_migrations
()
make_django_migrations
()
make_django_migrations
()
make_populate_migration
()
make_populate_migration
()
#put_migrations_under_version_control()
if
__name__
==
"
__main__
"
:
if
__name__
==
"
__main__
"
:
...
...
This diff is collapsed.
Click to expand it.
SAS/TMSS/src/tmss/tmssapp/models/scheduling.py
+
9
−
4
View file @
b89d1cae
...
@@ -180,13 +180,18 @@ class Subtask(BasicCommon):
...
@@ -180,13 +180,18 @@ class Subtask(BasicCommon):
'''
override of normal save method, doing a validation of the specification against the schema first
'''
override of normal save method, doing a validation of the specification against the schema first
:raises SpecificationException in case the specification does not validate against the schema
'''
:raises SpecificationException in case the specification does not validate against the schema
'''
self
.
validate_specification_against_schema
()
self
.
validate_specification_against_schema
()
creating
=
self
.
_state
.
adding
creating
=
self
.
_state
.
adding
# True on create, False on update
super
().
save
(
force_insert
,
force_update
,
using
,
update_fields
)
super
().
save
(
force_insert
,
force_update
,
using
,
update_fields
)
# log if either state update or new entry:
# log if either state update or new entry:
if
self
.
state
!=
self
.
__original_state
or
creating
is
True
:
if
self
.
state
!=
self
.
__original_state
or
creating
is
True
:
state_update
=
SubtaskStateLog
(
subtask
=
self
,
old_state
=
self
.
__original_state
,
new_state
=
self
.
state
,
if
self
.
created_or_updated_by_user
is
None
:
user
=
self
.
created_or_updated_by_user
,
user_identifier
=
self
.
created_or_updated_by_user
.
email
)
identifier
=
None
state_update
.
save
()
else
:
identifier
=
self
.
created_or_updated_by_user
.
email
log_entry
=
SubtaskStateLog
(
subtask
=
self
,
old_state
=
self
.
__original_state
,
new_state
=
self
.
state
,
user
=
self
.
created_or_updated_by_user
,
user_identifier
=
identifier
)
log_entry
.
save
()
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment