Files
JackMoodleHelper/README.md
T
2023-11-28 09:35:30 +01:00

4.0 KiB

Jack Tools

Python script to assist with import and export between JACK and Moodle. Also generates pdf files to print.

Listat - Usage

Use it as a command line script as follows:

usage: JackMoodleHelper.py [-h] -i INPUT [-j] [-p JACK_PREFIX] [-t TAN_PREFIX]
                           [-o OUTPUT] [-l LOGINS] [-r RESULTS_PREFIX]

optional arguments:
  -h, --help            show this help message and exit
  -i INPUT, --input INPUT
                        the csv file downloaded from moodle
  -j, --jack            output matriculation numbers for JACK?
  -p JACK_PREFIX, --jack_prefix JACK_PREFIX
                        prefix for output files for JACK, default: JACK_
  -t TAN_PREFIX, --tan_prefix TAN_PREFIX
                        prefix for tan files from JACK, default: examTans
  -o OUTPUT, --output OUTPUT
                        the output file. If you are preparing the testat, this
                        is the csv file containing the plan you want to upload
                        to moodle. Otherwise, this is a csv or excel table
                        containing the results of the testat.
  -l LOGINS, --logins LOGINS
                        file with login information
  -r RESULTS_PREFIX, --results_prefix RESULTS_PREFIX
                        prefix for files from JACK with the results of the
                        testat

Parameters

  • -h --help print the help page
  • -i INPUT, --input INPUT the input file from Moodle. You get this file by exporting the registration results. Make sure to select semicolon as the separator and include at least the following fields:
    • Datum
    • Startzeit
    • Endzeit
    • Ort
    • Zeitfenster
    • Vorname
    • Nachname
    • Teilnehmer-ID
  • -j, --jack if this flag is present, txt files with matriculation numbers will be generated, which can be uploaded to JACK. This is necessary so JACK knows who is registered.
  • -p JACK_PREFIX, --jack_prefix JACK_PREFIX optional prefix for the output files for JACK
  • -t TAN_PREFIX, --tan_prefix TAN_PREFIX prefix for the tan files from JACK. JACK generates TANs for each registered student. If the name is not examTans.csv, examTans-1.csv or similar, you can change this value.
  • -o OUTPUT, --output OUTPUT use this parameter to generate an output file. If you are preparing the testat, this is the csv file containing the plan you want to upload to moodle. Otherwise, if the results of the testat are found in the directory, this is a csv or excel table containing the results of the testat.
  • -l LOGINS, --logins LOGINS this is the file with login information for the pc pool. Get it from ZIM.
  • -r RESULTS_PREFIX, --results_prefix RESULTS_PREFIX optional prefix for the result files from JACK after the testat.

Output

This script generates multiple files and does multiple things. Before the testat: If -j, --jack is present, it generates txt files with matriculation numbers. If -o OUTPUT, --output OUTPUT is set, it also generates feedback for moodle. If the TAN file(s) and the specified login file are present, it also generates the following pdf files:

  • Serienbrief.pdf This is the pdf containing the login information and task description for every student.
  • Teilnehmerlisten.pdf This is a list of every registered student. Use it to check for attendance.
  • ExtraKennungen.pdf This file contains extra login information for students locking the pc by typing the wrong password.

After the testat: If excel files starting with RESULTS_PREFIX are present, the scripts merges the results from JACK with the names from INPUT and generates a csv or excel file containing the results. You can edit this file if necessary (e.g. someone uploaded a solution for someone else) and upload it to moodle afterwards.

TeX files

You need to modify Serienbrief.tex and \input the correct task. The task definitions are located in testat1.tex and similar files. If you want to adjust the tasks, edit the commands \taskdefinitionA and \taskdefinitionB as well as \mainclassA and \mainclassB.