Skip to main content

Python scrapper / mailer for the french ad website

Project description

This is a simple Python scrapper for the french ad website that mails you the latest ads you are interested in.

Synopsis & Motivation

I developed this small tool for two reasons:

  • laziness: I don’t want to go to the website and manually search for stuff every days,
  • speed: I want to receive some ads quickly to be contact the sellers ASAP.


  • Install the project:

    $ pip install leboncrevard
  • You can set the configuration with the following environment variables (an SMTP server that supports STARTTLS is mandatory, Gmail is fine):

    $ export LBC_SMTP_USER="user"
    $ export LBC_SMTP_PASS="pass"
    $ export LBC_SMTP_SERVER=""
    $ export LBC_JOB_FILE="jobs.csv"
    $ export LBC_DELETE_FILE="delete.csv"
  • Fill the “job file” defined by LBC_JOB_FILE (see syntax below), default is jobs.csv

  • Run the application:

    $ leboncrevard &>> leboncrevard.log

The entries in both of these files should look like this:


The numeric field is the time interval (in minutes) you want between scraping sessions. You can add new entries, the script parses the file regularly and will add them. You can also delete jobs by moving then from the “job file” to the “delete file” (interval and recipients are ignored when deleting a job, all instances are removed).

The script will create csv files using job names in order to store an history of already mailed ads.

Limitations and bugs

Seems to run quite well for me, but there may be bugs that I did not foresee or triggered through usage. Feel free to open issues and pull requests.


Usual stuff, I am not a professional Python developer and made this for my personal use. Feel free to use it at your own risks.

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

leboncrevard-0.1.1.tar.gz (5.2 kB view hashes)

Uploaded source

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Huawei Huawei PSF Sponsor Microsoft Microsoft PSF Sponsor NVIDIA NVIDIA PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page