wrapping the script to contain errors and amke it easier to retry a few times, which almost totally eliminates problems except 404 errors