本地运行没问题部署后运行爬虫很快就停了找不到文件FileNotFoundError不知道在哪里找原因
2017-12-04 18:43:29 [twisted] CRITICAL:
Traceback (most recent call last):
File "c:\users\administrator\envs\p3spider\lib\site-packages\twisted\internet\defer.py", line 1386, in _inlineCallbacks
result = g.send(result)
File "c:\users\administrator\envs\p3spider\lib\site-packages\scrapy\crawler.py", line 77, in crawl
self.engine = self._create_engine()
File "c:\users\administrator\envs\p3spider\lib\site-packages\scrapy\crawler.py", line 102, in _create_engine
return ExecutionEngine(self, lambda _: self.stop())
File "c:\users\administrator\envs\p3spider\lib\site-packages\scrapy\core\engine.py", line 70, in __init__
self.scraper = Scraper(crawler)
File "c:\users\administrator\envs\p3spider\lib\site-packages\scrapy\core\scraper.py", line 71, in __init__
self.itemproc = itemproc_cls.from_crawler(crawler)
File "c:\users\administrator\envs\p3spider\lib\site-packages\scrapy\middleware.py", line 58, in from_crawler
return cls.from_settings(crawler.settings, crawler)
File "c:\users\administrator\envs\p3spider\lib\site-packages\scrapy\middleware.py", line 36, in from_settings
mw = mwcls.from_crawler(crawler)
File "c:\users\administrator\envs\p3spider\lib\site-packages\scrapy\pipelines\media.py", line 68, in from_crawler
pipe = cls.from_settings(crawler.settings)
File "c:\users\administrator\envs\p3spider\lib\site-packages\scrapy\pipelines\images.py", line 95, in from_settings
return cls(store_uri, settings=settings)
File "c:\users\administrator\envs\p3spider\lib\site-packages\scrapy\pipelines\images.py", line 52, in __init__
download_func=download_func)
File "c:\users\administrator\envs\p3spider\lib\site-packages\scrapy\pipelines\files.py", line 234, in __init__
self.store = self._get_store(store_uri)
File "c:\users\administrator\envs\p3spider\lib\site-packages\scrapy\pipelines\files.py", line 270, in _get_store
return store_cls(uri)
File "c:\users\administrator\envs\p3spider\lib\site-packages\scrapy\pipelines\files.py", line 48, in __init__
self._mkdir(self.basedir)
File "c:\users\administrator\envs\p3spider\lib\site-packages\scrapy\pipelines\files.py", line 77, in _mkdir
os.makedirs(dirname)
File "c:\users\administrator\envs\p3spider\lib\os.py", line 231, in makedirs
makedirs(head, mode, exist_ok)
File "c:\users\administrator\envs\p3spider\lib\os.py", line 241, in makedirs
mkdir(name, mode)
FileNotFoundError: [WinError 3] 系统找ä¸åˆ°æŒ‡å®šçš„路径。: 'c:\\users\\admini~1\\appdata\\local\\temp\\articlespider-1512384126-2rpi5uvj.egg\\ArticleSpider'
带你彻底掌握Scrapy,用Django+Elasticsearch搭建搜索引擎
了解课程