-
Notifications
You must be signed in to change notification settings - Fork 2
/
main.py
33 lines (27 loc) · 837 Bytes
/
main.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
# getpass does not show anything while password is entered but pwinput shows ***
# pwinput looks better but it is not in standard library
# ---IMPORTS---
try:
from src import logger
from src.login import login
from src.kampus import get_course_list, filter_courses
from src.task_handler import start_tasks
from src.db_handler import DB
from src import globals
except ModuleNotFoundError:
print(
"HATA! Kütphaneler yüklenemedi. 'src' klasörü silinmiş veya yeri değişmiş olabilir."
)
exit()
# ---MAIN---
@logger.speed_measure("Program", False)
def main():
DB.init()
courses = get_course_list()
courses = filter_courses(courses)
start_tasks(courses)
DB.write_records()
# ---Program driving code---
if __name__ == "__main__":
globals.init_globals()
main()