Repository navigation
fix: report the matched window and add exactTitle for window targets (#89) - #137
Merged
Merged
Conversation
…89) start_recording now returns matchedWindow, matchCount, matchKind and the captured region, as screenshot does, and keeps matchedWindow on the session. A substring-only or ambiguous match adds a windowWarning listing the candidate titles, and exactTitle: true refuses the substring fallback entirely. Co-Authored-By: Claude Opus 5.5 <[email protected]>
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 #89.
What
A generic
window:Codecould match a different window by substring (topmost wins), andstart_recordingnever said which one. That's a quiet privacy failure under the threat model.selectWindownow also returnsmatchKind(exact|substring) and up to 5candidates, and takes{ exactOnly }.windowMatchReport()builds the fields both capture tools return:matchedWindow,matchCount,matchKind,region(rect only), and awindowWarninglisting candidates when the match was a substring or ambiguous.start_recordingreturns those fields (it used to drop the match entirely) and storesmatchedWindowon the session, soget_sessionshows it.exactTitle: trueonscreenshotandstart_recordingrefuses the substring fallback; the error lists near-miss titles.Small shape change:
screenshot'sregionfor a window target is now just{x, y, width, height}; the match details are top-level. Noted under Changed in the CHANGELOG.Tests
exactOnlyrefusal with near misses, candidate cap.start_recordingon a real window withexactTitlereportsmatchedWindow/matchKind: exact,get_sessionkeeps it, and a strict prefix of the title is refused underexactTitle.Version 0.14.0; README, ROADMAP, CHANGELOG,
mcp-tools.jsonupdated.🤖 Generated with Claude Code