Closed k3lwin closed 1 year ago
Hi! thanks for the report. I updated the script with some patches that can fix the problem. Can you please try it out?
Hi! thanks for the report. I updated the script with some patches that can fix the problem. Can you please try it out? I have tried it:
Result:
Almost working.
To make it work I had to install the missing "paho-mqtt" module as @k3lwin noted.
SSH into the router and install the missing module: pip install paho-mqtt
(V1.6.1 was installed)
NOTE: When i add the MQTT integration it takes ~ 2min before the configuration page is available (not sure if this is normal, but I'm not complaining MQTT is working :D )
Thank you for the update!
Isn't paho-mqtt installed automatically with HA ? You can check it in /etc/homeassistant/deps/
Usually, it takes some time to install all the required packages before using it. Sometimes it is required to restart HA.
@devbis this folder does not contain any pip modules, only aiogithubapi. This module I installed manually (it was a requirement to get the homeassistant comunity store HACS integration working)
This is my folder tree on the openwrt target:
/etc/homeassistant/deps/
└── lib
└── python3.10
└── site-packages
├── aiogithubapi
└── aiogithubapi-22.12.2.dist-info
I reran the first part the script were the requirements are collected inside the /tmp/ha_requirements.txt
file.
here the paho-mqtt==1.6.1
requirement is listed.
in the /tmp/requirements.txt
file which is statically defined inside the script this requirement is not listed.
I just performed a clean install an ran the script again. (there is an issue with the installation of frozenlist but after fixing this the script is able to finish. However some dependencies are missing after the install, I get an error in the HA log about pycountry
missing after the install and when I try to add the MQTT integration a new error is generated and points to paho-mqtt==1.6.1
missing.
I found a clue inside the /tmp dir pip-log.txt
but I'm not sure why it is failing to install because when I do this manually it installs just fine.
To fix these errors i installed these packages manually and rebooted.
pip install paho-mqtt==1.6.1
pip install pycountry
I added "integration" component to the script as it is mentioned in logs. The probem of installing paho-mqtt seems to be related to the network problems. I don't want to incorporate libraries that could not be used by end-users. E.g. installations without using MQTT at all. As for pycountry, I didn't find any mentions of the package in the code.
Thank you, I just checked the pycountry
module is a dependency of the radios
module (radio_browser integration), not sure why it failed to install. Probably not needed to update the script for this.
Changes in MQTT in HA 2022.12 broke the installation script:
text
component, which apparently gets removed by the script.text
component, I get this error:util.py
is present in./components/mqtt
directory. Some bug reports with similar issues have been resolved by installing missing pip packages, but it is unclear which package is missing.paho-mqtt
was not installed despite being mentioned in MQTT integration manifest, but installing it manually did not solve the issue.I'm trying to install HA on Xiaomi DGNWG05LM with OpenWRT 22.03.2 r19803-9a599fee93
Unfortunately, I'm not experienced enough to debug this issue further.