When changing the repeat setting for a task to 'Stop Repeating' all instances in the past are getting deleted including those already completed! I just checked the documentation to confirm that this is not the intended behaviour.