F5Networks / f5-ansible

Imperative Ansible modules for F5 BIG-IP products
GNU General Public License v3.0
376 stars 231 forks source link

error with bigip_ucs_fetch.py global name 'BIGSUDS_AVAILABLE' is not defined #135

Closed damhau closed 6 years ago

damhau commented 7 years ago

in bigip_ucs_fetch.py

I've have to add server_port it was missing and generating a "pack" error: around line 361:

(server, user, password, state, partition, validate_certs, server_port) = f5_parse_arguments(module)

I had to configure manually the connection type with the following:

line 371 connection = 'soap' instead of connection = module.params['connection']

I had to comment the following:

line 390 and 391 and 393

if not BIGSUDS_AVAILABLE:

           # raise Exception("The python bigsuds module is required")

        #test_icontrol(user, password, server, validate_certs)

Otherwise i would get the following error:

An exception occurred during task execution. To see the full traceback, use -vvv. The error was: NameError: global name 'BIGSUDS_AVAILABLE' is not defined fatal: [CH-F5LMV0N3-01.it.actelion.com -> localhost]: FAILED! => {"changed": false, "failed": true, "module_stderr": "Traceback (most recent call last):\n File \"/tmp/ansible_YrkSIt/ansible_module_bigip_ucs_fetch.py\", line 469, in \n main()\n File \"/tmp/ansible_YrkSIt/ansible_module_bigip_ucs_fetch.py\", line 390, in main\n if not BIGSUDS_AVAILABLE:\nNameError: global name 'BIGSUDS_AVAILABLE' is not defined\n", "module_stdout": "", "msg": "MODULE FAILURE", "rc": 0}

I'm sure that the needed python module and the right version of ansible is installed (2.3).

I've searched where BIGSUDS_AVAILABLE and test_icontrol could be defined but no luck.

Maybe I'm still missing somehting but with thus change it work perfectly.

Rgds,

Damien

caphrim007 commented 7 years ago

BIGSUDS_AVAILABLE is no longer used, so this module will need to be changed to reflect that, as you have seen.

caphrim007 commented 6 years ago

this module has been refactored, and my tests indicate this is no longer an issue