This project aims to create an API (with a realtime component) to track UK train delays. There will also be a client app which will consume this API and display the result on a map.
cp conf.example.yml conf.yml
- Change conf.yml to include your credentials
python db_setup.py
cd utils && python import_stanox_lookup.py
This should set you up an environment in which you can run the RailDelay server.
There are two daemons. The first is stomp_listener.py
, which listens for
train movement data and spits it into the database. The second is the main
application server, which still needs to be written. It will provide an API
for the train data, including a realtime websocket endpoint hooked up to
Rethink's change feeds.
- Python 3.4
- RethinkDB 2.0
- And the following Python packages:
beautifulsoup4==4.3.2 Flask==0.10.1 gevent==1.0.1 greenlet==0.4.6 itsdangerous==0.24 jedi==0.9.0 Jinja2==2.7.3 MarkupSafe==0.23 PyYAML==3.11 requests==2.7.0 rethinkdb==2.0.0.post1 stomp.py==4.0.16 toolz==0.7.2 websockets==2.4 Werkzeug==0.10.4
You should probably run this in a venv.
For now let's call it MIT licensed (but subject to change). No warranties expressed or implied of this thing working at all, much less being fit for purpose.