Finance App

📌 Overview

Last Commit Repo Size License

HTML Python Django Pytest Pydantic PostgreSQL

💰 SaaS FinanceApp

A modular, pipeline‑driven finance analytics SaaS built with Django & PostgreSQL

FinanceApp is a full‑stack personal finance analytics platform designed to ingest messy real‑world bank CSVs, clean and normalise the data, and present clear financial insights through dashboards, charts, and transaction management tools.

This is Version 1, focused on correctness, stability, modularity, and a clean user experience. The architecture is intentionally scalable, with a dedicated ingestion pipeline, logging system, and multi‑app layout.


🚀 Key Features

📸Screenshots

Analytical Dashboard Main dashboard main dashboard main dashboard Running balance dashboard Main login dashboard User profile dashboard CSV successfully cleaned dashboard Upload CSV dashboard Analytical Chart Dashboard


📹Demo Video

![Video of the dashboard]


⚙️ Tech Stack


🔐 Secure User Accounts (accounts app)


💸 Transaction Management (analytics app)


📊 Dashboard & Analytics


📥 CSV Upload & Ingestion Pipeline

This is the heart of SaaS FinanceApp. FinanceApp includes a two‑stage ingestion pipeline:

🧼 Stage 1 — CSVCleaner

A production‑grade cleaning engine that:

Handles messy CSV exports

Normalises dates into ISO format

Converts amounts into floats

Cleans categories (title‑case, typo fixes)


🏗️ Stage 2 — CSVImporter

A safe importer that:


🧱 Modular Architecture

The project is structured into multiple Django apps, each with a clear responsibility:

accounts/        → Authentication, profiles
apps/
  analytics/     → Transactions, dashboards, CSV ingestion
  logs/          → Logging system (analytics, pipeline, security)
  pipeline/      → Future pipeline engine (categorizer, cleaner, normalizer)
  uploads/       → Generic upload system (future expansion)
csv_data/        → Test CSVs
finance_app/     → Project-level config (settings, URLs, WSGI)
settings/        → Environment-specific settings (base/dev/prod)
templates/       → Global templates (login, register, base layout)


🗄️ Database

FinanceApp uses PostgreSQL in development and production.
Environment variables (from .env):
DB_NAME=finance_app
DB_USER=postgres
DB_PASSWORD=yourpassword
DB_HOST=localhost
DB_PORT=5432

🧩 Logging System (apps/logs/)

A dedicated logging subsystem with:
- analytics_logger.py
- pipeline_logger.py
- security_logger.py
- base.py

This allows:
- pipeline step logging
- error tracking
- security event logging
- analytics access logging

🧹 Example Cleaner Output

When uploading a messy CSV, the app might show:
Some rows were skipped during cleaning:
["Row 1: Invalid amount ' £2'",
 "Row 14: Invalid date format 'date'",
 "Row 15: Invalid amount '£2500'",
 "Row 35: Missing date"]
Valid rows are imported cleanly and appear in the dashboard.


🛠️ Installation

  1. ## Clone the repo
git clone https://github.com/reory/finance_app.git
cd finance_app
  1. ## Create a virtual environment
python -m venv venv
source venv/Scripts\activate # Windows
source venv\bin\activate  # Mac/Linux
  1. ## Install dependencies
pip install -r requirements.txt
  1. ## Configure environment variables Create a .env file in the project root:
DEBUG=True
SECRET_KEY=your-secret-key

DB_NAME=finance_app
DB_USER=postgres
DB_PASSWORD=yourpassword
DB_HOST=localhost
DB_PORT=5432
  1. Run migrations
python manage.py migrate
  1. Start the server
python manage.py runserver

🎯 Version 1 Goals Achieved

This is a complete, functional SaaS foundation.


🧪 Testing

This project includes a small, focused test suite that covers the critical paths of the backend:

These tests ensure that the ingestion pipeline is stable, predictable, and safe to extend

▶️ Run the Pytest suite:

pytest -q


🛣️ Roadmap


🏁 Final Notes

This app manages real‑world data, provides meaningful analytics, and is built with clean, maintainable Django architecture.