2018-11-23 21:12:17 ERROR (MainThread) [homeassistant.components.sensor] Error while setting up platform ha_vcenter
Traceback (most recent call last):
File "/config/custom_components/sensor/ha_vcenter.py", line 382, in _HostInformation
networkTx = (float(sum(statNetworkTx[0].value[0].value) * 8 * 1024) / statInt)
TypeError: 'bool' object is not subscriptable
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/config/custom_components/sensor/ha_vcenter.py", line 354, in _ComputeResourceInformation
self._HostInformation(host,datacenter_name,computeResource_name,content,perf_dict,vchtime,interval)
File "/config/custom_components/sensor/ha_vcenter.py", line 391, in _HostInformation
_LOGGER.error( "Unable to access information for host: ", host.name)
File "/usr/local/lib/python3.6/logging/__init__.py", line 1336, in error
self._log(ERROR, msg, args, **kwargs)
File "/usr/local/lib/python3.6/logging/__init__.py", line 1443, in _log
self.handle(record)
File "/usr/local/lib/python3.6/logging/__init__.py", line 1453, in handle
self.callHandlers(record)
File "/usr/local/lib/python3.6/logging/__init__.py", line 1515, in callHandlers
hdlr.handle(record)
File "/usr/local/lib/python3.6/logging/__init__.py", line 864, in handle
self.emit(record)
File "/usr/local/lib/python3.6/site-packages/homeassistant/components/system_log/__init__.py", line 130, in emit
entry = self._create_entry(record, stack)
File "/usr/local/lib/python3.6/site-packages/homeassistant/components/system_log/__init__.py", line 113, in _create_entry
'message': record.getMessage(),
File "/usr/local/lib/python3.6/logging/__init__.py", line 338, in getMessage
msg = msg % self.args
TypeError: not all arguments converted during string formatting
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/local/lib/python3.6/site-packages/homeassistant/helpers/entity_platform.py", line 128, in _async_setup_platform
SLOW_SETUP_MAX_WAIT, loop=hass.loop)
File "/usr/local/lib/python3.6/asyncio/tasks.py", line 358, in wait_for
return fut.result()
File "/usr/local/lib/python3.6/concurrent/futures/thread.py", line 56, in run
result = self.fn(*self.args, **self.kwargs)
File "/config/custom_components/sensor/ha_vcenter.py", line 140, in setup_platform
client.start(hass)
File "/config/custom_components/sensor/ha_vcenter.py", line 258, in start
self.run(dt_util.now())
File "/config/custom_components/sensor/ha_vcenter.py", line 510, in run
self._ComputeResourceInformation(computeResource,datacenter_name,content,perf_dict,vchtime,self._interval)
File "/config/custom_components/sensor/ha_vcenter.py", line 356, in _ComputeResourceInformation
_LOGGER.error( "Unable to access information for compute resource: ", computeResource.name)
File "/usr/local/lib/python3.6/logging/__init__.py", line 1336, in error
self._log(ERROR, msg, args, **kwargs)
File "/usr/local/lib/python3.6/logging/__init__.py", line 1443, in _log
self.handle(record)
File "/usr/local/lib/python3.6/logging/__init__.py", line 1453, in handle
self.callHandlers(record)
File "/usr/local/lib/python3.6/logging/__init__.py", line 1515, in callHandlers
hdlr.handle(record)
File "/usr/local/lib/python3.6/logging/__init__.py", line 864, in handle
self.emit(record)
File "/usr/local/lib/python3.6/site-packages/homeassistant/components/system_log/__init__.py", line 130, in emit
entry = self._create_entry(record, stack)
File "/usr/local/lib/python3.6/site-packages/homeassistant/components/system_log/__init__.py", line 113, in _create_entry
'message': record.getMessage(),
File "/usr/local/lib/python3.6/logging/__init__.py", line 338, in getMessage
msg = msg % self.args
TypeError: not all arguments converted during string formatting