Giter Club home page Giter Club logo

redfincrawler's Introduction

redfinCrawler

This is a Python crawler to check the newly available houses on Redfin website.

Get Started Locally

  1. Update the target URL in redfinIrvine.py as you like.

    Redfin has a special region id for each city, e.g. Irvine is 9361. URL = "https://www.redfin.com/city/9361/CA/Irvine/filter/property-type=house+condo+townhouse,max-price=750k,max-beds=3,min-baths=2" Or you can go with zipcode: https://www.redfin.com/zipcode/94086

  2. Update base_path and work_path in redfinIrvine.py on your machine.

  3. Use crontab (on Mac or Linux) to schedule the Python scripts. e.g.:

    0 10,16 * * * /anaconda3/bin/python3 /Users/zixxu/Documents/Learning/crawler/redfinIrvine.py >| /Users/zixxu/Documents/Learning/crawler/log/redfinIrvine.log 2>&1
    5 13 * * * /anaconda3/bin/python3 /Users/zixxu/Documents/Learning/crawler/storeData.py >| /Users/zixxu/Documents/Learning/crawler/log/storeData.log 2>&1
    

    Note: ">|" means overwrite, need noclobber flag on (set -o | grep noclobber)

  4. There will be a .csv file downloaded which will be processed by Python scripts. Then host the webpage through Nginx:

    sudo nginx
    

    And go to http://localhost:[port] to see the crawler results. You can edit the Nginx config file at /usr/local/etc/nginx/.

Possible Improvements

  1. Server side: Use an actual server instead of local computer. We can use AWS to hold the Python scripts and Webpages, also move crontab scheduler there.
  2. Client side: Use React.js instead of web component.

redfincrawler's People

Contributors

spider-detective avatar

Stargazers

 avatar

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.