Python HTML CSS Other
Latest commit fe3125f Feb 23, 2017 @bartromgens bartromgens change voting result 'verworpen' icon
The remove x looked like it could close or remove the
item when clicked on.


Build Status Coverage Status Dependency Status

Openkamer gives insight into the Dutch parliament by gathering, organizing and visualizing parliamentary data.

Openkamer gathers (scrapes) parliamentary data from several external sources, creates relations, and visualizes this data in a web application.

Openkamer is a Python 3.4+ and Django 1.10+ project under MIT license.

Installation (Linux)

Get the code and enter the project directory,

$ git clone
$ cd openkamer

Install in a local environment (creates a Python 3 virtualenv and a sqlite database file),

$ ./

Activate the virtualenv,

$ source env/bin/activate


There are 3 options to fill your database with data.

Option 1: Load a json dump from (5 min)

This will fill your database with all openkamer data. Download the latest openkamer-<date>.json.gz file from
Load this data into your local database with the following Django command,

$ python loaddata openkamer-<date>.json.gz

Option 2: Scrape a small demo data set (10-15 min)

Scrape a demo data subset from external sources. This is the longer, but more exciting method. Scraping demo data can take several minutes and mostly depends on response time of external sources,

$ python create_demo_data

Option 3: Scrape all data from scratch (12-24 hours)

This is how you get all data from scratch; scrape everything from external sources. This will take several hours, but is independent of
Use the following command,

$ python create_data

Run a development server

Run the Django dev web server in the virtualenv,

$ source env/bin/activate
(env)$ python runserver

Openkamer is now available at and


See website/ and website/ for settings.



Run tests

Run all tests,

$ python test

Run specific tests (example),

$ python test website.test.TestCreateParliament
Create test json fixtures
$ python dumpdata --all --natural-foreign --indent 2 auth.User auth.Group person parliament government document website > website/fixtures/<fixture_name>.json


Openkamer has some optional cronjobs that do some cool stuff. You can review them in website/
Create the following cronjob (Linux) to kickstart the django-cron jobs,

$ crontab -e
*/5 * * * * source /home/bart/.bashrc && source /home/<path-to-openkamer>/openkamer/env/bin/activate && python /home/<path-to-openkamer>/website/ runcrons > /home/<path-to-openkamer>/log/cronjob.log