From 7139a4e23cb97d3848dcc185c443f092ab60cfc2 Mon Sep 17 00:00:00 2001 From: Aaron Gable Date: Tue, 5 Sep 2017 17:53:09 -0700 Subject: [PATCH] git-cl set_close: Don't fail on branches with no issue R=tandrii@chromium.org Bug: 258661 Change-Id: Iee910d6d01df4c675523abdaf4e505364f94c4aa Reviewed-on: https://chromium-review.googlesource.com/651233 Reviewed-by: Andrii Shyshkalov Commit-Queue: Aaron Gable --- git_cl.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/git_cl.py b/git_cl.py index 8f55a5296..0dc18b565 100755 --- a/git_cl.py +++ b/git_cl.py @@ -5692,7 +5692,8 @@ def CMDset_close(parser, args): cl = Changelist(auth_config=auth_config, issue=options.issue, codereview=options.forced_codereview) # Ensure there actually is an issue to close. - cl.GetDescription() + if not cl.GetIssue(): + DieWithError('ERROR No issue to close') cl.CloseIssue() return 0