Skip to content

Commit

Permalink
Merge pull request #1242 from csordasmarton/fix_general_exception
Browse files Browse the repository at this point in the history
Fix server general exception
  • Loading branch information
gyorb authored Dec 11, 2017
2 parents aa2631a + c156414 commit 25fa81b
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion libcodechecker/server/api/report_server.py
Original file line number Diff line number Diff line change
Expand Up @@ -1873,7 +1873,9 @@ def massStoreRun(self, name, tag, version, b64zip, force):
run = session.query(Run).filter(Run.name == name).one_or_none()

if run and self.__storage_session.has_ongoing_run(run.id):
raise Exception('Storage of ' + name + ' is already going!')
raise shared.ttypes.RequestFailed(
shared.ttypes.ErrorCode.GENERAL,
'Storage of ' + name + ' is already going!')
finally:
session.close()

Expand Down

0 comments on commit 25fa81b

Please sign in to comment.