relate icon indicating copy to clipboard operation
relate copied to clipboard

Timing shown on list of grades?

Open KlavsKlavsen opened this issue 2 years ago • 4 comments

If I go look at my new quiz: https://relate.example.com/course/test-quiz1/grading/by-opportunity/1/?view_page_grades=1 It would be very nice to have the "time to finish" there also.. I need the time "per person" - as this affects the grade.. I did see you had some advanced auto thing for timing stuff.. But it would be very nice if the "time taken" per question (of in total quiz atleast) would be vieable somewhere? I can "sort of see it" - in analytics- but thats not user specific.

KlavsKlavsen avatar Mar 21 '22 12:03 KlavsKlavsen

"Time per question" is generally ill-defined IMO. Without additional client-side tracking, all we have is GET/POST timestamps for different pages. It may be possible to do something approximate that's good enough for analytics, but personally I wouldn't base any grades on it. There's too much that can go wrong, even if we had snoopy Javascript (which is easy to defeat): what if multiple tabs are open? what if multiple devices are looking at the same session?

As for time per session, that's well-defined and easy to show. I'd be happy to take a patch to show it.

inducer avatar Mar 22 '22 02:03 inducer

Time per session would be great.

KlavsKlavsen avatar Mar 22 '22 10:03 KlavsKlavsen

could you give some pointers as to where in the code to do this?

KlavsKlavsen avatar Mar 30 '22 08:03 KlavsKlavsen

To find the time per session, simply compute the difference between these two:

https://github.com/inducer/relate/blob/2186f96bfb1bb45d498c162cf8d824e9a84f6c4a/course/models.py#L880-L883

and insert the relevant HTML here:

https://github.com/inducer/relate/blob/2186f96bfb1bb45d498c162cf8d824e9a84f6c4a/course/templates/course/gradebook-by-opp.html#L181

(you have access to the flow session as grade_info.flow_session.

inducer avatar Mar 30 '22 22:03 inducer