josh-abad / proctor-vue-web

The web application for Proctor Vue.
MIT License
1 stars 1 forks source link

Wait for webcam and face detection to load every time #3

Closed josh-abad closed 3 years ago

josh-abad commented 3 years ago

Currently, before taking an exam, a setup modal appears to indicate that the user's webcam (as well as the face detection models) is being loaded. Until both operations are complete, the user cannot proceed to the exam. This helps ensure that there is no lag once the actual attempt has started, and the webcam starts making detections immediately.

However if the exam is interrupted (e.g., the user closes the tab or changes URL), the way for the user to return to the attempt is by going directly to the attempt URL (i.e., /courses/<course>/<exam>/attempt/<attempt_id>). When this happens, the in-progress attempt is fetched immediately, while the webcam and face detection models are loaded upon mounting.

An ideal scenario would be if the aforementioned modal were to always appear. In the case of continuing an in-progress attempt, the attempt would still be fetched, however, the user can neither interact nor continue with the exam until the prior setup has completed.