Final Project

For this project you will use what we have learned so far this semester to create a web site using Flask and SQLite. This project is open-ended, but for full credit you must adhere to the requirements below. The project is due Friday, May 1.

It was originally going to be required that this project be a group project, but given the circumstances I will not require that everyone work in groups. However, some students have expressed interest in working in groups. So you may work individually, or in a self-selected group of 2 or 3 people.

Either way, please contact me by Monday, April 20 with your project idea, and list the members of your group if you are working in a group.

Requirements

Your Flask application must serve both HTML web pages and implement an API that uses JSON. The HTML pages will allow users to interact with the content in the database through the browser, and the API will allow applications to interact with the site.

You must also create a command-line utility that interacts with the site via the API.

More detailed requirements:

GitHub Repository

You must create a repository on GitHub in which you will work. Create the repository as a private repository under the class organization (https://github.com/cs232s20/). If you are working as a group, whoever creates the repository must add the other team members to the repository with write access.

It is always a good idea to create a .gitignore file in your repositories so that certain files will be ignored by Git, preventing you from accidentally adding files that should not be in the repository. For example, things will get annoying if someone accidentally pushes their PyCharm project folder. You also do not want to add SQLite databases, since those can be created from the code.

Here are the contents of a .gitignore file which will ignore the PyCharm project folder (.idea), compiled Python bytecode (*.pyc), the Python cached bytecode folder (__python__), SQLite databases (*.sqlite), and macOS folder attributes (.DS_Store):

.idea/
*.pyc
__pycache__
*.sqlite
.DS_Store

You can create your .gitignore before anybody forks the repository by clicking the “Create new file” link at the top of the repository.

If you are working in a group, all development must be done in personal forks of this repository. When you have code that should go into the main repository, create a pull request. The pull request must be merged by someone else in the team, and everyone must merge at least one pull request.

Once your repository is created, have one of the team members send me an email with the name of your repository and the members of your team.

Dividing Work and Simultaneous Development

If you are working in a group, work will need to be divided up among the team members. Some of the components will ultimately depend on other components, but that should not stop you from starting work on those components. For example, the HTML templates will ultimately need to use data from the Flask code, but you can write HTML files that are filled in with fake placeholder data at first, and then add the template stuff later when the Flask code is ready to use it. If you open up the HTML file on your computer it will open in your browser, so you can get things looking nice before it uses live data.

Similarly, the Flask code will ultimately need to use the database class, but you can still start working on the Flask code by manually returning fake data until the database code is written.

There will be a git-keeper assignment in which those who are working in a group will be required to submit a short write-up detailing which portions of the project they were responsible for.

Additional Features

Some features that we have not yet talked about that you might incorporate into your project:

You can find other features to use as well. If you are unsure if your idea fulfills this requirement, ask me.

Create a file named features.md in your repository where you write an explaination of the feature(s) that you chose and how you incorporated them into your project.

Ideas

If you are stuck trying to think of an idea for your project, here are some suggestions. Remember to keep it simple! Start by developing the simplest version of your idea that you can think of and add more features if you have time.