Skip to content

Commit 8a57db7

Browse files
authoredOct 21, 2024··
Merge pull request #2196 from allmightyspiff/setupDebug
Allow for proper debugging of config setup
2 parents fe208b1 + fbdf40e commit 8a57db7

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed
 

‎SoftLayer/CLI/config/setup.py

+4
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,8 @@ def cli(env, auth):
7878
username = 'apikey'
7979
secret = env.getpass('Classic Infrastructure API Key', default=defaults['api_key'])
8080
new_client = SoftLayer.Client(username=username, api_key=secret, endpoint_url=endpoint_url, timeout=timeout)
81+
env.client = new_client
82+
env.client.transport = SoftLayer.DebugTransport(new_client.transport)
8183
api_key = get_api_key(new_client, username, secret)
8284

8385
elif auth == 'sso':
@@ -87,6 +89,8 @@ def cli(env, auth):
8789
username = env.input('Classic Infrastructure Username', default=defaults['username'])
8890
secret = env.getpass('Classic Infrastructure API Key', default=defaults['api_key'])
8991
new_client = SoftLayer.Client(username=username, api_key=secret, endpoint_url=endpoint_url, timeout=timeout)
92+
env.client = new_client
93+
env.client.transport = SoftLayer.DebugTransport(new_client.transport)
9094
api_key = get_api_key(new_client, username, secret)
9195

9296
# Ask for timeout, convert to float, then to int

0 commit comments

Comments
 (0)
Please sign in to comment.