Skip to content

jday1/euros.python

Repository files navigation

Euros 2024 Fantasy

Code style: black Checked with mypy

This python application is for a Euros 2024 fantasy game where players accumulate points based on match results. The application is created using Dash and Plotly for the frontend with most of the computation being handled by pandas. Rather than a database, the app uses files for storing the fixtures and the users' points. This is because, when we used this app for the game during the Euros, there were very few API calls from the website. If one were to scale this app for many more users, this approach would need to be revisited.
On the frontend, the app is designed to be responsive and mobile-friendly. Plotly does not create figures which are designed to be mobile-friendly. To overcome this, different figures are used for different screensizes through a combination of Plotly and Dash CSS.

See the Rules below for a preview of the landing page of the app, or use the documentation below to get going!

Rules

alt text

Setup

  1. Requires a Python 3.12 environment (virtual environment recommended).

  2. Install all the dependencies

pip install -e ".[lint, test]"
  1. Run locally (this will make the app available at 0.0.0.0:3000)
python euros/main.py -f euros/tests/resources/test_config.yaml
  1. Log in using a username/password combination from
euros/tests/resources/example_base_path/example_group/users.json
  1. Extra - run using gunicorn
gunicorn 'euros.main:server(filepath="euros/tests/resources/test_config.yaml")'

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published