Closed skarcha closed 4 years ago
I was also trying to revert the commit, but indeed it has a lot of changes. It would be good to have smaller commits with individual changes :/
Thanks for trying, @abmantis 👍
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
So the scheduler that was introduced in the mentioned commit first had an issue (that would only show up in certain configurations, thus it was not caught immediately). See also git history here: https://github.com/esphome/esphome/commits/dev/esphome/core/scheduler.cpp
That probably means the git bisect is tainted (or at least doesn't give accurate result) because the pattern is not fail, fail, fail, ..., good, good, good
.
Thanks for trying to bisect it. As for the big commits: We squash commits to keep the git history cleaner, obviously that makes git bisecting harder (but it should be possible if you switch to the branch of the PR).
Operating environment/Installation (Hass.io/Docker/pip/etc.):
Ubuntu 18.04, Kubuntu 19.10, several versions of Python, pip, esphome, etc.
ESP (ESP32/ESP8266, Board/Sonoff):
ESP8266. Board D1 Mini.
Affected component:
Wifi
Description of problem:
I have an ESP8266 configured as deep sleep with an BME280 and a ds18b20. All is powered by a 18650 battery and a solar panel.
The system works like a charm with v1.13.6, but it fails with v1.14.3 and 'dev'. It takes several minutes to connect to wifi (if connect), so it continues reading sensors, etc. but doesn't begin deep sleep because it can't connect to wifi. Sometimes it connects, enter deep sleep and when wakes up, the same cycle.
Problem-relevant YAML-configuration entries:
Logs (if applicable):
I provide two logs. The first one with a good connection, a deep sleep, wake up and good conection again.
The second one is a bad/no connect. It shows some retries to connect to wifi and mqtt and never enter deep sleep, so I canceled the log manually.
Good connection using commit: 7a895adec9dcf49c245ea2cfabab461d348ba2d7
Bad connection using commit: a55787f40caf11e8c7ed83aff76dd1205c5a50f6
Additional information and things you've tried:
I decided to git bisect and after "some" work I found the last commit that works without problems: 7a895adec9dcf49c245ea2cfabab461d348ba2d7
After it, new scheduler was introduced in this commit: b51cbc420766a008d0ed55973898df5a143a38b3 (with other changes, so more dificult to git bisec and isolate problems). After it, I tried this commit 8db6f3129cb35a9a0fe8c5c4977af5be9521c2db (no logs provided, sorry) and Wifi connection works fine but not MQTT.
BUT, the key is in the next commit, 36f47ade70351e8d5ddbc6ec608b3092427f54bb, where captive portal is introduced, and with that commit starts the connection problems.
I've read some closed issues, like #455, even tried changing the output power, but I'm pretty sure the problem is the code changed to add captive portal. In git bisect I trust.. :-)
Hope this logs and info helps to solve the problem. If you need more, I'm glad to provide more logs or info.
P.S: I LOVE this software. A great idea and simple to configure and maintain. Congrats and thanks!
P.S.2: I'd suggest do more specific commit, avoid squash unrelated commits and create and merge hotfix branches instead cherry-picking to help with git bisect. Also use
pip freeze
every now and then; I had to edit requirements_test.txt in some commits to forcevoluptuous
andplatformio
versions.