Making some refactors to make it easier to cancel the build at any time.
This commit is contained in:
parent
42ed8522fd
commit
1cde22e76c
3 changed files with 86 additions and 16 deletions
|
@ -63,10 +63,7 @@ class StatusHandler(object):
|
|||
self._append_log_message(phase, self._build_logs.PHASE, extra_data)
|
||||
|
||||
# Update the repository build with the new phase
|
||||
repo_build = model.build.get_repository_build(self._uuid)
|
||||
repo_build.phase = phase
|
||||
repo_build.save()
|
||||
return True
|
||||
return model.build.update_phase(self._uuid, phase)
|
||||
|
||||
def __enter__(self):
|
||||
return self._status
|
||||
|
|
Reference in a new issue