Repository navigation
Warn before leaving until report is saved - #250
Merged
Merged
Conversation
jserv
reviewed
Oct 7, 2026
jserv
reviewed
Oct 7, 2026
davidtsai15
force-pushed
the
fix/interview-lifecycle-warning
branch
from
October 7, 2026 07:42
a14db9c to
aef6158
Compare
ColtenOuO
requested changes
Oct 7, 2026
ColtenOuO
left a comment
Collaborator
There was a problem hiding this comment.
Please squash your commits.
Addressing review comments does not require a separate commit.
A timed interview can be lost to refresh or navigation before its report reaches Past attempts. LiveKit's page-leave hook also disconnects before the candidate can choose Stay, so wait for pagehide and keep the warning until a saved report can be reopened.
davidtsai15
force-pushed
the
fix/interview-lifecycle-warning
branch
from
October 8, 2026 07:08
aef6158 to
f9c83f2
Compare
Contributor
Author
|
Squashed the review-fix commit into the original commit. The PR now contains a single commit. |
Contributor
|
Thank @davidtsai15 for contributing! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Timed interviews currently allow accidental refreshes or navigation before the report is safely persisted.
This change keeps the native beforeunload guard active from the timed interview start until either the local or account report copy has been saved. LiveKit's automatic page-leave disconnect is disabled because it runs before the candidate chooses whether to stay, so room cleanup now waits for pagehide.
Tests cover the interview lifecycle, report persistence results, listener cleanup, and LiveKit page-leave behavior. The credential-free test gate passes locally, including all 936 browser tests with no failures or skips.
Closes #243
Summary by cubic
Warns before leaving a timed interview until a report copy is saved, so candidates can't lose an unsaved report by refreshing or navigating away.
pagehideso it doesn't run before the candidate chooses to stay.Closes #243.
Written for commit f9c83f2. Summary will update on new commits.