Merge dev to main, nearing completion #6

Merged
WorldTeacher merged 33 commits from dev into main 2025-05-13 15:32:46 +01:00
Showing only changes of commit ac32b86b17 - Show all commits

View File

@@ -47,6 +47,7 @@ class Database:
if db_path is None:
self.db_path = self.database.path + self.database.name
self.db_path = self.db_path.replace("~", str(Path.home()))
logger.debug(self.db_path)
else:
self.db_path = db_path
self.checkDatabaseStatus()
@@ -54,7 +55,6 @@ class Database:
def checkDatabaseStatus(self):
path = self.database.path
path = path.replace("~", str(Path.home()))
# print(path)
path = os.path.abspath(path)
if not os.path.exists(path):
# create path
@@ -181,7 +181,7 @@ class Database:
# log_message = f"Querying database with query {query}"
if "INTO user" in query:
log_message = f"Querying database with query {query}"
logger.debug(log_message)
logger.debug(f"DB Query: {log_message}")
try:
cursor.execute(query, args)
rv = cursor.fetchall()
@@ -816,7 +816,7 @@ class Database:
)
else:
self.query_db(
"UPDATE semesterapparat SET verlängerung_bis=?, verlängerung_am=? WHERE appnr=?",
"UPDATE semesterapparat SET verlängerung_bis=?, verlängert_am=? WHERE appnr=?",
(newDate, today, app_id),
)