How avipaut/kursach-master works
Project type and purpose
• This is a monolithic full-stack web application built with the Flask framework in Python.
• Purpose: a project management dashboard with Kanban boards, chat, calendar (with Zoom integrations), document management, KPI construction, reporting, notifications and user management.
File structure
• app.py: the Flask application factory / entry point.
• config/: application configuration (e.g., Zoom API credentials).
• instance/: holds the SQLite database (main.db), environment-specific files.
• migrations/: Alembic scripts for database schema evolution.
• routes/: Flask Blueprints, each file implements one area of functionality (auth, kanban, chat, documents, kpi, reports, etc).
• templates/: Jinja2 HTML templates, organized by feature.
• static/: CSS, JavaScript, images, audio, and file uploads.
• exports/: pre-generated export files (PDF, JSON) to illustrate reporting output.
• uploaded_documents/: local storage for user-uploaded files, with .trash subfolders.
• requirements.txt: Python dependencies (Flask, SQLAlchemy, Alembic, Zoom SDK, etc).
• .github/workflows/python-publish.yml: CI/CD for packaging or publishing.
Insights from README
• Minimal description (“our first full project”) implies that all features are in one deployable Flask app.
• No extra microservices—everything runs as one codebase, communicates with one database, and stores files locally.
a. Main components
• Client (Web browser/mobile)
• Web Server / Load Balancer (e.g., Nginx or Gunicorn in front of Flask)
• Flask Application
– Blueprints for auth, kanban, chat, calendar, documents, KPI, reports, notifications
– SQLAlchemy ORM layer
– Zoom integration module (config_zoom.py, zoom_service route)
– Alembic migrations
• Relational Database (SQLite in this setup; could be PostgreSQL in production)
• File Storage (local filesystem under uploaded_documents/)
• Static Asset Server (serves CSS/JS/images/audio under static/)
• External Service: Zoom API
b. Relationships and data flows
1. User’s browser → HTTP(S) → Web Server
2. Web Server forwards requests to Flask app
3. Flask app routes to appropriate Blueprint
4. Blueprint handlers:
– Query/update database via SQLAlchemy
– Read/write files in uploaded_documents/
– Call Zoom REST API for meeting/calendar actions
– Trigger export routines (PDF, JSON) writing to exports/
5. Database responds with data; Flask renders templates or returns JSON
6. Browser receives HTML/JS/CSS and opens real-time connections for chat (e.g., long polling or websockets)
7. Notifications subsystem pushes events to browser (via server-sent events or polling)
c. Architectural patterns and principles
• Monolithic MVC-like structure:
• Models (routes/models.py, SQLAlchemy classes)
• Views (templates/)
• Controllers (routes/*.py blueprints)
• Blueprint modularization: each area of functionality isolated into its own module
• Configuration-per-environment using config/ and instance/
• Database versioning with Alembic (migrations/versions)
• Separation of static assets and dynamic routes
d. Key technologies
• Python 3 + Flask
• SQLAlchemy ORM + SQLite (for local) / PostgreSQL (for production)
• Alembic for migrations
• Jinja2 templating
• Zoom SDK / REST API integration
• Frontend: Vanilla JS + CSS modules under static/js and static/css
• PDF generation libraries (implied by exports/pdf_…)
Capturing essential details
• Alembic migration tool’s interaction with the database as a side-flow (development/deployment only).
• Configuration lookup: config/config_zoom.py + instance/ folder for secrets.
• “Exports” component for reporting outputs.
• File upload/download paths from browser to uploaded_documents/ directory.