It was failing everytime but I just ran it twice now and got my combined results. I will keep testing. I don't think the code has a bug per se just that in India where my connection is so variable I think a more robust way of dealing with errors would be good.