If the yaml file has invalid utf-8, the config flow would raise an
unhandled exception. Allow the encryption key to be entered manually
in this case instead of a hard failure
fixes#92772
* Fix source device when source entity is changed
* Update loop
* Complement and add comments in the test_change_device_source test
* Only clean up dev reg when options change
---------
Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
* Avoid regex for negative zero check in sensor
We can avoid calling the regex for every sensor value
since most of the time values are not negative zero
* tweak
* tweak
* Apply suggestions from code review
* simpler
* cover
* safer and still fast
* safer and still fast
* prep for py3.11
* fix check
* add missing cover
* more coverage
* coverage
* coverage
Remove generated translation
Raise error correctly
Remove obsolete consts
Remove callback, hass assignment and info log
Use name from LOQED API instead of default name
Correct entity name for assertion
* Create Opower integration
* fix tests
* Update config_flow.py
* Update coordinator.py
* Update sensor.py
* Update sensor.py
* Update coordinator.py
* Bump opower==0.0.4
* Ignore errors for "recent" PGE accounts
* Add type for forecasts
* Bump opower to 0.0.5
* Bump opower to 0.0.6
* Bump opower to 0.0.7
* Update requirements_all.txt
* Update requirements_test_all.txt
* Update coordinator
Fix exception caused by https://github.com/home-assistant/core/pull/92095
{} is dict but the function expects a set so change it to set()
* Improve exceptions handling
* Bump opower==0.0.9
* Bump opower to 0.0.10
* Bump opower to 0.0.11
* fix issue when integration hasn't run for 30 days
use last stat time instead of now when fetching recent usage/cost
* Allow username to be changed in reauth
* Don't allow changing username in reauth flow
* Handle incorrect or missing device name for ESPHome noise encryption
If we did not have the device name during setup we could never
get the key from the dashboard. The device will send us
its name if we try encryption which allows us to find the
right key from the dashboard.
This should help get users unstuck when they change the key
and cannot get the device back online after deleting and
trying to set it up again manually
* bump lib to get name
* tweak
* reduce number of connections
* less connections when we know we will fail
* coverage shows it works but it does not
* add more coverage
* fix test
* bump again
* Update log message when referenced entity not found
* Update homeassistant/helpers/service.py
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
* Update test
---------
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>