Repository navigation
fix: ask for macOS notification permission when the collector starts - #58
Merged
Merged
Conversation
macOS shows the notification prompt only once. Driga asked lazily at the first alert, often while nobody was at the screen; a collector restart before the prompt was answered withdrew it, and macOS then recorded Driga as asked and not allowed, refusing every later request without a prompt. The collector now asks at startup, right after `driga service install` or a restart, when the user is likely present. macOS answers silently from the saved setting once decided. When notifications are off, `driga doctor` prints the command that opens Driga's page in System Settings, the only way to turn them on after a refusal. Usage docs state that click to jump works on macOS only. Claude-Session: https://claude.ai/code/session_01T2vtcW6ihn1ywy9vxUq9a4
vishr
added a commit
that referenced
this pull request
Oct 24, 2026
The landing page leads with a 24-second film and three short loops, all recordings of the shipped binary: - cmd/driga-demo plays scripted sessions into a private data directory: it writes the store, holds the collector lock and runs the real prompt broker, so `driga` and `driga web` read it as a live collector. It never reads the process table, agent files or Git. - site/footage records the TUI with VHS and the web dashboard (dark and light) with Playwright, then cuts site/public/media with Remotion. `just site-footage` redoes all of it. The page follows the approved design: status line, headline, install, film, feature sections for Needs you, Flow and Machines, three ways in, local by default, and a closing install. The site switches to Geist and Geist Mono, with Catppuccin state colours darkened to 4.5:1 in Latte. Docs follow the CLI changes in #59: bare `driga` opens the viewer, and activity, conflicts and --watch are gone. The notifications guide explains the one-time macOS prompt from #58. Claude-Session: https://claude.ai/code/session_01T2vtcW6ihn1ywy9vxUq9a4
vishr
added a commit
that referenced
this pull request
Oct 24, 2026
A Starlight site for driga.dev, built from the code where it can be: - cmd/driga-docgen writes the CLI, settings, MCP tools and hooks reference pages from the parser, the settings table, the MCP server and dry-run hook installers; `just docs-check` and the docgen tests fail on a stale page. - llms.txt, llms-full.txt and a Markdown alternate of every page, including the landing page's headings, commands and install line. - Catppuccin Mocha and Latte as in the app, Geist and Geist Mono, one heading scale and focus ring, state colours at 4.5:1 or better. The landing page leads with real-time screen recordings of the shipped binary: the terminal from typing `driga` to an allowed permission prompt, then the same prompt allowed in the browser, then the install command, with a Terminal · Browser · Install chapter bar. Feature sections play tight crops of the same takes, light or dark with the site theme; phones get the Needs-you crop in the hero. - cmd/driga-demo plays scripted sessions into a private temporary data directory: it holds the collector lock, writes the store and runs the real prompt broker, so `driga` and `driga web` read it as a live collector. It never reads the process table, agent files or Git. - site/footage records the TUI with VHS and `driga web` with Playwright (a drawn pointer, both themes), refusing to film unless the viewer reads the demo, and cuts the films with Remotion from film/cut.json. - Videos live in the R2 bucket driga-assets under content-hashed keys, served from assets.driga.dev and listed in src/data/media.json; posters are committed. `just site-footage` re-records, `just site-footage-publish` uploads. Docs follow #58 (one-time macOS notification prompt) and #59 (bare `driga` opens the viewer; no activity, conflicts or --watch). Deployed to Cloudflare Pages by .github/workflows/site.yml. Claude-Session: https://claude.ai/code/session_01T2vtcW6ihn1ywy9vxUq9a4
vishr
added a commit
that referenced
this pull request
Oct 24, 2026
A Starlight site for driga.dev, built from the code where it can be: - cmd/driga-docgen writes the CLI, settings, MCP tools and hooks reference pages from the parser, the settings table, the MCP server and dry-run hook installers; `just docs-check` and the docgen tests fail on a stale page. - llms.txt, llms-full.txt and a Markdown alternate of every page, including the landing page's headings, commands and install line. - Catppuccin Mocha and Latte as in the app, Geist and Geist Mono, one heading scale and focus ring, state colours at 4.5:1 or better. The landing page leads with real-time screen recordings of the shipped binary: the terminal from typing `driga` to an allowed permission prompt, then the same prompt allowed in the browser, then the install command, with a Terminal · Browser · Install chapter bar. Feature sections play tight crops of the same takes, light or dark with the site theme; phones get the Needs-you crop in the hero. - cmd/driga-demo plays scripted sessions into a private temporary data directory: it holds the collector lock, writes the store and runs the real prompt broker, so `driga` and `driga web` read it as a live collector. It never reads the process table, agent files or Git. - site/footage records the TUI with VHS and `driga web` with Playwright (a drawn pointer, both themes), refusing to film unless the viewer reads the demo, and cuts the films with Remotion from film/cut.json. - Videos live in the R2 bucket driga-assets under content-hashed keys, served from assets.driga.dev and listed in src/data/media.json; posters are committed. `just site-footage` re-records, `just site-footage-publish` uploads. Docs follow #58 (one-time macOS notification prompt) and #59 (bare `driga` opens the viewer; no activity, conflicts or --watch). Deployed to Cloudflare Pages by .github/workflows/site.yml. Claude-Session: https://claude.ai/code/session_01T2vtcW6ihn1ywy9vxUq9a4
vishr
added a commit
that referenced
this pull request
Oct 24, 2026
A Starlight site for driga.dev, built from the code where it can be: - cmd/driga-docgen writes the CLI, settings, MCP tools and hooks reference pages from the parser, the settings table, the MCP server and dry-run hook installers; `just docs-check` and the docgen tests fail on a stale page. - llms.txt, llms-full.txt and a Markdown alternate of every page, including the landing page's headings, commands and install line. - Catppuccin Mocha and Latte as in the app, Geist and Geist Mono, one heading scale and focus ring, state colours at 4.5:1 or better. The landing page leads with real-time screen recordings of the shipped binary: the terminal from typing `driga` to an allowed permission prompt, then the same prompt allowed in the browser, then the install command, with a Terminal · Browser · Install chapter bar. Feature sections play tight crops of the same takes, light or dark with the site theme; phones get the Needs-you crop in the hero. - cmd/driga-demo plays scripted sessions into a private temporary data directory: it holds the collector lock, writes the store and runs the real prompt broker, so `driga` and `driga web` read it as a live collector. It never reads the process table, agent files or Git. - site/footage records the TUI with VHS and `driga web` with Playwright (a drawn pointer, both themes), refusing to film unless the viewer reads the demo, and cuts the films with Remotion from film/cut.json. - Videos live in the R2 bucket driga-assets under content-hashed keys, served from assets.driga.dev and listed in src/data/media.json; posters are committed. `just site-footage` re-records, `just site-footage-publish` uploads. Docs follow #58 (one-time macOS notification prompt) and #59 (bare `driga` opens the viewer; no activity, conflicts or --watch). Deployed to Cloudflare Pages by .github/workflows/site.yml. Claude-Session: https://claude.ai/code/session_01T2vtcW6ihn1ywy9vxUq9a4
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.
Why notifications never worked on the maintainer's Mac
macOS asks each app for notification permission once. Driga asked lazily at the first alert. On 2026-10-23 the prompt appeared at 22:15, sat unanswered, and was withdrawn when the collector restarted at 23:22. macOS then stored Driga as asked and not allowed (same record as an explicit Don't Allow) and refused every later request immediately (
UNErrorDomain 1), with no new prompt.Verified with throwaway probe apps: a bundle launched directly by a launchd agent (as the collector is) gets the prompt and is granted on Allow, so the launch method is not the problem. The stored record for
run.drigamatched a declined probe bit for bit. After turning on Allow notifications in System Settings, a real low-disk alert was delivered and presented.Changes
attention.RequestNotificationPermission), so the prompt appears right afterdriga service installor a restart. Once decided, macOS answers silently.driga doctorprintsopen "x-apple.systempreferences:com.apple.Notifications-Settings.extension?id=run.driga"when notifications are off.Tests
TestMacRequestPermissionAsksOnceBeforeAnyAlert: one request at startup covers the first alert; a refusal is re-checked on the next alert.just check,GOOS=windows go vet ./...,GOOS=linux go vet ./...pass.https://claude.ai/code/session_01T2vtcW6ihn1ywy9vxUq9a4