clb
clb copied to clipboard
TypeError: string indices must be integers, not str
Seemingly randomly, the output from clb list
isn't a list of the load balancers but this error:
Traceback (most recent call last):
File "/usr/local/bin/clb", line 5, in
File "/usr/local/lib/python2.7/dist-packages/python_cloudlb-0.5.1-py2.7.egg/cloudlb/base.py", line 57, in _list
resp, body = self.api.client.get(url)
File "/usr/local/lib/python2.7/dist-packages/python_cloudlb-0.5.1-py2.7.egg/cloudlb/client.py", line 183, in get
return self._cloudlb_request(url, 'GET', **kwargs)
File "/usr/local/lib/python2.7/dist-packages/python_cloudlb-0.5.1-py2.7.egg/cloudlb/client.py", line 159, in _cloudlb_request
message = ', '.join(body['messages'])
TypeError: string indices must be integers, not str
I am getting this too. Oddly this was working fine with a normal user, the only caveat I could fine was needing to change perms of cacerts.txt under the cloudlb module. Then magically this morning, I started getting the same type of error:
$ scl enable python27 "clb list"
Traceback (most recent call last):
File "/opt/rh/python27/root/usr/bin/clb", line 5, in
File "/opt/rh/python27/root/usr/lib/python2.7/site-packages/python_cloudlb-0.6.2-py2.7.egg/cloudlb/base.py", line 59, in _list
resp, body = self.api.client.get(url)
File "/opt/rh/python27/root/usr/lib/python2.7/site-packages/python_cloudlb-0.6.2-py2.7.egg/cloudlb/client.py", line 191, in get
return self._cloudlb_request(url, 'GET', **kwargs)
File "/opt/rh/python27/root/usr/lib/python2.7/site-packages/python_cloudlb-0.6.2-py2.7.egg/cloudlb/client.py", line 170, in _cloudlb_request
message = ', '.join(body['messages'])
TypeError: string indices must be integers, not str
This is centos 6.6 running python2.7 from the centOS SCL repo.
NOTE, if run as root user it works as expected though. Any ideas?