Skip to content
This repository has been archived by the owner on Jan 22, 2025. It is now read-only.

Seeder did not make a CourseStudent relation with the passed uit #368

Merged
merged 2 commits into from
May 18, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions backend/seeder/seeder.py
Original file line number Diff line number Diff line change
Expand Up @@ -177,6 +177,8 @@ def into_the_db(my_uid):
course_id = insert_course_into_db_get_id(session, teacher_uid)
subscribed_students = populate_course_students(
session, course_id, students)
session.add(CourseStudent(course_id=course_id, uid=my_uid))
session.commit()
subscribed_students.append(my_uid) # my_uid is also a student
populate_course_projects(
session, course_id, subscribed_students, teacher_uid)
Expand Down