Skip to content

Commit a2b36ed

Browse files
committed
use if/else instead of try/except
1 parent c365b94 commit a2b36ed

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

create_requirement_images.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -316,9 +316,9 @@ def get_dependencies(libraries):
316316
lib_name = libraries_to_check[0]
317317
del libraries_to_check[0]
318318

319-
try:
319+
if lib_name in bundle_data:
320320
lib_obj = bundle_data[lib_name]
321-
except KeyError:
321+
else:
322322
# Library isn't in bundle, so we don't know about its
323323
# dependencies.
324324
if "." in lib_name:

0 commit comments

Comments
 (0)