Skip to content

techistem/student-data

Repository files navigation

Student Data

Overview

This Student Data program is useful for teachers or administrators to manage student records easily. They can add new student data, view existing data, and have it all organized neatly in a Google Sheet.

It is built using Python and runs through the Code institute mock terminal on Heroku.

Welcome to Student Data

Responsive design

Planing Stage

User Stories:

As a user, I want to be able to:

  1. As an administrator, I want to add a new student's data so that their information is stored in the system.
  2. As a teacher, I want to view a list of all student data so that I can have an overview of all students in the system.
  3. As a teacher, I want to calculate a student's average grade so that I can assess their performance in the course.
  4. As a teacher, I want to filter students by lesson so that I can view the performance of students in a specific lesson.
  5. As an administrator, I want to update a student's information so that the data in the system remains accurate.
  6. As an administrator, I want to delete a student's data so that their information is removed from the system.

Site Aims:

The site aims to:

  1. Users can input student information, including name, surname, lesson, and exam scores.
  2. Users can list and display student data from Google Sheets worksheet.
  3. Describes how the program saves the entered student data to the worksheet.
  4. Users are encouraged to provide feedback or report issues for program improvement.

Path to Achieve:

To achieve the above, the site will:

  1. When the user enters information that is not valid, a message should appear on the screen explaining what to do and how to continue.
  2. Create an option so that the user can check the information they enter.
  3. Provide the user with the opportunity to easily view and delete the information they enter.

Student Data Flow Chart:

