osc-cli icon indicating copy to clipboard operation
osc-cli copied to clipboard

endpoints in osc/config.json make cli crash

Open jerome-jutteau opened this issue 2 years ago • 1 comments

Hi,

Seems that "endpoints" in osc/config.json makes osc-cli crash.

$ osc-cli api ReadNets
Traceback (most recent call last):
  File "/tmp/.mount_osc-clA4himb/opt/python3.9/bin/osc-cli", line 34, in <module>
    sys.exit(load_entry_point('osc-sdk==1.8.0', 'console_scripts', 'osc-cli')())
  File "/tmp/.mount_osc-clA4himb/opt/python3.9/lib/python3.9/site-packages/osc_sdk-1.8.0-py3.9.egg/osc_sdk/sdk.py", line 749, in main
  File "/home/jerome/.local/lib/python3.9/site-packages/fire/core.py", line 141, in Fire
    component_trace = _Fire(component, args, parsed_flag_args, context, name)
  File "/home/jerome/.local/lib/python3.9/site-packages/fire/core.py", line 466, in _Fire
    component, remaining_args = _CallAndUpdateTrace(
  File "/home/jerome/.local/lib/python3.9/site-packages/fire/core.py", line 681, in _CallAndUpdateTrace
    component = fn(*varargs, **kwargs)
  File "/tmp/.mount_osc-clA4himb/opt/python3.9/lib/python3.9/site-packages/osc_sdk-1.8.0-py3.9.egg/osc_sdk/sdk.py", line 739, in api_connect
TypeError: __init__() got an unexpected keyword argument 'endpoints'

osc-cli should just ignore items in json it does not know (yet)

cc FYI @outscale-mgo

jerome-jutteau avatar Jun 10 '22 13:06 jerome-jutteau

Ok, I take care of this after the the windows packaging is fix

outscale-mgo avatar Jun 10 '22 13:06 outscale-mgo