Status-item NSMenu (MenuBarExtra .menu): opens but can't be inspected via Accessibility or dismissed
メンテナーはふだん 1 日以内に返信
関連するプルリクエストがすでにマージされています。
- #215 @iamnbutler による — マージ済み
評価
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 初心者へのやさしさ
- 48/100
- issue の種類
- バグ
- 明瞭さ
- おおむね明確
- 活発さ
- 活発
- 技術スタック
- swift
- 領域
- accessibility, desktop
調査の方向性
Start by tracing the desktop_menubar_click and desktop_inspect entry points and how they handle NSMenu windows in Accessibility and pixels modes. Reproduce the reported SwiftUI MenuBarExtra case on macOS and inspect the accessibility snapshot and dismissal behavior. Done means menu items and submenus can be inspected, or the menu can be dismissed without activating an item, with inspectable accurately reflecting whether inspection works.
索引モデルが issue の本文から書いたものです。
説明
What happened
I was checking a SwiftUI MenuBarExtra with .menuBarExtraStyle(.menu), which is a native NSMenu with a submenu, in an app I'd just built (Yap). The agent could open the menu, but it couldn't read or close it.
desktop_menubar_clickon the status item returnedcompleted. It listed an opened window (window_id7393, layer 101) with"inspectable": true.desktop_inspect {pid, window: 7393}in Accessibility mode failed even after its automatic retry:
The menu was open and drawn on screen at that moment. The agent couldn't list the menu items, open the submenu by element, or press a toggle.internalError: Exact window 7393 returned no usable Accessibility elements. Warning: AX tree incomplete at incomplete accessibility read. Retry once after a short wait.desktop_inspect … mode: "pixels"worked, and the screenshot was correct. But a pixel snapshot refuses key actions, so the agent couldn't send Escape to close the menu. Its only choices were clicking a menu item, which runs that action, or leaving the menu open.- Clicking the status item again didn't close the menu. Each click reported a new window opening (7392, 7393, then 7397). The last one appeared at a different x (1882 instead of 1834). By the next
desktop_inspectit had already disappeared (window_gone), and the menu eventually closed by itself.
Expected
- The open menu's items show up in an Accessibility snapshot as
AXMenuItems, with their titles, enabled state and checkmarks, and a way to open a submenu. Orinspectableshould be false when the window can't actually be inspected. - There is some way to close an open menu without choosing an item, such as Escape from a pixel snapshot of a menu window, or a
desktop_menubar_clickthat closes the status item's menu when it's already open.
Environment
macOS (Darwin 27.0.0). The target app is a SwiftUI MenuBarExtra in an LSUIElement app, Swift 6. Reported by an agent in Claude Code on 2026-10-22.
- 主要言語
- Swift
- スター
- 0
- フォーク
- 0
- 平均マージ
- 39分
- マージ済み PR(30日)
- 162
環境構築
このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
githubnext/desktop-tools のほかの issue
-
Accessibility inspect returns far-offscreen elements, blowing the budget on long pages対応中かも @iamnbutler が 1 日前に担当しました。 オープン
難易度 4/5 3〜5日 初心者へのやさしさ 48/100
githubnext/desktop-tools#178 ·
メンテナーはふだん 1 日以内に返信
-
難易度 5/5 1週間以上 初心者へのやさしさ 15/100
githubnext/desktop-tools#143 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
難易度 4/5 3〜5日 初心者へのやさしさ 42/100
githubnext/desktop-tools#129 ·
メンテナーはふだん 1 日以内に返信
-
enhancement
難易度 5/5 1週間以上 初心者へのやさしさ 8/100
githubnext/desktop-tools#5 · コメント 11 件 ·
メンテナーはふだん 1 日以内に返信
githubnext/desktop-tools の issue をすべて見る
似ている issue
-
a:bug
難易度 2/5 1〜3時間 初心者へのやさしさ 83/100
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
vorssaint/vorssaint-utils#3527 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
rorkai/App-Store-Connect-CLI#3192 ·
メンテナーはふだん 1 日以内に返信
-
bug
難易度 2/5 1〜3時間 初心者へのやさしさ 65/100
jellyfin/Swiftfin#2388 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
clawsweeper:fix-shape-clear clawsweeper:queueable-fix clawsweeper:source-repro impact:ux-friction issue-rating: 🦞 diamond lobster no-stale P2
難易度 2/5 1〜3時間 初心者へのやさしさ 74/100
openclaw/openclaw#183929 · コメント 1 件 · リアクション 1 件 ·
メンテナーはふだん 1 日以内に返信