Skip to content
dev
Go to file
Code

Latest commit

…t from under the recorder (#43610)

* MariaDB doesn't purge #42402

This addresses  #42402
Relationships within table "states" and between tables "states" and "events " #40467 prevent the purge from working correctly. The database increases w/o any purge.
This proposal sets related indices to NULL and permits deleting of rows.
Further explanations can be found here #42402
This proposal also allows to purge the tables "events" and "states" in any order.

* Update models.py

Corrected for Black style requirements

* Update homeassistant/components/recorder/models.py

Co-authored-by: J. Nick Koston <nick@koston.org>

* Add the options to foreign key constraints

* purge old states when database gets deleted out from under us

* pylint

Co-authored-by: J. Nick Koston <nick@koston.org>
337b8d2

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time

README.rst

Home Assistant Chat Status

Open source home automation that puts local control and privacy first. Powered by a worldwide community of tinkerers and DIY enthusiasts. Perfect to run on a Raspberry Pi or a local server.

Check out home-assistant.io for a demo, installation instructions, tutorials and documentation.

screenshot-states

Featured integrations

screenshot-components

The system is built using a modular approach so support for other devices or actions can be implemented easily. See also the section on architecture and the section on creating your own components.

If you run into issues while using Home Assistant or during development of a component, check the Home Assistant help section of our website for further help and information.

You can’t perform that action at this time.