A previous `git pull --rebase origin main` dropped 177 local commits,
losing 3400+ files across admin-v2, backend, studio-v2, website,
klausur-service, and many other services. The partial restore attempt
(660295e2) only recovered some files.
This commit restores all missing files from pre-rebase ref 98933f5e
while preserving post-rebase additions (night-scheduler, night-mode UI,
NightModeWidget dashboard integration).
Restored features include:
- AI Module Sidebar (FAB), OCR Labeling, OCR Compare
- GPU Dashboard, RAG Pipeline, Magic Help
- Klausur-Korrektur (8 files), Abitur-Archiv (5+ files)
- Companion, Zeugnisse-Crawler, Screen Flow
- Full backend, studio-v2, website, klausur-service
- All compliance SDKs, agent-core, voice-service
- CI/CD configs, documentation, scripts
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
62 lines
1.6 KiB
Python
62 lines
1.6 KiB
Python
"""
|
|
Klausur-Service In-Memory Storage
|
|
|
|
Centralized storage for all in-memory data.
|
|
Note: In production, this should be replaced with a database.
|
|
"""
|
|
|
|
from typing import Dict, List
|
|
|
|
from models.exam import Klausur, StudentKlausur
|
|
from models.grading import AuditLogEntry
|
|
from models.eh import (
|
|
Erwartungshorizont,
|
|
EHRightsConfirmation,
|
|
EHAuditLogEntry,
|
|
EHKeyShare,
|
|
EHKlausurLink,
|
|
EHShareInvitation,
|
|
)
|
|
|
|
# =============================================
|
|
# KLAUSUR STORAGE
|
|
# =============================================
|
|
|
|
# Klausur storage: klausur_id -> Klausur
|
|
klausuren_db: Dict[str, Klausur] = {}
|
|
|
|
# Student work storage: student_id -> StudentKlausur
|
|
students_db: Dict[str, StudentKlausur] = {}
|
|
|
|
# Examiner assignments: student_id -> examiner info
|
|
examiner_db: Dict[str, Dict] = {}
|
|
|
|
# =============================================
|
|
# AUDIT LOG STORAGE
|
|
# =============================================
|
|
|
|
# General audit log
|
|
audit_log_db: List[AuditLogEntry] = []
|
|
|
|
# =============================================
|
|
# BYOEH STORAGE
|
|
# =============================================
|
|
|
|
# Erwartungshorizont storage: eh_id -> Erwartungshorizont
|
|
eh_db: Dict[str, Erwartungshorizont] = {}
|
|
|
|
# Rights confirmations: confirmation_id -> EHRightsConfirmation
|
|
eh_rights_db: Dict[str, EHRightsConfirmation] = {}
|
|
|
|
# EH audit log
|
|
eh_audit_db: List[EHAuditLogEntry] = []
|
|
|
|
# Key shares: eh_id -> list of EHKeyShare
|
|
eh_key_shares_db: Dict[str, List[EHKeyShare]] = {}
|
|
|
|
# EH-Klausur links: klausur_id -> list of EHKlausurLink
|
|
eh_klausur_links_db: Dict[str, List[EHKlausurLink]] = {}
|
|
|
|
# Share invitations: invitation_id -> EHShareInvitation
|
|
eh_invitations_db: Dict[str, EHShareInvitation] = {}
|