Install the required OS dependencies. The procedure varies according to the package manager in use.
python3
python3-venv
python3-dev
libmariadb-dev
Create a Python virtual environment and activate it:
python3 -m venv .venv
source .venv/bin/activate
Install the required Python dependencies:
python3 -m pip install -r requirements.txt
To add the students to an exam:
python add_students.py db-config-file exam-config-file students.csv
To download the solutions submitted by students for an exam:
python download_exams.py db-config-file exam-config-file students.csv
db-config-file
: path of the JSON file containing the parameters to be used for the connection to the databaseuser
: name of the user with write access to the DOMJudge databasepassword
: password of the above userhost
: where the database is hostedport
: connection portdatabase
: name of the DOMJudge database
{
"user": "domjudge",
"password": "password",
"host": "localhost",
"port": 3306,
"database": "domjudge"
}
exam-config-file
: path of the JSON file containing the information about the examshortname
: the shortname that has been specified while creating the contest through the DOMJudge web interface
{
"shortname": "exam",
"problem_shortnames": ["Shortname 1", "Shortname 2"],
"team_category": "Team category name"
}
students.csv
: path of the CSV file containing the students registered to the exam