From 3e784339af808833998657daded0f32870305966 Mon Sep 17 00:00:00 2001 From: godofredoc Date: Fri, 9 Sep 2022 15:20:09 -0700 Subject: [PATCH] Print detailed logs on command error. (flutter/engine#36053) --- .../src/flutter/sky/tools/create_macos_gen_snapshots.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/engine/src/flutter/sky/tools/create_macos_gen_snapshots.py b/engine/src/flutter/sky/tools/create_macos_gen_snapshots.py index 139e9ed146..4daa54f0b2 100755 --- a/engine/src/flutter/sky/tools/create_macos_gen_snapshots.py +++ b/engine/src/flutter/sky/tools/create_macos_gen_snapshots.py @@ -78,9 +78,15 @@ def generate_gen_snapshot(directory, destination): print('Cannot find gen_snapshot at %s' % gen_snapshot_dir) sys.exit(1) - subprocess.check_call([ + result = subprocess.run([ 'xcrun', 'bitcode_strip', '-r', gen_snapshot_dir, '-o', destination ]) + if result.returncode != 0: + print( + 'Error processing command with stdout[%s] and stderr[%s]' % + (result.stdout, result.stderr) + ) + return 1 if __name__ == '__main__':