Skip to content

A simple Flask application to observe and manipulate results of key Formula 1 seasons.

Notifications You must be signed in to change notification settings

bryce-cc-dunn/influenceF1

Repository files navigation

InfluenceF1

A simple Flask application to observe and manipulate results of key Formula 1 seasons.

 

Deployed here: https://influencef1-app.herokuapp.com/

 

To Recreate:

Required Tech: Python, PostgreSQL

  • Download/Clone Git and navigate to file

    $ git clone https://github.com/bcdunn7/influenceF1
    $ cd path-to-influenceF1
    
  • Set up virtual environ and install dependencies

    $ python3 -m venv venv
    $ source venv/bin/activate
    (venv) $ pip3 install -r requirements.txt
    
  • Set up database

    $ sudo service postgresql start
    ...
    $ createdb influenceF1
    
  • Seed database

    $ python seed.py
    
  • Start server

    $ flask run
    
  • navigate to server/localhost!

 

Features:

  • The site displays results and standings data from the Ergast API for seasons which had extremely close standings, especially those where a dramatic or controversial event determined the result of the chamionship

The site has two main 'modes'

  • A 'Replay Mode' where users can navigate through a given season race by race to see where the crucial points were scored. Certain races also have information on dramatic or controversial moments that occured in a race. Image of InfluenceF1
  • Those dramatic moments are then taken over to the 'Simulator' mode where users are able to toggle the events 'on and off' to see how those moments changed the result of the season. The toggle arrangement for each season can be saved to the user account and will automatically load in the next time that user visits the simulator Image of InfluenceF1

 

API and Race Data:

  • https://ergast.com/mrd/
  • The data for the seasons, races, drivers is all found in the ergast API. No active calls are made, the data is all gathered during app deployment.
  • Information for 'changes' (the toggles in the simulator) was supplied by me.

 

Tech Used:

Front end

  • JavaScript (& jQuery)
  • Chart.JS
  • Boostrap

Back end

  • Python (w/ Flask)
  • PostgreSQL
  • SLQAlchemy
  • WTForms

About

A simple Flask application to observe and manipulate results of key Formula 1 seasons.

Resources

Stars

Watchers

Forks