I created the following flow chart using [lucid charts] (https://www.lucidchart.com/) to outline the necessary steps for programming the student data recording system.

Student Data Logic Flowchart

Features

This Python program allows users to manage and record student data using Google Sheets. The features included in this programme are listed in the main menu and they can be seen below:

Main Menu

Add student data:

When the user selects the add new student option, the program will be asked to enter student information.

Add Student Data

List Student Data

  • The program can list and display student data from the Google Sheets worksheet.
  • Accordingly, the student's name, surname, course, and average exam scores are reflected on the screen.
  • The system automatically calculates the student's status (Pass/Fail) based on their exam scores.

List Student Data

Google Sheets Integration

Utilizes Google Sheets API for data storage and retrieval.

Validated Input

Input validation ensures correct data entry, prompting users when invalid input is provided.

Validated Input

Flexible Lesson Selection

Users can select from a list of predefined lessons: English, Science, Math, and History.

Flexible Lesson Selection

Feedback and Error Handling

The program provides feedback on successful data entry and error messages for invalid inputs.

Feedback and Error Handling

Exit

Users can exit the program at any time.

Exit

Future-Enhancements

Here are some potential improvements and features that I could add to enhance the functionality of the program:

  • User Authentication: I can implement user authentication to ensure only authorized users can access and modify student data.

  • Search and Filter: I can add functionality to search for specific students or filter students by criteria such as lesson, score, or status.

  • Update and Delete: I can include options to update and delete student records directly from the program interface.

  • Data Visualization: I can integrate data visualization tools to create charts and graphs for better data analysis and insights.

  • Email Notifications: I can send automated email notifications to teachers or administrators for important events, such as new student entries or low scores.

  • CSV Import/Export: I can allow users to import student data from CSV files and export data to CSV for easy sharing and backup.

  • Mobile App: I can develop a mobile app version of the program for convenient access on smartphones and tablets.

These enhancements could make the program more versatile, user-friendly, and efficient for managing student data.

Technologies Used

I have used several technologies that have enabled this design to work:

-Python

  • The entirety of the code in this application is composed using Python as the fundamental programming language, ensuring its complete functionality.
    • In addition to core Python I have used the following Python modules:
      • Gspread
        • Used to access my google sheets document throughout the application, to access and edit data.
      • Google Auth
        • Used to provide access to the application to interact with my google sheet.
  • GitHub
    • Used to store code for the project after being pushed.
  • Git
    • Used for version control by utilising the Gitpod terminal to commit to Git and Push to GitHub.
  • Gitpod
    • Used as the development environment.
  • Heroku
    • Used to deploy my application.
  • Lucid
    • Used to create the flowchart for the project.
  • Grammarly
    • Used to fix the grammar errors across the project.
  • Google Sheets
    • Used to store the 'Contacts' data used for the application.
  • Pep8
    • Used to test my code for any issues or errors.

Testing Phase

I have written my testing in a different file for both during-development and post-development called TESTING.md .

Libraries

For this project to function, I imported the following libraries:

  • gspread: Used for accessing Google Sheets API.
  • google-auth: Provides authentication credentials for accessing Google APIs.

Deployment to Heroku

The project was deployed to Heroku

  1. Log in to Heroku or create an account if required.
  2. Click on the dashboard from the hamburger menu on the top right to be navigated to the apps page.
  3. Click the new button on the top right of the page.
  4. Select the "create new app" option.
  5. Enter the app name. I named mine student-data (this has to be unique).
  6. Once Heroku accepts the app name select your region.
  7. Click the purple Create app button when you are ready to proceed.
  8. This will bring you to the project Deploy tab. From here, navigate to the settings tab and scroll down to the Config Vars section.
  9. Click the button labeled Reveal_Config Vars, Enter the key as Port, the Value as 8000 and Click the add button.
  10. Scroll down to the buildpacks section of the settings page, click the button labeled Add buildpack, select Python, and click Save Changes.
  11. Repeat step 10 but this time add node.js instead of python.
    • Remember to keep the buildpacks in the correct order, Python first and Node second.
  12. Scroll back to the top of the settings page, and navigate to the Deploy tab.
  13. From the deploy tab select Github as the deployment method.
  14. Confirm you want to connect to GitHub.
  15. Search for the repository name and click the connect button next to the intended repository.
  16. From the bottom of the deploy page select your preferred deployment type by following one of the steps below:
    • Clicking either "Enable Automatic Deploys" for automatic deployment when you push updates to GitHub.
    • Select the correct branch for deployment from the drop-down menu and click the "Deploy Branch" button for manual deployment.

Heroku Student Data

Using Github & Gitpod

To deploy my command-line interface application, I had to use the Code Institute Python Essentials Template, as this enables the application to be properly viewed on Heroku using a mock terminal.

  • Click the Use This Template button.
  • Add a repository name and brief description.
  • Click the Create Repository from Template to create your repository.
  • To create a Gitpod workspace you then need to click Gitpod, this can take a few minutes.
  • When you want to work on the project it is best to open the workspace from Gitpod (rather than Github) as this will open your previous workspace rather than creating a new one. You should pin the workspace so that it isn't deleted.
  • Committing your work should be done often and should have clear/explanatory messages, use the following commands to make your commits:
    • git add .: adds all modified files to a staging area
    • git commit -m "A message explaining your commit": commits all changes to a local repository.
    • git push: pushes all your committed changes to your Github repository.

Forking the GitHub Repository

If you want to make changes to your repository without affecting it, you can make a copy of it by 'Forking' it. This ensures your original repository remains unchanged.

  1. Find the relevant GitHub repository
  2. In the top right corner of the page, click the Fork button (under your account)
  3. Your repository has now been 'Forked' and you have a copy to work on

Cloning the GitHub Repository

Cloning your repository will allow you to download a local version of the repository to be worked on. Cloning can also be a great way to backup your work.

  1. Find the relevant GitHub repository
  2. Press the arrow on the Code button
  3. Copy the link that is shown in the drop-down
  4. Now open Gitpod & select the directory location where you would like the clone created
  5. In the terminal type 'git clone' & then paste the link you copied in GitHub
  6. Press enter and your local clone will be created.

Credits

Acknowledgements

I would like to thank my course mentor Tim Nelson, for his support and guidance throughout the course of the project and my peer Ilyascan Olgun for their support & feedback.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published