From 4e55dd0f598a9f8df1e4478333e4111c4f7cad2c Mon Sep 17 00:00:00 2001 From: ZhuoX Li Date: Wed, 19 Mar 2014 13:50:28 +0800 Subject: [PATCH] Catch buildservice ObsError exception When modify the meta conf to unlink raise ObsError exception, it should be catched. Fixes: #1726 Change-Id: Icf7602ba813db5a3c0ca9ead4171dd2072b767d5 --- job_submit.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/job_submit.py b/job_submit.py index f3aee9a..eecd50d 100755 --- a/job_submit.py +++ b/job_submit.py @@ -67,7 +67,10 @@ def create_project(git_url, git_project, git_tag, git_revision, build, # update project info build.update_info(info, obs_project) # unlink the project to upload packages - build.unlink_project(obs_project) + try: + build.unlink_project(obs_project) + except ObsError, error: + print 'Modify the meta conf to unlink failed: %s' % error else: if not build.exists(obs_target_prj): raise LocalError("Target project %s doesn't exist" % obs_target_prj) -- 2.7.4