Netscaler module returns "No module named json"

I’m running Ansible from a Centos 6 server w/ Python 2.6. My hosts are running RH5 w/ Python 2.4 and I have python-simplejson installed. On the client, “import json” from within the python interpreter doesn’t work but “import simplejson” does work.

So if I run the shell module

ansible all -m shell -a “cat /etc/redhat-release” returns values

If I run a playbook that utilizes the netscaler module, I get the following error.

TASK: [disable service in the lb] *********************************************
failed: [web002] => {“failed”: true, “parsed”: false}
Traceback (most recent call last):
File “/home/deployment/.ansible/tmp/ansible-tmp-1424196167.51-24867210620940/netscaler”, line 100, in ?
import json
ImportError: No module named json

FATAL: all hosts have already failed – aborting

the netscaler plugin only imports json and not simplejson, this is a
bug as it should work with 2.4

try just removing the import json from the file (netscaler.py), it
should not need it at all

Didn’t like that. :slight_smile:

msg: ‘NoneType’ object has no attribute ‘read’

FATAL: all hosts have already failed – aborting

Is it attempting to log into the host? Why would it need to do that if the work is being done on the netscaler?

use connection: local for that task

Awesome, works!

Thanks a lot.