An attempt at a web-based redesign of Calchart, which integrates the desktop Calchart application, the viewer, and the server.
Goals:
- Create a cloud file system that stores shows created by Stunt and can be viewed by bandsmen
- Create an intuitive UI for charting shows
- Integrate Calchart Viewer
- Integrate the individual continuity generator
For a visualization of the design, see the Figma.
This project is different from other Comp-Comm projects in that developers will be running the Django server and building the static files locally instead of in a virtual machine (with Vagrant). Each of the steps below will list out the requirements needed to install on a developer's computer.
Our Django code is using Python 3.6, which can be downloaded either with Conda or from source.
Conda provides a lot of cool features (we only use a fraction of these features), such as supporting user-wide virtual environments, allowing for different Python versions in each environment, and more.
Recommended install (Conda):
- Install Conda here (for Python 3.6)
- Create a virtual environment:
conda create --name calchart
- Activate the environment (needs to be run in every shell):
source activate calchart
- See documentation for more details.
Install from source:
- Install Python 3.6 here
- Create a virtual environment:
python3 -m venv venv
- Activate the environment (needs to be run in every shell):
source venv/bin/activate
Most of the code in this project is written using Vue, a Javascript framework for building client-side applications. In order to run and build this code, developers need to install Node 9 and Yarn. For MacOS developers who use Homebrew, brew install yarn
should install both dependencies.
After installing Node, run yarn install
to install the dependencies.
After finishing all the above installation steps, do the following:
- Install Django requirements (inside the virtual environment):
pip install -r requirements/dev.txt
- Set up Django database:
python calchart/manage.py migrate
- Create a super user:
python calchart/manage.py shell < scripts/createsuperuser.py
First, get the Django server running: python calchart/manage.py runserver
. Then, in another tab, run yarn start
.
You should now be able to connect to http://localhost:5000
.
This project contains four testing facilities:
- Linting (
yarn lint
andflake8 calchart/
): Checks code style - Server-side tests (
python manage.py test
): These are Django tests that test functionality within the back-end; e.g. testing Django models - Unit tests (
yarn test
): These are Javascript tests (using the Mocha library) that test functionality within the front-end; e.g. testing Component methods - End-to-end tests (
yarn cypress
): These are tests that test functionality between the back-end and front-end; e.g. testingsendAction
calls.
More detailed information and examples of these tests can be found in docs/Testing.md
.