How to run the Scrapy project in Eclipse+pydev

Source: Internet
Author: User


    • Reference link: https://www.zhihu.com/question/28565716 (eclipse+pydev configuration)
    • Reference link: http://www.cnblogs.com/kongzhagen/p/6549053.html (scrapy crawler Simple example)
1. Create a new Python project via Eclipse+pydev


Set up




2. You can create a project from the Scrapy command line to the newly built Eclipse project:/users/it-0003005/documents/workspace/testscrapy1 or copy a scrapy item directly into this directory. A. A new Scrapy project was created


it-0003005mac:~ it-0003005$ cd/users/it-0003005/documents/workspace/testscrapy1
It-0003005mac:testscrapy1 it-0003005$ scrapy startproject pic
2017-08-19 04:47:13 [scrapy] info:scrapy 1.0.3 started (Bot:scrapybot)
2017-08-19 04:47:13 [Scrapy] info:optional features Available:ssl, HTTP11
2017-08-19 04:47:13 [scrapy] Info:overridden settings: {}
New scrapy project ' pic ' created in:
/users/it-0003005/documents/workspace/testscrapy1/pic



You can start your first spider with:
CD pic
Scrapy Genspider Example example.com
It-0003005mac:testscrapy1 it-0003005$ CD pic
It-0003005mac:pic it-0003005$ scrapy genspider xh xiaohuar.com
Created spider ' xh ' using template ' Basic ' in module:
Pic.spiders.xh


B. Refreshing a project at eclipse





3. Configure the compilation options for Eclipse


Run, run configurations, delete the old configuration file under Python Run and create a new one.








How to run the Scrapy project in Eclipse+pydev


Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.