Code Monkey home page Code Monkey logo

Comments (7)

devbis avatar devbis commented on June 12, 2024

Hi! thanks for the report. I updated the script with some patches that can fix the problem. Can you please try it out?

from homeassistant_on_openwrt.

littleboot avatar littleboot commented on June 12, 2024

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!

from homeassistant_on_openwrt.

devbis avatar devbis commented on June 12, 2024

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.

from homeassistant_on_openwrt.

littleboot avatar littleboot commented on June 12, 2024

@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.

from homeassistant_on_openwrt.

littleboot avatar littleboot commented on June 12, 2024

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

pip-log.txt

home-assistant_2022-12-29T23-02-24.129Z.log

from homeassistant_on_openwrt.

devbis avatar devbis commented on June 12, 2024

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.

from homeassistant_on_openwrt.

littleboot avatar littleboot commented on June 12, 2024

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.

from homeassistant_on_openwrt.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.