diff options
author | Jonas Devlieghere <jonas@devlieghere.com> | 2019-08-26 16:08:53 +0000 |
---|---|---|
committer | Jonas Devlieghere <jonas@devlieghere.com> | 2019-08-26 16:08:53 +0000 |
commit | a69992c8cb804e7db254f8c218cc0fe6f7a78e49 (patch) | |
tree | f8341df53c16967e6941903c872099a4dfe89b4a /lldb/packages/Python/lldbsuite/test/dotest.py | |
parent | 3877aa1660b6ec02376b6b260411662d7d4ab74f (diff) | |
download | bcm5719-llvm-a69992c8cb804e7db254f8c218cc0fe6f7a78e49.tar.gz bcm5719-llvm-a69992c8cb804e7db254f8c218cc0fe6f7a78e49.zip |
[dotest] Print invocation when encountering an error.
With this patch dotest.py will print the full invocation whenever it
fails to parse its arguments. The dotest invocation is usually build up
with different inputs, potentially coming from CMake, lldb-dotest, lit
or passed directly. This can make debugging hard, especially on CI,
where there might be another layer of indirection. This aims to make
that a bit easier.
llvm-svn: 369922
Diffstat (limited to 'lldb/packages/Python/lldbsuite/test/dotest.py')
-rw-r--r-- | lldb/packages/Python/lldbsuite/test/dotest.py | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/lldb/packages/Python/lldbsuite/test/dotest.py b/lldb/packages/Python/lldbsuite/test/dotest.py index 5eb8bd54f59..9082b78e8c6 100644 --- a/lldb/packages/Python/lldbsuite/test/dotest.py +++ b/lldb/packages/Python/lldbsuite/test/dotest.py @@ -225,8 +225,12 @@ def parseOptionsAndInitTestdirs(): platform_system = platform.system() platform_machine = platform.machine() - parser = dotest_args.create_parser() - args = dotest_args.parse_args(parser, sys.argv[1:]) + try: + parser = dotest_args.create_parser() + args = dotest_args.parse_args(parser, sys.argv[1:]) + except: + print(' '.join(sys.argv)) + raise if args.unset_env_varnames: for env_var in args.unset_env_varnames: |