How nithinr8265/college_voting_system works
This is a Flask college-election platform. Its principal voter workflow runs from registration and approval through OTP login, face verification, ballot confirmation, vote storage, and scheduled result publication; administrators manage voters, candidates, election settings, and monitoring. app.py is the route and workflow orchestrator, with validation, face recognition, email, and Supabase operations delegated to helpers. The source excerpts support several helper calls and the webcam verification request; other feature relationships below rely on the README, not inspection of unsampled routes.
Main entry points: app.py Face verification · db.py Supabase operations · ballot.html Ballot and confirmation · mail_service.py OTP email delivery
Components 20
Voter workflow
- Flask routes
app.py - Registration and approval
app.py - OTP authentication
app.py - Face verification
app.py - Ballot and confirmation
templates/ballot.html - Vote confirmation UI
static/js/vote.js - Vote submission
app.py - Results and analytics
app.py - Webcam capture
static/js/webcam.js
Election administration
- Voter and candidate management
app.py - Election settings and scheduling
app.py - Election monitoring
templates/admin/monitor.html
Application services
- Face matching
face_service.py - OTP email delivery
mail_service.py - Server-side validation
validators.py - Gmail SMTP
Data and presentation
- Supabase operations
db.py - Supabase PostgreSQL
Other components
- Student voter
- Administrator
Connections 24
- Student voter → Registration and approval: registers
README.md - Registration and approval → OTP authentication: continues to
README.md - OTP authentication → OTP email delivery: sends OTP
app.py - OTP email delivery → Gmail SMTP: sends email
mail_service.py - OTP authentication → Face verification: verifies next
README.md - Student voter → Webcam capture: captures image
static/js/webcam.js - Webcam capture → Face verification: posts image
static/js/webcam.js - Face verification → Face matching: checks face
app.py - Face verification → Flask routes: uses routes
app.py - Face verification → Ballot and confirmation: continues to
README.md - Student voter → Ballot and confirmation: selects candidates
README.md - Ballot and confirmation → Vote confirmation UI: uses confirmation
static/js/vote.js - Vote confirmation UI → Vote submission: submits ballot
README.md - Vote submission → Results and analytics: feeds results
README.md - Flask routes → Supabase operations: reads and writes
app.py - Flask routes → Server-side validation: validates forms
app.py - Supabase operations → Supabase PostgreSQL: queries and updates
db.py - Administrator → Voter and candidate management: manages records
README.md - Administrator → Election settings and scheduling: configures election
README.md - Administrator → Election monitoring: monitors election
README.md - Voter and candidate management → Supabase operations: updates records
app.py - Election settings and scheduling → Supabase operations: stores settings
app.py - Results and analytics → Supabase operations: reads vote data
README.md - Flask routes → OTP email delivery: uses service
app.py