Resets tasks with specified statuses back to idle (NULL) state, clearing their execution history. This allows them to be picked up by workers again.
Usage
task_reset(project, status = c("working", "failed"), con = NULL)Details
Resetting tasks clears:
Status (set to NULL/idle)
Start time
Finish time
Error messages
Common use cases:
Reset failed tasks after fixing code:
status = "failed"Reset interrupted tasks:
status = "working"Re-run everything:
status = "all"
Specifying status = "all" resets all tasks regardless of current status.
Examples
if (FALSE) { # \dontrun{
# Not run:
# Reset only failed tasks
task_reset("simulation_study", status = "failed")
# Reset working tasks (e.g., after project_stop)
task_reset("simulation_study", status = "working")
# Reset all tasks to start over
task_reset("simulation_study", status = "all")
# Check status after reset
task_status("simulation_study")
} # }