Repository navigation
Conversation
One-shot settle on Prompt/RejectPrompt and sendReply so Enter/click cannot POST the same requestID repeatedly (XiaomiMiMo#2565). Permission.reply returns false for an unknown requestID and the TUI dismisses the dialog on false/error so an ask orphaned by turn teardown cannot wedge input forever (XiaomiMiMo#2502).
Match the file's existing signal style instead of mutable let flags, and indent the dismissed Show wrapper. No behavior change.
Author
|
@yanyihan-xiaomi @lilei-xiaomi @JinyuXiang-Mimo — ready for review. Small TUI fix for orphaned / re-fired permission prompts (#2502, related #2565). Typecheck + 112 permission tests pass locally; before/after capture is in the PR body. Fork PR is sitting on I only have pull access on this repo, so I can’t merge — happy to address review comments or rebase if you want it landed a certain way. |
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.
Permission prompts could re-POST the same
requestIDon every Enter/click (#2565) and, when a turn tore an ask down withoutpermission.replied, the dialog stayed up and swallowed all input (#2502).Prompt/RejectPrompt/sendReplyPermission.replyreturnsfalsefor an unknown (orphaned)requestIDfalse/ error instead of waiting foreverBefore / after
Scenario:
bash_delete/ “Confirm irreversible deletion”, orphaned ask (permission.reply→false), triple-Enter. Captured from the realPermissionPromptvia@opentui/solidtestRender(100×24).main@6babeb0bPOST …/replyPOST …/replyShort recording (prompt → triple-Enter → result): permission-before-after.mp4
Verified with
bun run typecheckandbun test test/cli/tui/permission-bash-delete.test.tsx test/permission/next.test.ts(112 pass) — covers single-reply latch, orphaned dismiss, and HTTP-error dismiss.Fixes #2502
Related to #2565