From 721f841ef8fe0017835a8f54acbe1c2d729d97a4 Mon Sep 17 00:00:00 2001 From: Jonathan Bohren Date: Mon, 16 Mar 2015 11:53:09 -0400 Subject: [PATCH] build: fixing bad crash when --this is used when not in a package Fixes #115 --- catkin_tools/verbs/catkin_build/cli.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/catkin_tools/verbs/catkin_build/cli.py b/catkin_tools/verbs/catkin_build/cli.py index 6a178ec8..8f836afb 100644 --- a/catkin_tools/verbs/catkin_build/cli.py +++ b/catkin_tools/verbs/catkin_build/cli.py @@ -193,8 +193,8 @@ def main(opts): # Determine the enclosing package try: this_package = find_enclosing_package() - except InvalidPackage: - pass + except (InvalidPackage, RuntimeError): + this_package = None # Handle context-based package building if opts.build_this: