rekordbox_set_list_manager.services.autosave#

Periodic autosave and crash-recovery helpers.

Attributes#

Functions#

write_autosave(project)

Write project to the autosave slot for its id. Silent on error.

read_autosave(project_id)

Return the autosaved project for project_id, or None if absent/corrupt.

autosave_mtime(project_id)

Return the mtime of the autosave file, or 0.0 if it does not exist.

clear_autosave(project_id)

Remove the autosave file for project_id. Silent on error.

Module Contents#

rekordbox_set_list_manager.services.autosave.CRASH_LOG[source]#
rekordbox_set_list_manager.services.autosave.write_autosave(project)[source]#

Write project to the autosave slot for its id. Silent on error.

Parameters:

project (Project) – The project to persist to the autosave file.

Return type:

None

rekordbox_set_list_manager.services.autosave.read_autosave(project_id)[source]#

Return the autosaved project for project_id, or None if absent/corrupt.

Parameters:

project_id (UUID) – The project ID whose autosave file to load.

Returns:

The deserialised project, or None if the autosave does not exist or cannot be read.

Return type:

Project | None

rekordbox_set_list_manager.services.autosave.autosave_mtime(project_id)[source]#

Return the mtime of the autosave file, or 0.0 if it does not exist.

Parameters:

project_id (UUID) – The project ID whose autosave mtime to query.

Returns:

The file modification timestamp, or 0.0 if the file is missing.

Return type:

float

rekordbox_set_list_manager.services.autosave.clear_autosave(project_id)[source]#

Remove the autosave file for project_id. Silent on error.

Parameters:

project_id (UUID) – The project ID whose autosave file to delete.

Return type:

None