Session log — Lesson completion gate (95% watch rule)
← All session logs
Session log — Lesson completion gate (95% watch rule)
Summary
- Hasmukh raised a concern that learners can mark a lesson complete on s2l.online without actually watching the video. He asked how to stop that.
- We agreed the right design is to lock the "Mark as Complete" button until 95% of the video has been watched, and then auto-complete the lesson the moment the threshold is reached.
- We also agreed that watch progress must be remembered across visits, so a learner who refreshes or comes back later resumes from where they stopped rather than starting over.
- I implemented the change end-to-end on the live s2l.online site (EP Courses plugin). Hasmukh will test tomorrow.
Decisions
- Completion threshold set to 95% (Hasmukh: "let's be greedy").
- Auto-complete on reaching the threshold, no click required.
- Resume from last position when the learner returns to a lesson, on any device.
- Skipping ahead in the video does not count toward the 95%, only time actually watched.
- Server enforces the rule too, so the gate cannot be bypassed by reloading the page or jumping to the end.
- Lessons without a video (content-only) keep the old behaviour — button works any time.
Changes made
- Added three watch-tracking fields to the lesson-progress store on the database, applied to the live site: last position, seconds actually watched, and video duration.
- Updated the EP Courses plugin so the lesson viewer now tracks playback for Vimeo, YouTube and MP4 videos, saves position roughly every ten seconds (and immediately on pause or page close), and auto-marks the lesson complete at 95%.
- Locked the "Mark as Complete" button by default for video lessons. It shows "Watch the video to complete" until the threshold is met.
- Added a server-side check so the completion request is rejected unless the stored watched-seconds reach 95% of the video duration.
- Backed up the previous plugin and frontend script with timestamped copies on the server before installing the new versions.
Follow-ups
- Hasmukh to test tomorrow: open a course as a learner, play a lesson to near the end, confirm it auto-completes; reload the lesson page and confirm it resumes from where the video was paused.
- If anything misbehaves, roll back to the previous plugin and frontend script (timestamped backups are sitting next to the live files).
- Existing in-progress learners will start their watch counter from zero on lessons they had not yet finished. Lessons already marked complete are untouched.