my $success; while (! $success) { eval { $mech->get(@_); }; if (! $@) { $success = 1; } else { sleep $CONFIG{DELAY}; } }