I get the following error for some workflows. Restarting them always solves the problem, but doing this manually for each instance is not practical in our setup.
This task is currently locked by a running workflow and cannot be edited.
From what I have found out, there is a WorkflowVersion flag with the tasklist item associated with the workflow which is set to a value != 1 whenever there is an error. Once I have detected this error how do I restart the workflow? Or are there any other ways to tackle this problem?