mirror of https://github.com/scrapy/scrapy.git
renamed setting SCRAPY_PICKLED_SETTINGS to
SCRAPY_PICKLED_SETTINGS_TO_OVERRIDE --HG-- extra : convert_revision : svn%3Ab85faa78-f9eb-468e-a121-7cced6da292c%4064
This commit is contained in:
parent
11bc122a54
commit
2b6189a3f8
|
|
@ -13,7 +13,7 @@ class Settings(object):
|
|||
core = None
|
||||
|
||||
def __init__(self):
|
||||
pickled_settings = os.environ.get("SCRAPY_PICKLED_SETTINGS")
|
||||
pickled_settings = os.environ.get("SCRAPY_PICKLED_SETTINGS_TO_OVERRIDE")
|
||||
self.overrides = pickle.loads(pickled_settings) if pickled_settings else {}
|
||||
self.settings = self._import(SETTINGS_MODULE)
|
||||
self.defaults = {}
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@ class ScrapyProcessProtocol(protocol.ProcessProtocol):
|
|||
self.scrapy_settings = spider_settings or {}
|
||||
self.scrapy_settings.update({'LOGFILE': self.logfile, 'CLUSTER_WORKER_ENABLED': '0', 'WEBCONSOLE_ENABLED': '0'})
|
||||
pickled_settings = pickle.dumps(self.scrapy_settings)
|
||||
self.env["SCRAPY_PICKLED_SETTINGS"] = pickled_settings
|
||||
self.env["SCRAPY_PICKLED_SETTINGS_TO_OVERRIDE"] = pickled_settings
|
||||
self.env["PYTHONPATH"] = ":".join(sys.path)#this is need so this crawl process knows where to locate local_scrapy_settings.
|
||||
|
||||
def __str__(self):
|
||||
|
|
|
|||
Loading…
Reference in New Issue