You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In looking through the integration tests, I noticed a traceback when creating an invalid SSH key.
TASK [digital_ocean_sshkey : Create an invalid SSH key] ************************
An exception occurred during task execution. To see the full traceback, use -vvv. The error was: IndexError: list index out of range
fatal: [testhost]: FAILED! => {"changed": false, "module_stderr": "Traceback (most recent call last):\n File \"/root/.ansible/tmp/ansible-tmp-1618943706.106942-1819-173224235158984/AnsiballZ_digital_ocean_sshkey.py\", line 143, in <module>\n _ansiballz_main()\n File \"/root/.ansible/tmp/ansible-tmp-1618943706.106942-1819-173224235158984/AnsiballZ_digital_ocean_sshkey.py\", line 135, in _ansiballz_main\n invoke_module(zipped_mod, temp_path, ANSIBALLZ_PARAMS)\n File \"/root/.ansible/tmp/ansible-tmp-1618943706.106942-1819-173224235158984/AnsiballZ_digital_ocean_sshkey.py\", line 81, in invoke_module\n runpy.run_module(mod_name='ansible_collections.community.digitalocean.plugins.modules.digital_ocean_sshkey', init_globals=None, run_name='__main__', alter_sys=True)\n File \"/usr/lib/python3.8/runpy.py\", line 205, in run_module\n return _run_module_code(code, init_globals, run_name, mod_spec)\n File \"/usr/lib/python3.8/runpy.py\", line 95, in _run_module_code\n _run_code(code, mod_globals, init_globals,\n File \"/usr/lib/python3.8/runpy.py\", line 85, in _run_code\n exec(code, run_globals)\n File \"/tmp/ansible_community.digitalocean.digital_ocean_sshkey_payload_rdwn4ua1/ansible_community.digitalocean.digital_ocean_sshkey_payload.zip/ansible_collections/community/digitalocean/plugins/modules/digital_ocean_sshkey.py\", line 273, in <module>\n File \"/tmp/ansible_community.digitalocean.digital_ocean_sshkey_payload_rdwn4ua1/ansible_community.digitalocean.digital_ocean_sshkey_payload.zip/ansible_collections/community/digitalocean/plugins/modules/digital_ocean_sshkey.py\", line 269, in main\n File \"/tmp/ansible_community.digitalocean.digital_ocean_sshkey_payload_rdwn4ua1/ansible_community.digitalocean.digital_ocean_sshkey_payload.zip/ansible_collections/community/digitalocean/plugins/modules/digital_ocean_sshkey.py\", line 175, in core\n File \"/tmp/ansible_community.digitalocean.digital_ocean_sshkey_payload_rdwn4ua1/ansible_community.digitalocean.digital_ocean_sshkey_payload.zip/ansible_collections/community/digitalocean/plugins/modules/digital_ocean_sshkey.py\", line 242, in ssh_key_fingerprint\nIndexError: list index out of range\n", "module_stdout": "", "msg": "MODULE FAILURE\nSee stdout/stderr for the exact error", "rc": 1}
...ignoring
SUMMARY
In looking through the integration tests, I noticed a traceback when creating an invalid SSH key.
ISSUE TYPE
COMPONENT NAME
digital_ocean_sshkey
ANSIBLE VERSION
CONFIGURATION
STEPS TO REPRODUCE
The traceback is visible in the output of the integration test, I'm sure it could be reproduced locally as well.
EXPECTED RESULTS
It would be nice to let the user know that the SSH key isn't valid, and, not have an exception.
ACTUAL RESULTS
Traceback.
The text was updated successfully, but these errors were encountered: