Closed silverailscolo closed 3 months ago
And when was the last time you updated your API key? They were changed recently by MyEnergi.
Generated a new key as suggested, and the key was accepted by the myenergi API when running a python import script. However in HA I still get a message: 'Could not connect to myenergi, please try again in a while."
Full log:
Deze fout is ontstaan door een aangepaste integratie. [= This error was caused by a custom integration]
Logger: custom_components.myenergi
Bron: custom_components/myenergi/config_flow.py:102
integratie: myenergi (documentatie, problemen)
Eerst voorgekomen: 17:12:48 (14 gebeurtenissen)
Laatst gelogd: 17:55:23
Traceback (most recent call last): File "/config/custom_components/myenergi/config_flow.py", line 88, in _test_credentials conn = await self.hass.async_add_executor_job( ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/concurrent/futures/thread.py", line 58, in run result = self.fn(*self.args, **self.kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ TypeError: Connection.__init__() takes from 1 to 4 positional arguments but 5 were given
Getting the same "5 args" error in log when trying to reinstall myenergy integration in HA:
Deze fout is ontstaan door een aangepaste integratie.
Logger: custom_components.myenergi
Bron: custom_components/myenergi/config_flow.py:102
integratie: myenergi (documentatie, problemen)
Eerst voorgekomen: 17:12:48 (17 gebeurtenissen)
Laatst gelogd: 19:55:10
Traceback (most recent call last): File "/config/custom_components/myenergi/config_flow.py", line 88, in _test_credentials conn = await self.hass.async_add_executor_job( ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/concurrent/futures/thread.py", line 58, in run result = self.fn(*self.args, **self.kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ TypeError: Connection.__init__() takes from 1 to 4 positional arguments but 5 were given
Updating pymyenergi to latest version using -U option made no difference.
My issue disappeared after removing an local copy of outdated pymyenergi code that was inside the /homeassistant/ dir on my raspi.
Will close this Issue
Hub component does not connect. On restart, log says:
Connection.__init__() takes from 1 to 4 positional arguments but 5 were given
Version of the custom_component
0.0.28
Configuration
HACS myenergi integration configured via UI Zappi v2, Hub + Harvi all running fine since 2023 (except for a recent warning about missing
num_phases
attribute).Today I updated the myenergi integration via HACS.
Describe the bug
myenergi integration does not complete, sensors are grayed out/unavailable. Code in
connection.py
seems to provide 5 args:Debug log