Expert mode warning can be bypassed by going via expert mode debug screen#2158
Merged
sds100 merged 1 commit intoJun 9, 2026
Merged
Conversation
Move the debugging section (GetEvent button) inside the `warningState is Understood` conditional so it is only visible after the user acknowledges the expert mode warning, preventing the bypass via the debug screen. Also add a defensive guard in ExpertModeViewModel.onGetEventClick() that returns early if the warning has not been acknowledged.
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.
Closes #2154
Summary
ExpertModeScreen, outside thewarningState is Understoodguard that gates all other expert-mode content. This let a user navigate to the GetEvent debug screen without ever acknowledging the expert mode warning.if (warningState is ExpertModeWarningState.Understood)block so the button is only shown once the warning has been acknowledged.ExpertModeViewModel.onGetEventClick()that does nothing ifwarningStateis notUnderstood, preventing navigation even if the button were somehow invoked by another code path.Files changed
base/…/expertmode/ExpertModeScreen.ktUnderstoodbranchbase/…/expertmode/ExpertModeViewModel.ktonGetEventClickagainst unacknowledged warningCHANGELOG.mdKnown limitations / areas for human review
GetEventScreen/GetEventViewModel) has no awareness of the warning state; it relies entirely on being unreachable via the UI. This is fine for the current navigation graph, but worth noting if deep-link or intent-based navigation toNavDestination.GetEventis added in future.Generated by Claude Code