homeassistant-solax-modbus
homeassistant-solax-modbus copied to clipboard
[Bug]: 'Solis' - TypeError: unsupported operand type(s) for *: 'NoneType' and 'NoneType'
Describe the bug
Intermittently, the integration will stop and all the entities will zero out. Reloading the integration usually seems to fix it, so it sounds like a HA/integration issue as opposed to a inverter/modbus issue.
I've looked through the existing issues, and I don't think this is the same as some of them which have been reported.
Integration Version
2024.05.2
Homeassistant core version
2024.5.2
Inverter brand
Solis
Plugin used
plugin_solis.py
Serial prefix
603105
Connection Method
USR-TCP232-304 Serial RS485 to TCP/IP Ethernet Server Converter Module
Detailed Error Log
Logger: custom_components.solax_modbus
Source: custom_components/solax_modbus/__init__.py:615
integration: SolaX Inverter Modbus ([documentation](https://homeassistant-solax-modbus.readthedocs.io/), [issues](https://github.com/wills106/homsassistant-solax-modbus/issues))
First occurred: May 8, 2024 at 7:49:33 PM (1026 occurrences)
Last logged: 10:03:27 AM
Something went wrong reading from modbus
Traceback (most recent call last):
File "/config/custom_components/solax_modbus/__init__.py", line 615, in async_read_modbus_data
res = await self.async_read_modbus_registers_all(group)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/solax_modbus/__init__.py", line 794, in async_read_modbus_registers_all
self.data[descr.key] = descr.value_function(0, descr, self.data)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/solax_modbus/plugin_solis.py", line 134, in value_function_pv1_power
return datadict.get('pv_voltage_1', 0) * datadict.get('pv_current_1',0)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
TypeError: unsupported operand type(s) for *: 'NoneType' and 'NoneType'
Additional context
No response