Handle the error emitted from spawn itself