updated to add extra try/catch retry