Skip to content

Make GUI wake reliable + fail loud instead of silent no-op#24

Merged
ThinkOffApp merged 1 commit into
mainfrom
fix/gemini-gui-nudge-wake
Jul 6, 2026
Merged

Make GUI wake reliable + fail loud instead of silent no-op#24
ThinkOffApp merged 1 commit into
mainfrom
fix/gemini-gui-nudge-wake

Conversation

@ThinkOffApp

Copy link
Copy Markdown
Owner

Two hardening fixes to the AppleScript that brings a target app to the front before keystroking a nudge (silent wake drops traced to this). Recovered from the Mini clone.

  • Force focus reliably: open -a (forces launch + focus even when the app is hidden/minimized or another app holds focus — full-screen, Mission Control, a modal) followed by activate, instead of activate alone.
  • More focus budget: 5×0.2s (1s) → 15×0.5s (7.5s). Stuck-poller incidents (2026-05-04) were ABORTs that cleared on the next nudge.
  • Fail loud: on give-up, throw an AppleScript error (exit non-zero) instead of return (exit 0). Previously wake.sh logged "nudge sent" for an actual no-op (3+ hours of silent ABORTs, 2026-05-05).

No behavior change on the happy path.

…nt no-op

Two hardening fixes to the AppleScript that brings a target app to the
front before keystroking a nudge (silent wake drops traced to this).

- Force focus more reliably: `open -a` (forces launch + focus even when the
  app is hidden/minimized or another app holds focus — full-screen, Mission
  Control, a modal) followed by `activate`, instead of relying on `activate`
  alone.
- Give the focus loop more budget: 5x0.2s (1s) -> 15x0.5s (7.5s). Stuck-poller
  incidents (2026-05-04) were ABORTs that cleared on the next nudge because
  activate needs longer when the user is across spaces / in another full-screen
  window.
- Fail loud: on give-up, throw an AppleScript error (exit non-zero) instead of
  `return` (exit 0). Previously wake.sh logged "nudge sent" for what was
  actually a no-op (confirmed 3+ hours of silent ABORTs, 2026-05-05).

No behavior change on the happy path.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@cursor

cursor Bot commented Jul 6, 2026

Copy link
Copy Markdown

Bugbot is not enabled for your account, so this pull request was not reviewed.

Enable Bugbot in the Cursor dashboard to get automatic reviews on future PRs.

@ThinkOffApp ThinkOffApp merged commit 7aadb66 into main Jul 6, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant