-
-
Notifications
You must be signed in to change notification settings - Fork 29k
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鈥檒l occasionally send you account related emails.
Already on GitHub? Sign in to your account
ESPHome prevent connecting to different hosts when IP reassigned #64559
Conversation
Hey there @jesserockz, mind taking a look at this pull request as it has been labeled with an integration ( |
Line 292 in e59510f
Edit: ah, apparently it calcuates in the changes from the initial branching point (months ago), and compared to that some coverage changed in mqtt and so on (but doesn't affect this PR) |
How does this look in the HA UI, and how would a user go about fixing it? |
Right, I didn't think about that. We can catch this issue in Background:
For 1 I think the maximum we should do is printing an error. For 2 the user must have set up the device manually (without discovery) by entering an IP. In this case I think it's expected that if the IP changes it stops working, and a log error should be enough. For 3 a config flow would be best, but since the process is already complicated I guess we can just add an additional step to the ESPHome guide about changing nodes' names. |
Proposed change
Prevent ESPHome connecting to the incorrect host when the old one got reassigned to a new IP address but HA hasn't received the updated mDNS record yet.
This change required a protocol addition (both sides still support older peers), hence the minor aioesphomepi version bump.
More information here: esphome/aioesphomeapi#122 and #52239
Changelog: https://github.com/esphome/aioesphomeapi/releases/tag/v10.8.0 and https://github.com/esphome/aioesphomeapi/releases/tag/v10.8.1
Type of change
Additional information
Checklist
black --fast homeassistant tests
)If user exposed functionality or configuration variables are added/changed:
If the code communicates with devices, web services, or third-party tools:
Updated and included derived files by running:
python3 -m script.hassfest
.requirements_all.txt
.Updated by running
python3 -m script.gen_requirements_all
..coveragerc
.The integration reached or maintains the following Integration Quality Scale:
To help with the load of incoming pull requests: