Skip to main content

create_undo_snapshot

Function create_undo_snapshot 

Source
pub fn create_undo_snapshot(
    resolved: &Resolved,
    operation: &str,
) -> Result<PathBuf>
Expand description

Create a snapshot before a mutation operation.

This should be called AFTER acquiring the queue lock but BEFORE performing any modifications. The snapshot captures both queue.json and done.json atomically.

§Arguments

  • resolved - Resolved configuration containing paths
  • operation - Human-readable description of the operation (e.g., “complete_task RQ-0001”)

§Returns

Path to the created snapshot file.