RestartTask assumes that task slugs are unique instance-wide
- Create two processes.
- Restart the
initialisationtask on one process. Assuming you had a clean DB before, the old task gets renamed toinitialisation_old1. - Restart the
initialisationtask on the other process. The old task gets renamed toinitialisation_old2, instead ofinitialisation_old1as expected. - Retry one of the processes.
- Restart the
initialisationtask on that second run. It is againinitialisation_old1. - Cry.
RestartTask filters existing tasks by run when determining which suffix to add, but not by process!