Skip to content

Students who have not logged in cannot have their attendances taken #389

@smartspot2

Description

@smartspot2

If a user was added to a section but have not logged into scheduler, mentors cannot change the attendance for the student, because of a validation error when saving the object in the database through the serializer.

In particular, the following Django log is printed:

<Attendance:Failure> Could not record attendance for User <pk=24;email=demo_user@berkeley.edu>, errors: {'student_name': [ErrorDetail(string='This field may not be blank.', code='blank')]}

Generally, this hasn't been an issue in the past, since student enroll themselves in sections, which requires them to have logged into scheduler. However, if a coordinator manually enrolls a student without having them login first, this creates a new user and student object without any associated name, causing this error when attempting to modify attendances.

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingsev3High severity - Production system impaired

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions