Best Flask open-source libraries and packages

SomaSOMA online school using flask

Robust e-learning app for students, parents, teachers, and school administrators
Updated 1 month ago

GitHub Open Issues GitHub Closed Issues GitHub Pull Request Open GitHub Pull Request Closed GitHub forks GitHub Stars

somaSOMA Online School

This is the third and final iteration of the somaSoma elearning app. The original application can be seen on this repo. A project started while at Moringa School with my friends Mark Mwaura and Alexona Kinuthia, I finally have a complete demo of the vision we had. This is a demo, though there are a handful other live versions I have built.

Overview

Built with love and from experience, this demo project summarizes the ideas that may be pivotal to any learning center, especially if conducted online. It covers the needs of four types of users:

  • Administrators:

    • You control who uses the platform, by registering them, managing their data, temporarily deactivating users or permanently deleting them and their data.
    • You get a bird's eye view of the entire business: what teachers are doing, what students are doing, what paretnts have to say
    • You manage lesson contents by uploading them to the platform
  • Teachers:

    • Tasked with guiding students through the lessons
    • They mark students' attendance, compounded to ratify each student's participation.
    • They assess their submitted lesson projects
    • They grade students projects
  • Parents:

    • They register their children once approved by the admin. Done so so that student information is accurate.
    • They see how well their child's attendance has been
    • They get to see how they perform in each chapter
  • Students:

    • They have access to lessons
    • They are required to complete the lessons in the order they appear
    • Access to subsequent lessons is dependant on the performance on the current chapter/lesson

Table of Contents

Features

  • Multi-user support
  • Newsletter subscription
  • Basic user authentication
  • Two-factor authentication
  • Sending of emails from the app

Technologies Used

  • Flask micro-framework
  • Python for programming
  • Sprinkles of JavaScript for front-end design
  • Twilio Verify API for two-factor authentication
  • Twilio SendGrid for email support
  • Gunicorn for live app deployment
  • Phonenumbers package for beautiful phone numbers
  • DatatableJS for interactive tables
  • Pytest and pytest-cov for testing
  • Psycopg2 for postgresql adaptability
  • Postgresql database or fallback to SQLite database
  • Flask-sqlalchemy ORM for database management
  • Flask-migrate for database migrations
  • Flask-moment for time formatting

Additional Details

Db Schema Design UI Design Deployment Contributors Tests
drawSQL Figma Render GitHub Tests

Application Details

Newsletter:

  • A user interested in receiving periodic updates about somaSOMA can sign up for the newsletter service.
  • Registration is limited to those who verify their email addresses only How newsletter works
  • The application automatically sends pre-prepared emails to them at set intervals Regular emails
  • Admin can email an individual newsletter subscriber to enhance one-on-one communication (optional) Admin talks with subscriber

Multi-user Support

The application features a superadmin, who cannot be deleted. This superadmin is the source of all activities in the app. For example:

  • All teachers are added by the superadmin
  • Other admins, with limited powers, are also added by the superadmin

To login as a superadmin, you can use this credentials:

Testing It Locally

  • Clone this repo:

    $ git clone git@github.com:GitauHarrison/somaSOMA-online-school-using-flask.git
  • Change directory into the cloned repo:

    $ cd somaSOMA-online-school-using-flask
  • Create and activate a virtual environment

    # Using virtualenvwrapper
    $ mkvirtualenv venv
    
    # Normal way
    $ python3 -m venv venv
    $ source venv/bin/activate
  • Install needed dependancies:

    (venv)$ pip3 install -r requirements.txt
  • Add and update environment variables in a .env file as seen in .env-template:

    (venv)$ cp .env-template .env
  • Start the flask server:

    (venv)$ flask run
  • Check the application in your favourite browser by pasting http://127.0.0.1:5000.

Areas of Improvement

  • Notifications of activities taking place within the app
  • Capture user gender during registration to help define how to send an email(Mr. or Ms.)
  • Other user's can request to delete their own accounts
  • Restricted access to subsequent chapters by students unless passmark is achieved
  • Marking of students attendance by teachers
  • Addition of student project quizzes to be assessed by teachers
  • Display of student performance in each chapter on students and parents' profile pages
  • Display of graphs to indicate student performance, student enrollment, account activities etc
  • Use of blueprints and factory function
  • Threading of the process of sending emails to make the app faster (you will notice the app slow down when sending emails)

NOTE: The above mentioned features are things I have implemented in other live and in-use applications

forthebadge forthebadge forthebadge forthebadge forthebadge

Tags sqlite