-
Notifications
You must be signed in to change notification settings - Fork 26
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Dependency wish list #586
Comments
My Gentoo Ebuild still can be run with HA 0.108.3 requirements with some harder deviations to the dependency check list. Currently I use
Everything I use (including the dashboard) works again like a charm. |
Ahh thanks for testing and reporting!! |
Hi Guillermo, Here I have several virtual machines used only for Home Assitant, all running Gentoo Linux. I am maintaining Gentoo Overlay for Home Assitant, containing Ebuild Files for (nearly) all modules Home Assistant uses and for ESPHome & Platformio as long as these cannot be found in Gentoo's Main Repository. With the help of Gentoo's package manager I can keep tight control of all installed python modules. On my productive box Home Assistant (0.108.3, yes I know it's old, sorry, short on time during home office days) and ESPHome 1.14.3-r6 run without any virtual environments (except /etc/homeassistant/deps, which i try to keep empty) on Python 3.7.7-r1. Also I have a Box for development and testing with Python 3.7.7-r1, and another one for Python 3.8.2-r1. I wrote more about my setup in my README.md. In my home about 30 ESP based devices are in productive duty, and about 15 more are only for tests and development. Most of these run ESPHome. Originated mostly from Home Assitant, after a big cleanup last week, I currently have the following packages installed on the production machine:
As far as I know, https://github.com/esphome/esphome/blob/dev/requirements.txt is not used for setup anyway, so I took ESPHome's dependencies only from setup.py. My Ebuild for ESPHome simply patches esphome.egg-info/requires.txt after unpacking the source prior calling setup.py. This works great for me (and a unknown number of cloners) since I started using esphomeyaml-1.10.0. :-) Thanks again a lot to you all, guys. |
In addition, made some tests with tornado-6.0.4, did not find any problems. 1.14.3 runs good with it. |
Continuously getting better, currently src_prepare() {
sed -e 's;tornado==5.1.1;tornado==6.0.4;' \
-i esphome.egg-info/requires.txt \
-i setup.py
sed -e 's;protobuf==3.11.3;protobuf==3.11.4;' \
-i esphome.egg-info/requires.txt \
-i setup.py
} Last update to Thanks a lot for work. |
Hi, thanks for trying to get gentoo builds. I have a question though: Why not use python venvs? (Maybe gentoo's package manager doesn't have venv-like features?) I understand it's a problem to get ESPHome and HA core to install on the same system without venvs because of the version conflicts. With some packages, we could maybe relax the version pinning a bit (ifaddr, click, colorlog, protobuf, paho-mqtt) - in many other packages we really do need strict version pinning though:
So for a bunch of packages it will be impossible to relax the version pinning. |
Hello Otto, you are very right, one of my main targets is to use Gentoo’s package manager, and yep, currently there’s no way to let it manage venvs. I kept HA's /etc/homeassistant/deps, but usually it is empty. I understand that proper function is much more important than external compatibility, and version pinning makes things a lot easier. I mostly wanted to let you guys know about the versions I am using and that I did not see any problems. But I do not track the changes in the dependant libraries in detail, neither do I extensive testing, I just check if they work for my daily use. On the other hand I believe that using the same libraries (as HA's core does) should make things easier for you, too. Since esphome-1.15.0_beta my list is very short anyway:
If you could just unpin colorlog, my list would be empty, except the new protobuf-3.12.4 upgrade :-) As far as I know, a handful users (including me) are using the dashboard with my Ebuild. So I would say that tornado-6.0.4 works well, I have it running since it went stable in Gentoo's main repo in the beginning of May (during 1.14.4). BTW: If I can help testing anything, please let me know. And: again thanks a lot for this very cool stuff. |
Oh ifaddr and tornado shouldn't be loaded when dashboard is not in use (helps keep startup times low). I'll check where that import is from. |
I don't see any $ python3 -X importtime -m esphome --help
import time: self [us] | cumulative | imported package
import time: 1708 | 1708 | _frozen_importlib_external
import time: 373 | 373 | time
import time: 869 | 1241 | zipimport
import time: 227 | 227 | _codecs
import time: 1528 | 1755 | codecs
import time: 1353 | 1353 | encodings.aliases
import time: 1806 | 4913 | encodings
import time: 755 | 755 | encodings.utf_8
import time: 654 | 654 | _signal
import time: 861 | 861 | encodings.latin_1
import time: 179 | 179 | _abc
import time: 904 | 1082 | abc
import time: 1052 | 2134 | io
import time: 209 | 209 | _stat
import time: 959 | 1168 | stat
import time: 3133 | 3133 | _collections_abc
import time: 352 | 352 | genericpath
import time: 506 | 857 | posixpath
import time: 1616 | 6773 | os
import time: 422 | 422 | _sitebuiltins
import time: 177 | 177 | _locale
import time: 306 | 482 | _bootlocale
import time: 438 | 438 | types
import time: 636 | 636 | warnings
import time: 287 | 1361 | importlib
import time: 242 | 242 | importlib.machinery
import time: 886 | 2488 | importlib.abc
import time: 143 | 143 | _operator
import time: 523 | 665 | operator
import time: 176 | 176 | keyword
import time: 70 | 70 | _heapq
import time: 234 | 303 | heapq
import time: 145 | 145 | itertools
import time: 271 | 271 | reprlib
import time: 1092 | 1092 | _collections
import time: 1363 | 4012 | collections
import time: 84 | 84 | _functools
import time: 983 | 1066 | functools
import time: 806 | 5882 | contextlib
import time: 414 | 6296 | importlib.util
import time: 255 | 255 | _weakrefset
import time: 824 | 1078 | threading
import time: 835 | 10696 | _virtualenv
import time: 151 | 151 | apport_python_hook
import time: 155 | 305 | sitecustomize
import time: 7513 | 26190 | site
import time: 379 | 379 | weakref
import time: 529 | 908 | pkgutil
import time: 217 | 1124 | runpy
import time: 115 | 115 | esphome
import time: 706 | 706 | enum
import time: 74 | 74 | _sre
import time: 277 | 277 | sre_constants
import time: 361 | 637 | sre_parse
import time: 317 | 1027 | sre_compile
import time: 178 | 178 | copyreg
import time: 483 | 2392 | re
import time: 867 | 867 | locale
import time: 858 | 1725 | gettext
import time: 934 | 5050 | argparse
import time: 162 | 162 | token
import time: 979 | 1140 | tokenize
import time: 141 | 1281 | linecache
import time: 271 | 1552 | traceback
import time: 161 | 161 | collections.abc
import time: 39 | 39 | _string
import time: 582 | 621 | string
import time: 40 | 40 | atexit
import time: 1731 | 4103 | logging
import time: 59 | 59 | math
import time: 108 | 108 | _datetime
import time: 673 | 839 | datetime
import time: 328 | 328 | esphome.const
import time: 149 | 149 | _opcode
import time: 212 | 360 | opcode
import time: 356 | 716 | dis
import time: 1396 | 2111 | inspect
import time: 1165 | 1165 | voluptuous.error
import time: 434 | 3710 | voluptuous.schema_builder
import time: 309 | 309 | numbers
import time: 716 | 1024 | _decimal
import time: 145 | 1169 | decimal
import time: 125 | 125 | urllib
import time: 818 | 942 | urllib.parse
import time: 2409 | 4519 | voluptuous.validators
import time: 177 | 177 | voluptuous.util
import time: 191 | 8595 | voluptuous
import time: 1418 | 1418 | typing
import time: 132 | 132 | fnmatch
import time: 71 | 71 | nt
import time: 57 | 57 | nt
import time: 65 | 65 | nt
import time: 57 | 57 | nt
import time: 196 | 444 | ntpath
import time: 59 | 59 | errno
import time: 681 | 1314 | pathlib
import time: 80 | 80 | zlib
import time: 257 | 257 | _compression
import time: 193 | 193 | _bz2
import time: 209 | 659 | bz2
import time: 215 | 215 | _lzma
import time: 214 | 429 | lzma
import time: 42 | 42 | pwd
import time: 31 | 31 | grp
import time: 478 | 1716 | shutil
import time: 34 | 34 | _bisect
import time: 120 | 153 | bisect
import time: 41 | 41 | _sha512
import time: 30 | 30 | _random
import time: 343 | 565 | random
import time: 301 | 2581 | tempfile
import time: 374 | 4268 | esphome.helpers
import time: 729 | 729 | signal
import time: 75 | 75 | msvcrt
import time: 34 | 34 | _posixsubprocess
import time: 50 | 50 | select
import time: 483 | 483 | selectors
import time: 408 | 1776 | subprocess
import time: 423 | 2199 | esphome.util
import time: 699 | 8583 | esphome.core
import time: 1932 | 1932 | esphome.cpp_generator
import time: 140 | 140 | esphome.cpp_types
import time: 166 | 305 | esphome.cpp_helpers
import time: 132 | 2368 | esphome.codegen
import time: 2199 | 2199 | platform
import time: 289 | 289 | _uuid
import time: 1767 | 4254 | uuid
import time: 585 | 585 | difflib
import time: 217 | 802 | esphome.voluptuous_schema
import time: 3687 | 8742 | esphome.config_validation
import time: 820 | 820 | esphome.automation
import time: 771 | 771 | esphome.pins
import time: 1069 | 13768 | esphome.core_config
import time: 271 | 271 | yaml.error
import time: 253 | 253 | yaml.tokens
import time: 240 | 240 | yaml.events
import time: 149 | 149 | yaml.nodes
import time: 4745 | 4745 | yaml.reader
import time: 267 | 267 | yaml.scanner
import time: 262 | 262 | yaml.parser
import time: 164 | 164 | yaml.composer
import time: 66 | 66 | _struct
import time: 110 | 176 | struct
import time: 63 | 63 | binascii
import time: 181 | 418 | base64
import time: 1004 | 1422 | yaml.constructor
import time: 1819 | 1819 | yaml.resolver
import time: 299 | 8975 | yaml.loader
import time: 248 | 248 | yaml.emitter
import time: 157 | 157 | yaml.serializer
import time: 323 | 323 | yaml.representer
import time: 206 | 932 | yaml.dumper
import time: 71 | 71 | _yaml
import time: 124 | 194 | yaml.cyaml
import time: 331 | 11341 | yaml
import time: 153 | 153 | _json
import time: 360 | 512 | json.scanner
import time: 373 | 884 | json.decoder
import time: 397 | 397 | json.encoder
import time: 166 | 1447 | json
import time: 102 | 1549 | esphome.config_helpers
import time: 365 | 13253 | esphome.yaml_util
import time: 466 | 44664 | esphome.config
import time: 188 | 188 | esphome.storage_json
import time: 209 | 45060 | esphome.writer
import time: 972 | 972 | textwrap
usage: __main__.py [-h] [-v] [-q] [-s key value]
[configuration [configuration ...]]
{config,compile,upload,logs,run,clean-mqtt,wizard,mqtt-fingerprint,version,clean,dashboard,vscode,update-all}
...
ESPHome v1.16.0-dev
positional arguments:
configuration Your YAML configuration file.
{config,compile,upload,logs,run,clean-mqtt,wizard,mqtt-fingerprint,version,clean,dashboard,vscode,update-all}
Commands
config Validate the configuration and spit it out.
compile Read the configuration and compile a program.
upload Validate the configuration and upload the latest
binary.
logs Validate the configuration and show all MQTT logs.
run Validate the configuration, create a binary, upload
it, and start MQTT logs.
clean-mqtt Helper to clear an MQTT topic from retain messages.
wizard A helpful setup wizard that will guide you through
setting up esphome.
mqtt-fingerprint Get the SSL fingerprint from a MQTT broker.
version Print the esphome version and exit.
clean Delete all temporary build files.
dashboard Create a simple web server for a dashboard.
vscode ==SUPPRESS==
update-all ==SUPPRESS==
optional arguments:
-h, --help show this help message and exit
-v, --verbose Enable verbose esphome logs.
-q, --quiet Disable all esphome logs.
-s key value, --substitution key value
Add a substitution |
Sorry for keeping you waiting, was a busy week. This is how it looks here:
But, if I call it directly (without tornado installed):
Seems that something is parsing |
Yeay. |
Seems fixed to me. If not, please let me know and I reopen. |
Hello Otto,
first, thanks a lot (again) for your phantastic work.
Describe the problem you have/What new integration you would like
For running ESPHome and the Dashboard in the same environment with HomeAssistant ~0.105.0b* the following module versions would be required, these are partly already met in your dev branch:
Would be nice if you could make a new release soon for the upcoming 0.105.0. It always feels better when a system runs with code approved by the author :-)
Please describe your use case for this integration and alternatives you've tried:
I am currently running esphome-1.14.3-r5 including the following patch:
and can confirm that everything is working (on my ~20 devices) as it should.
Additional context
The text was updated successfully, but these errors were encountered: