def find_next(self):
if int(self.num_retries) < <NUM_LIT:0>:  <EOL><INDENT>self._cnt_retries += <NUM_LIT:1><EOL>sleeptime = (self._cnt_retries - <NUM_LIT:1>) * <NUM_LIT:2> if self._cnt_retries < <NUM_LIT:10> else <NUM_LIT:10><EOL>if sleeptime:<EOL><INDENT>log.warning(<EOL>"<STR_LIT>"<EOL>% (self.url, self._cnt_retries, self.num_retries)<EOL>+ "<STR_LIT>" % sleeptime<EOL>)<EOL>sleep(sleeptime)<EOL><DEDENT>return next(self.urls)<EOL><DEDENT>urls = [<EOL>k<EOL>for k, v in self._url_counter.items()<EOL>if (<EOL>int(self.num_retries) >= <NUM_LIT:0><EOL>and v <= self.num_retries<EOL>and (k != self.url or len(self._url_counter) == <NUM_LIT:1>)<EOL>)<EOL>]<EOL>if not len(urls):<EOL><INDENT>raise NumRetriesReached<EOL><DEDENT>url = urls[<NUM_LIT:0>]<EOL>return url<EOL>
Find the next url in the list