chain-studio/lib/data
flemming-it c6da5025ce
Some checks failed
Security / Security check (push) Failing after 2s
fix(setup): wizard errors copyable above the dialog, CLI skew explained, exec transparency
Field test of the setup wizard surfaced three trust breaks in one run:
an unexplained macOS Documents permission prompt, a perceived crash,
and an error message whose copy button could not be reached.

Root causes and fixes:
- chain init failures were shown as a SnackBar, which lands BEHIND the
  wizard's modal barrier: dimmed, clipped, copy unreachable — and the
  click aimed at it hit the barrier, dismissing the whole wizard with
  all answers (the perceived crash). Errors now open a modal dialog
  ABOVE the wizard via showChainErrorDialog with a copyable detail
  block, and the wizard is no longer barrier-dismissible.
- When the resolved chain binary is older than Studio and rejects
  --plan-json, the wizard now explains the version skew in plain
  language (binary path + update path) instead of leaking a raw clap
  usage error. A missing binary gets its own localized story.
- Step 3 announces which chain binary the preview will execute; when
  that binary physically lives (symlinks resolved) in a TCC-protected
  folder, the wizard pre-explains the macOS folder prompt.

Supporting changes: FriendlyError passes through friendlyError()
unchanged so call sites can ship precise localized stories through the
shared presentation; SystemActions gains resolvedChainBinary() plus
run/resolve test seams; ChainErrorBox hugs its content instead of
filling an unbounded dialog; the wizard's answers file is written
synchronously (the async dart:io variants never complete under the
widget-test fake-async zone).

Verified: flutter analyze clean, 53 tests green (6 new wizard error-
path tests incl. clipboard round-trip), plus a live GUI walk on macOS
in dark + light with a stale binary (skew dialog, copy verified via
clipboard) and with the real binary (TCC pre-explanation with the
resolved path, full plan preview).

Signed-off-by: flemming-it <stefan.a.flemming@googlemail.com>
2026-07-15 00:10:01 +02:00
..
chain_log.dart fix(approvals,l10n,theme): usertest findings — localized prompts, no-data confirm, .chain log path, honest wording, AA contrast 2026-07-11 02:38:24 +02:00
error_presentation.dart refactor: FaiError -> ChainError (SDK stub rename lockstep) 2026-07-11 23:14:33 +02:00
flow_output.dart refactor: rename app fai_studio -> chain_studio 2026-06-16 17:48:11 +02:00
flow_run_driver.dart feat: workspace switcher, per-project filters and run stamping (stage 1) 2026-07-12 13:49:51 +02:00
format.dart feat(studio): typed flow outputs + on-disk docs + UX polish 2026-05-25 11:17:58 +02:00
friendly_error.dart fix(setup): wizard errors copyable above the dialog, CLI skew explained, exec transparency 2026-07-15 00:10:01 +02:00
hub.dart feat: detached-runs monitor page (T3 parity) 2026-07-12 14:43:37 +02:00
hub_auth_token.dart fix(studio): chain config dir + spawn path + doc URLs 2026-06-16 09:38:30 +02:00
registry_token.dart refactor: rename internal Fai* design system + fai_ helpers to chain 2026-06-16 17:53:17 +02:00
sealed_areas.dart feat: sealed-area connection switch + identity bar (multi-project stage 3) 2026-07-12 17:31:39 +02:00
system_actions.dart fix(setup): wizard errors copyable above the dialog, CLI skew explained, exec transparency 2026-07-15 00:10:01 +02:00
theme_plugin.dart refactor: rename internal Fai* design system + fai_ helpers to chain 2026-06-16 17:53:17 +02:00
today_story_loader.dart fix(studio): chain config dir + spawn path + doc URLs 2026-06-16 09:38:30 +02:00
workspace.dart feat: sealed-area connection switch + identity bar (multi-project stage 3) 2026-07-12 17:31:39 +02:00