Check out full instructions HERE
Previous project groups have utilized CSC cloud services for running SmartCanvas, so that the laptop attached to a large display needs to only run a web browser that is then used for accessing SmartCanvas running in the cloud.
CSC deployment instructions can be found from documentation HERE specifically.
- Python 3.12.*
- Poetry (2.1 or higher recommended)
- Node (24 tested)
- Node 24 in frontend image has not been tested in a long running test.
Check for installation
python3 --version
python --version
Depending on your OS of choice load and install python from https://www.python.org/downloads/ or via package manager. (Many Linux distros already have python)
NOTE
Up to version 3.12.11 is currently supported. Using newer will mostly likely not work with current dependencies.
Pyenv is a good option for multiple python versions https://github.com/pyenv/pyenv.
Follow instructions here -> https://pipx.pypa.io/stable/installation/
After python and pipx are installed insall poetru with pipx
pipx install poetry
After installing reload you shell and poetry should work.
The backend environment is managed with Poetry, a Python package and project manager. To install the project and its prerequisites simply use
poetry installFor any following commands it is assumed that the created Python virtual environment has been activated in the terminal. Development tools like Visual Studio Code handle venv activation automatically, but in case you need to invoke commands in a fresh terminal you can use poetry env activate to get the activation command.
Move to poetrys virtual env before running the app. https://python-poetry.org/docs/managing-environments/#bash-csh-zsh
eval $(poetry env activate)
To run the web backend, you can use.
flask --app web runFor unit testing, you can simply use the pytest command to run the tests defined in /tests/.
pytestCollect coverage from project
pytest --cov=smart_canvas --cov=web --cov-report=html
The results in /htmlcov/index.html. Open with the following command or open via filesystem.
xdg-open htmlcov/index.html # Linux
open htmlcov/index.html # macOS
start htmlcov/index.html # Windows
The frontend is managed with npm and can be installed in the smartcanvas-frontend directory with
npm installand started with
npm run dev
Before deploying, the frontend can be built into a static bundle in the web/static folder with
npm run build
The project comes with a VSCode launch.json to simplify debugging the backend and frontend separately. When contributing, strongly consider utilizing tooling like VSCode to simplify the environment management, and to run strict type checks on your code.
See the CONTRIBUTING.md guide.
- @Vilatsut
- @loppastoffa
- @hpeteri
- @juusosar
- @topoto123
- @vtiinanen
- @jarkkokotaniemi
- @jvuorine
- @jruntti20
- @Mikroudz
- @Redha-Aouadja
- @hengzhang-pro
- @antilaanssi
- @MeaNoCulpa
- @0LTSU0
- @jouniwho
- @morriskrr
- @pklemettila
- @JokelaR
- @Petercode12
- @naanatin
- @juvalta
- @sanpitka
- @MarkoMikaelT
- @pottumuusi
- @safi50
- @chgasche
- @TalhaPasha-sudo