I am using python-rq and redis to pass the domain names and get the links from the domain.
try:
for link in [h.get('href') for h in self.soup.find_all('a')]:
--code goes here--
except Exception, ex:
print ex
pass
Whenever i run the code and any exception is caught, instead of printing and ignoring that domain it is pushed to failed queue. But in the console rq does not print pushing to failed queue
.
The links are getting updated in the db but still the domain is getting pushed in the failed queue. And the count of failed queue is more than the default queue (total number of domains passed).
Why is this happening? Please help