GithubHelp home page GithubHelp logo

tristanlatr / charityvillage_jobs Goto Github PK

View Code? Open in Web Editor NEW

This project forked from scrapy/quotesbot

2.0 1.0 1.0 87 KB

This is a sample Scrapy project for educational purposes

Home Page: http://doc.scrapy.org/en/latest/intro/tutorial.html

License: MIT License

Python 100.00%

charityvillage_jobs's Introduction

Charity Village Jobs Scraper

This is a raw Scrapy project to scrape job postings from charityvillage.com.

See Alt Job fore more supported websites and email notification feature.

Install

git clone https://github.com/tristanlatr/charityvillage_jobs.git
cd charityvillage_jobs
python3 setup.py install

Extracted data

This project extracts quotes, combined with the respective author names and tags. The extracted data looks like this sample:

{
    "url": "https://charityvillage.com/jobs/director-of-teacher-recruitment-in-toronto-toronto-division-ontario-ca/",
    "date_posted": "August 26, 2020",
    "apply_before": "September 30, 2020",
    "organisation": "\n\t\t\t\t\t\t\t\tTeach For Canada\n\t\t\t\t\t\t\t",
    "location": "Remote",
    "title": "Director of Teacher Recruitment"
}

Spider

This project contains one spiders and you can see it using the list command:

$ scrapy list
charityvillage.com

Running the spider

You can run a spider using the scrapy crawl command, such as:

$ scrapy crawl charityvillage.com

If you want to save the scraped data to a file, you can pass the -o option:

$ scrapy crawl charityvillage.com -o jobs.json 

If you want to scrape from a specific search URL, you can pass the -a "url={}" option:

$ scrapy crawl charityvillage.com -o jobs.json -a "url=https://charityvillage.com/search/#results/5f4eb8f2b5ea676537f41bd5?kw=&loc=Ottawa&page_num=1"

If you want to load jobs pages individually ans scrape more infos, you can pass the -a "load_full_jobs=True" option:

$ scrapy crawl charityvillage.com -o jobs.json -a "load_full_jobs=True" -a "url=https://charityvillage.com/search/#results/5f4eb8f2b5ea676537f41bd5?kw=&loc=Ottawa&page_num=1"

If you want to load all available pages and scrape more job postings, you can pass the -a "load_all_pages=True" option:

$ scrapy crawl charityvillage.com -o jobs.json -a "load_all_pages=True" -a "url=https://charityvillage.com/search/#results/5f4eb8f2b5ea676537f41bd5?kw=&loc=Ottawa&page_num=1"

Testing the spider

You can run the automatic docstrings testing, Contracts test by running:

$ scrapy check

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.