core/homeassistant/helpers
J. Nick Koston 01e66d6fb2
Improve handling of unrecoverable storage corruption (#96712)
* Improve handling of unrecoverable storage corruption

fixes #96574

If something in storage gets corrupted core can boot loop
or if its integration specific, the integration will fail to
start.

We now complainly loudly in the log, move away the corrupt data
and start fresh to allow startup to proceed so the user can
get to the UI and restore from backup without having to attach
a console (or otherwise login to the OS and manually modify files).

* test for corruption

* ensure OSError is still fatal

* one more case

* create an issue for corrupt storage

* fix key

* persist

* feedback

* feedback

* better to give the full path

* tweaks

* grammar

* add time

* feedback

* adjust

* try to get issue_domain from storage key

* coverage

* tweak wording some more
2023-07-19 09:23:12 +02:00
..
service_info
__init__.py
aiohttp_client.py
aiohttp_compat.py
area_registry.py
check_config.py
collection.py Add TypeVar defaults for DataUpdateCoordinator and EntityComponent (#95026) 2023-06-22 03:33:23 +02:00
condition.py
config_entry_flow.py
config_entry_oauth2_flow.py
config_validation.py Improve the docstring of some config schema generators (#96296) 2023-07-11 11:34:16 +02:00
data_entry_flow.py
debounce.py
deprecation.py
device_registry.py Move device info validation to device registry (#96465) 2023-07-14 08:55:17 -04:00
discovery.py
discovery_flow.py
dispatcher.py
entity.py Only load the device entry when it changes in the base entity (#95801) 2023-07-10 15:17:35 +02:00
entity_component.py Add service response data for listing calendar events (#94759) 2023-06-23 23:34:34 -04:00
entity_platform.py Move device info validation to device registry (#96465) 2023-07-14 08:55:17 -04:00
entity_registry.py Stable entity registry id when a deleted entity is restored (#77710) 2023-06-26 15:54:35 +02:00
entity_values.py Limit cache size of EntityValues (#94983) 2023-06-21 22:23:35 +02:00
entityfilter.py Reduce code in entity filter (#94882) 2023-06-21 08:37:19 +01:00
event.py
frame.py
httpx_client.py Tune httpx keep alives for polling integrations (#95782) 2023-07-03 14:21:59 -04:00
icon.py
instance_id.py
integration_platform.py
intent.py
issue_registry.py
json.py
location.py
network.py
ratelimit.py
recorder.py
reload.py
restore_state.py
schema_config_entry_flow.py
script.py Move overlapping pylint rules to ruff, disable mypy overlap (#94359) 2023-06-27 17:42:46 +02:00
script_variables.py
selector.py Make default theme selectable for set theme service (#96849) 2023-07-18 17:36:35 +02:00
sensor.py
service.py Speed up single entity/response service calls (#96729) 2023-07-17 09:33:13 +02:00
signal.py
significant_change.py
singleton.py Update mypy to 1.4.0 (#94987) 2023-06-21 16:12:51 +02:00
start.py
state.py Remove deprecated state.get_changed_since (#96579) 2023-07-18 09:42:48 +02:00
storage.py Improve handling of unrecoverable storage corruption (#96712) 2023-07-19 09:23:12 +02:00
sun.py
system_info.py Ensure async_get_system_info does not fail if supervisor is unavailable (#96492) 2023-07-16 11:10:07 -04:00
temperature.py
template.py
template_entity.py Allow stopping a script with a response value (#95284) 2023-06-27 08:24:22 +02:00
trace.py Use slots in TraceElement (#95877) 2023-07-05 08:44:00 +02:00
translation.py Add support for service translations (#95984) 2023-07-11 15:52:12 +02:00
trigger.py
typing.py Replace EventType annotations with Event (#96426) 2023-07-18 08:51:06 +02:00
update_coordinator.py Partial revert "Add TypeVar defaults for DataUpdateCoordinator (#95026)" (#95101) 2023-06-23 14:42:34 +02:00