backend tooling for modulplaner-frontend
|
|
пре 3 недеља | |
|---|---|---|
| config | пре 2 месеци | |
| parse | пре 2 месеци | |
| .gitignore | пре 2 месеци | |
| LICENSE | пре 2 месеци | |
| README.md | пре 3 недеља | |
| extract_lecturer_shorthands_pdf.py | пре 2 месеци | |
| generate_classes_json.py | пре 2 месеци | |
| requirements.txt | пре 2 месеци | |
| rip_modulplaner_frontend_data.py | пре 2 месеци |
Provides backend tooling for modulplaner-frontend (archived at #1 #2).
Because the original repo only contains frontend code and data updates were slow and intransparent, I created this repo (archived at #1 #2) as a solution.
Currently the core data generation is pretty solid. This projects was built to support API version 1.0.0 of modulplaner-openapi-spec (archived at #1 #2). Currently I am part of the team at FHNW that works on an implementation of the API Version 2.x.x. Instead of parsing pdf files, the goal is the get the data directly from evento, the campus managment software used at FHNW. The associated repositories for this rewrite are currently only visible to circa 10 members of a GitLab group on the FHNW GitLab instace.
For this specific repo, the backlog is the following:
You need to install
requirements.txtFor some simple commands mentioned in this documentation, It is also recommended to install and setup
This project uses specific domain terms that map to the data sources and the generated JSON structure:
klassen.pdf) containing the weekly schedule.This section is split into the different script provided by this repository.
Execute the following to parse a class timetable PDF into the classes.json file needed by the frontend.
./generate_classes_json.py -i klassen.pdf -o classes.json
For more information, show the cli arguments via ./generate_classes_json.py -h.
Since the PDF extraction takes a significant amount of time, you can split the process into two stages:
./generate_classes_json.py --save-intermediate data.pkl./generate_classes_json.py --load-intermediate data.pkl --output classes.jsonUse this script to parse a lecturer shortname PDF into the lecturers.json file needed by the frontend. Note that if you don't merge the script output with your previous lecuturer.json file, the view of previous semesters may break. You can easily do that using jq:
jq -s 'add | unique' previous_lecturers.json script_output.json > merged.json
For more information, show the cli arguments via ./extract_lecturer_shorthands_pdf.py -h.
Rips all data files from a live modulplaner-frontend server.
For more information, show the cli arguments via ./rip_modulplaner_frontend_data.py -h.
DSMixe entry in the room line (third line) of class pdf cells, or the line is missing altogetheralle which is degree program agnosticKontext BWL, Kontext Kommunikation, Kontext GSW have mixed classes, which arises the need the have a table to differentiate the modules based on their shorthandsteaching_type's defined that may not ever be found in class pdf'spart_of_other_classes needs to be further investigatedmodulplaner-backend is a free (as in “free speech” and also as in “free beer”) Software. It is distributed under the GNU Affero General Public License v3 (or any later version) - see the accompanying LICENSE file for more details.