mirror of
https://github.com/scrapy/scrapy.git
synced 2025-02-24 13:23:59 +00:00
register AutoThrottle extension by default, and made AUTOTHROTTLE_ENABLED disabled by default
This commit is contained in:
parent
dcc28b7186
commit
756bf0cc06
@ -66,7 +66,7 @@ class AutoThrottle(object):
|
||||
DEBUG = 0
|
||||
|
||||
def __init__(self):
|
||||
if not settings.getbool('AUTOTHROTTLE_ENABLED', True):
|
||||
if not settings.getbool('AUTOTHROTTLE_ENABLED'):
|
||||
raise NotConfigured
|
||||
dispatcher.connect(self.spider_opened, signal=signals.spider_opened)
|
||||
dispatcher.connect(self.spider_closed, signal=signals.spider_closed)
|
||||
|
@ -126,6 +126,7 @@ EXTENSIONS_BASE = {
|
||||
'scrapy.contrib.closespider.CloseSpider': 0,
|
||||
'scrapy.contrib.feedexport.FeedExporter': 0,
|
||||
'scrapy.contrib.spidercontext.SpiderContext': 0,
|
||||
'scrapy.contrib.throttle.AutoThrottle': 0,
|
||||
}
|
||||
|
||||
FEED_URI = None
|
||||
|
Loading…
x
Reference in New Issue
Block a user