Scrapy, a fast high-level web crawling & scraping framework for Python.
fix a bug with rescheduling a domain when no free slot are in worker (a domain was passed instead of a list, and that raises the one-letter domains bug), also reschedule with priority=0)
olveyrafc4e0eaa2a9e
diff --git a/scrapy/trunk/scrapy/contrib/pbcluster/master/manager.py b/scrapy/trunk/scrapy/contrib/pbcluster/master/manager.pyindex c889facb0..7abced133 100644--- a/scrapy/trunk/scrapy/contrib/pbcluster/master/manager.py+++ b/scrapy/trunk/scrapy/contrib/pbcluster/master/manager.py@@ -80,7 +80,7 @@ class Node:def _run_callback(status):if status['callresponse'][0] == 1:#slots are complete. Reschedule in master. This is a security issue because could happen that the slots were completed since last status update by another cluster (thinking at future with full-distributed worker-master clusters)- self.master.schedule(pending['domain'], pending['settings'], pending['priority'])+ self.master.schedule([pending['domain']], pending['settings'], PRIORITY_NOW)log.msg("Domain %s rescheduled: no proc space in node." % pending['domain'], log.WARNING)self._set_status(status)