Skip to content

Commit

Permalink
Set history update_time in set_final_state / update_output_states
Browse files Browse the repository at this point in the history
  • Loading branch information
mvdbeek committed Sep 22, 2020
1 parent d6d281b commit 2d48d8b
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions lib/galaxy/model/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -1165,10 +1165,15 @@ def set_final_state(self, final_state):
FROM workflow_invocation_step wis
WHERE wis.job_id = :job_id
);
''', '''
UPDATE history
SET update_time = :update_time
WHERE id = :history_id
''']
sa_session = object_session(self)
params = {
'job_id': self.id,
'history_id': self.history_id,
'update_time': galaxy.model.orm.now.now()
}
for statement in statements:
Expand Down Expand Up @@ -1252,10 +1257,15 @@ def update_output_states(self):
FROM job_to_output_library_dataset jtold
WHERE jtold.job_id = :job_id
);
''', '''
UPDATE history
SET update_time = :update_time
WHERE id = :history_id
''']
sa_session = object_session(self)
params = {
'job_id': self.id,
'history_id': self.history_id,
'state': self.state,
'info': self.info,
'update_time': galaxy.model.orm.now.now()
Expand Down

0 comments on commit 2d48d8b

Please sign in to comment.