core/homeassistant/components/recorder
J. Nick Koston 93b01a3bc3
Fix minimum schema version to run event_id_post_migration (#139014)
* Fix minimum version to run event_id_post_migration

The table rebuild to fix the foreign key constraint was added
in https://github.com/home-assistant/core/pull/120779 but the
schema version was not bumped so we need to make sure
any database that was created with schema 43 or older
still has the migration run as otherwise they will not
be able to purge the database with SQLite since each
delete in the events table will due a full table scan
of the states table to look for a foreign key that is
not there

fixes #138818

* Apply suggestions from code review

* Update homeassistant/components/recorder/migration.py

* Update homeassistant/components/recorder/migration.py

* Update homeassistant/components/recorder/const.py

* Apply suggestions from code review

* Apply suggestions from code review

* Apply suggestions from code review

* Apply suggestions from code review

* update tests, add more cover

* update tests, add more cover

* Update tests/components/recorder/test_migration_run_time_migrations_remember.py
2025-02-22 15:39:12 -05:00
..
auto_repairs
history
models
system_health
table_managers
__init__.py
backup.py
basic_websocket_api.py
const.py Fix minimum schema version to run event_id_post_migration (#139014) 2025-02-22 15:39:12 -05:00
core.py
db_schema.py
entity_registry.py
executor.py
filters.py
icons.json
manifest.json
migration.py Fix minimum schema version to run event_id_post_migration (#139014) 2025-02-22 15:39:12 -05:00
pool.py
purge.py
queries.py
repack.py
services.py
services.yaml
statistics.py
strings.json
tasks.py
util.py
websocket_api.py