File tree Expand file tree Collapse file tree 3 files changed +13
-2
lines changed Expand file tree Collapse file tree 3 files changed +13
-2
lines changed Original file line number Diff line number Diff line change @@ -97,6 +97,7 @@ pip install https://github.com/boto/botocore/archive/v2.zip https://github.com/a
97
97
98
98
## Change Log
99
99
100
+ * v0.22.2: Display full stack traces only in ` --debug ` mode; non-debug runs now show concise error messages, consistent with ` awscli ` behavior.
100
101
* v0.22.1: Fix issue with cfn package and cfn deploy with awscli >= 1.41.9
101
102
* v0.22.0: Use fallback for endpoint detection. Should prevent most cases of ` Unable to find LocalStack endpoint for service ... `
102
103
* v0.21.1: Introducing semantic versioning and list of services without endpoints
Original file line number Diff line number Diff line change @@ -21,6 +21,7 @@ import os
21
21
import sys
22
22
import subprocess
23
23
import re
24
+ import traceback
24
25
25
26
PARENT_FOLDER = os .path .realpath (os .path .join (os .path .dirname (__file__ ), '..' ))
26
27
S3_VIRTUAL_ENDPOINT_HOSTNAME = 's3.localhost.localstack.cloud'
@@ -41,6 +42,8 @@ def get_service():
41
42
if not param .startswith ('-' ):
42
43
return param
43
44
45
+ def is_debug_mode ():
46
+ return "--debug" in sys .argv
44
47
45
48
def get_service_endpoint (localstack_host = None ):
46
49
service = get_service ()
@@ -83,7 +86,14 @@ def main():
83
86
try :
84
87
import awscli .clidriver # noqa: F401
85
88
except Exception :
86
- return run_as_separate_process ()
89
+ try :
90
+ return run_as_separate_process ()
91
+ except Exception as e :
92
+ if is_debug_mode ():
93
+ traceback .print_exc ()
94
+ else :
95
+ print (f"\n { e } " )
96
+ sys .exit (1 )
87
97
patch_awscli_libs ()
88
98
run_in_process ()
89
99
Original file line number Diff line number Diff line change 16
16
17
17
setup (
18
18
name = 'awscli-local' ,
19
- version = '0.22.1 ' ,
19
+ version = '0.22.2 ' ,
20
20
description = description ,
21
21
long_description = README ,
22
22
long_description_content_type = 'text/markdown' ,
You can’t perform that action at this time.
0 commit comments