Skip to content

ets-berkeley-edu/damien

Folders and files

NameName
Last commit message
Last commit date
Nov 19, 2024
May 2, 2024
Feb 14, 2025
Mar 4, 2025
Feb 14, 2025
Feb 6, 2025
Nov 12, 2024
Mar 4, 2025
Nov 8, 2024
Feb 12, 2025
Feb 14, 2025
Nov 12, 2024
Nov 12, 2024
Dec 13, 2024
Aug 6, 2024
Aug 6, 2024
Feb 14, 2025
Dec 18, 2023
Aug 15, 2023
Feb 14, 2025
Nov 19, 2024
Feb 14, 2025
Dec 13, 2024
Nov 16, 2024
Dec 20, 2024
Dec 20, 2024
Feb 10, 2025
Aug 6, 2024
Dec 13, 2024
Nov 12, 2024
Nov 19, 2024
Nov 8, 2024
Nov 8, 2024
Nov 8, 2024
Nov 8, 2024
Nov 8, 2024

Repository files navigation

damien

OEC, reimagined.

Damien smiling

Installation

  • Install Python 3
  • Create your virtual environment (venv)
  • Install dependencies
pip3 install -r requirements.txt [--upgrade]

Front-end dependencies

nvm use
npm install

Create Postgres user and databases

createuser damien --no-createdb --no-superuser --no-createrole --pwprompt
createdb bugenhagen --owner=damien
createdb bugenhagen_test --owner=damien

# Load schema
export FLASK_APP=application.py
flask initdb

Create local configurations

If you plan to use any resources outside localhost, put your configurations in a separately encrypted area:

mkdir /Volumes/XYZ/damien_config
export DAMIEN_LOCAL_CONFIGS=/Volumes/XYZ/damien_config

Run tests, lint the code

We use Tox for continuous integration. Under the hood, you'll find PyTest, Flake8 and ESLint. Please install NPM dependencies (see above) before running tests.

# Run all tests and linters with Tox's parallel mode:
tox -p

# Pytest
tox -e test

# Run specific test(s)
tox -e test -- tests/test_models/test_foo.py
tox -e test -- tests/test_externals/

# Linters, à la carte
tox -e lint-py
tox -e lint-vue

# Auto-fix linting errors in Vue code
tox -e lint-vue-fix

# Lint specific file(s)
tox -e lint-py -- scripts/foo.py