Quantified Self-App is a web application that tracks life parameters. Logs values into each tracker and plots trendlines on the basis of the logs. It sends monthly timed reports via emails to the user.
-
Clone the repo
git clone https://github.com/priyanka-maz/Quantified-Self-Application
-
Install MailHog as per your system's requirements.
-
After cloning or downloading the codebase src/ dir to /path/to/src
python3 -m venv /path/to/src cd /path/to/src python3 -m pip install -r requirements.txt # Skip below command if using in a development env export ENV=production ./app.sh
-
SENDER_ADDRESS
in src/application/config.py has been set todummy@gmail.com
Replace the value with the sender address you want the users of this app to receive their reports from.
- User Registration and Session Cookie based authentication for login.
- Passwords are stored using Bcrypt Hashing Algorithm.
- User Accounts may be deleted.
- Users may logout.
- Users may add Trackers of the following types:
- Multiple Choice (user choice)
- Numerical
- Boolean
- Time Duration
- Logs may be added for each tracker.
- CRUD functionality implemented for both trackers and logs.
- Matplotlib is used to render trendlines of logs under a tracker.
- Caching for root page is done.
- Export and Import for data in csv format is enabled.
- Monthly Reports are emailed via a fake SMTP server to the user email.
- WeasyPrint is used for email generation.
- Triggered and scheduled celery endpoints exist.
- Progressive Web App of this may be locally installed.
- All pages are dynamically rendered with Vue.
.
├── api.yaml
├── LICENSE
├── README.md
├── screenshots
└── src
├── application........... Contains the api handler, configuration, controllers,
│ │ database, model, email handler, jobs for celery
│ ├── api.py
│ ├── config.py
│ ├── controllers.py
│ ├── database.py
│ ├── email.py
│ ├── __init__.py
│ ├── jobs.............. Files for scheduling tasks & configuring celery Task handler
│ │ ├── __init__.py
│ │ ├── __pycache__
│ │ ├── tasks.py
│ │ └── workers.py
│ ├── models.py
│ ├── plot.py........... Uses matplotlib to plot trendlines of tracker logs
│ ├── __pycache__
│ └── validation.py..... For handling HTTP exceptions
├── app.sh................ Runs the celery schedule, MailHog and the entire application
├── db_directory.......... Contains the database in sqlite3 version
├── main.py............... Entry point into the application
├── __pycache__
├── requirements.txt...... Contains the requirements
├── static................ Contains Vue js files for SPA, service-worker files for
│ │ PWA and stores images of trendlines
│ ├── icon.png
│ ├── images
│ ├── js
│ │ └── app.js
│ ├── manifest.json
│ └── service-worker.js
└── templates............. HTML templates for the Report and Navigation Bar on all pages
├── index.html
└── report.html