add abilty to stop with keyboardinterrupt