ewcloud / ewcloud/ewccli

[BUG] Improve error when profile is formed manually

Open
#170 0 comments 0 reactions 1 assignee Claimed by @pacospace View on GitHub
bug
Dominant language
Python
Stars
3
Forks
4
Avg merge
1d 17h
Merged PRs (30d)
11

Description

### Affected Command

ewc infra list

### Describe the issue

```
Traceback (most recent call last):
File "/home/murdaca/work-ewc/ewccli-github/newtestewccli/bin/ewc", line 8, in
sys.exit(cli())
^^^^^
File "/home/murdaca/work-ewc/ewccli-github/newtestewccli/lib/python3.12/site-packages/rich_click/rich_command.py", line 402, in __call__
return super().__call__(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/murdaca/work-ewc/ewccli-github/newtestewccli/lib/python3.12/site-packages/click/core.py", line 1462, in __call__
return self.main(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/murdaca/work-ewc/ewccli-github/newtestewccli/lib/python3.12/site-packages/rich_click/rich_command.py", line 216, in main
rv = self.invoke(ctx)
^^^^^^^^^^^^^^^^
File "/home/murdaca/work-ewc/ewccli-github/newtestewccli/lib/python3.12/site-packages/click/core.py", line 1850, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/murdaca/work-ewc/ewccli-github/newtestewccli/lib/python3.12/site-packages/click/core.py", line 1847, in invoke
super().invoke(ctx)
File "/home/murdaca/work-ewc/ewccli-github/newtestewccli/lib/python3.12/site-packages/click/core.py", line 1246, in invoke
return ctx.invoke(self.callback, **ctx.params)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/murdaca/work-ewc/ewccli-github/newtestewccli/lib/python3.12/site-packages/click/core.py", line 814, in invoke
return callback(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/murdaca/work-ewc/ewccli-github/newtestewccli/lib/python3.12/site-packages/click/decorators.py", line 93, in new_func
return ctx.invoke(f, obj, *args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/murdaca/work-ewc/ewccli-github/newtestewccli/lib/python3.12/site-packages/click/core.py", line 814, in invoke
return callback(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/murdaca/work-ewc/ewccli-github/ewccli/commands/infra_command.py", line 75, in ewc_infra_command
auth_url=ewc_hub_config.EWC_CLI_SITE_MAP[federee][region],
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^
KeyError: 'CC1'
```

### Steps to Reproduce

Have a profile with wrong inputs
run ewc infra list

### Expected Behavior

_No response_

### Logs or Output

```shell

```

### Environment

Linux

### EWC CLI Version

0.9.0

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.