Gregory Petukhov  committed ec364b5

Fix proxylist issues

  • Participants
  • Parent commits eeab043
  • Branches default

Comments (0)

Files changed (2)

File grab/

         if (self.read_time is None or
             (time.time() - self.read_time) > self.read_timeout):
-            logging.debug('Reloading proxy list')
+            logger.debug('Reloading proxy list')
         Return next server in the list.
-        logging.debug('Changing proxy')
+        logger.debug('Changing proxy')

File grab/spider/

     # Deprecated methods
-    def setup_proxylist(self, proxy_file=None, proxy_type='http', read_timeout=None,
+    def setup_proxylist(self, proxy_file=None, proxy_type='http',
                         auto_init=True, auto_change=True,
-                        server_list=None):
+                        server_list=None, **kwargs):
         logging.error('Method `setup_proxylist` is deprecated. Use `load_proxylist` instead.')
         if server_list is not None:
             raise error.GrabMisuseError('setup_proxylist: the argument `server_list` is not suppported more')
         self.proxylist = ProxyList(source, source_type, proxy_type=proxy_type,
-                                   read_timeout=read_timeout)
+                                   **kwargs)
         self.proxylist_enabled = True
         self.proxy = None
         if not auto_change and auto_init: