fix(onboarding): harmonize Done-page AI Fun Facts notice copy (ISSUE-001)#152
Merged
Merged
Conversation
…001) The onboarding Done page showed a contradictory AI status: the notice banner claimed "AI Fun Facts is enabled" while the configuration summary labeled the same state "Template mode". The reported toggle-off symptom is not a form-serialization defect (the toggle is a <button type="button">; formData.set plus the hidden input plus the z.enum transform mean a correct toggle-off cannot post true, and the notice is already reconciled from the saved key state via _deriveAiKeyMissingNotice). The real, reproducible issue was copy inconsistency. - Reframe the Done-page banner to the "built-in templates will be used because no OpenAI key was provided" wording so it matches the summary card's "Template mode" label; preserve the Admin -> Settings -> AI link. - Export the summary helper as _deriveFunFactsSummary (the `_` prefix is required by the +page.server.ts route-export guard and matches the sibling _deriveAiKeyMissingNotice convention); behavior is unchanged. - Extend tests/unit/onboarding/complete-notice.test.ts with a _deriveFunFactsSummary branch test pinning all three states (key -> frequency; no key + ai-key-missing -> Template mode; else -> Disabled). ISSUE-002 (anonymous "Server Members Only" denial) is resolved won't-fix-by-design: the uniform 404 is deliberate anti-enumeration behavior (ISSUE-009 / DF-04 / DF-018) and the suggested redirect to /auth/plex is rejected as an enumeration oracle. No source or test change.
🤖 Augment PR SummarySummary: Harmonizes the onboarding Done-page messaging for AI Fun Facts when no OpenAI key is configured. Changes:
Technical Notes: No settings schema, persistence, or access-control behavior changes; this is primarily a copy/visibility + test coverage update. 🤖 Was this summary useful? React with 👍 or 👎 |
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.
Summary
Remediates the two Low-severity findings from the 2026-06-18 E2E dogfood run.
ISSUE-001 — Done-page AI Fun Facts notice inconsistency (fixed)
The onboarding Done page presented a self-contradictory AI status: the notice banner read "AI Fun Facts is enabled but no OpenAI key was provided" while the configuration summary card simultaneously labeled the same state "Template mode".
Root cause is copy inconsistency, not a form-serialization defect. The Configure toggle is a
<button type="button">that contributes no form field of its own; the value is posted viaformData.setplus a hidden input, and the schema'sz.enum(['true','false']).transformmeans a correct toggle-off cannot posttrue. The notice is also already reconciled against the saved key state through_deriveAiKeyMissingNotice(ISSUE-010), so the URL param cannot go stale. The reported toggle-off symptom was a stale-snapshot automation artifact; the genuine, reproducible problem was the wording.Changes:
Admin -> Settings -> AIlink is preserved._deriveFunFactsSummary. The_prefix is required by the+page.server.tsroute-export guard and matches the sibling_deriveAiKeyMissingNoticeconvention. Behavior is unchanged; only visibility changed to make it unit-testable.tests/unit/onboarding/complete-notice.test.tswith a_deriveFunFactsSummarybranch test pinning all three states: key present -> frequency label; no key + ai-key-missing -> "Template mode - add an OpenAI key to enable AI"; otherwise -> "Disabled". The existing_deriveAiKeyMissingNoticetests are unchanged.No database, schema, access-control, or form rewrite.
settings/+page.*is unchanged.ISSUE-002 — Anonymous "Server Members Only" denial (won't-fix by design)
Resolved as working-as-designed. The uniform 404 returned to anonymous visitors of a private-oauth personal Wrapped link is deliberate anti-enumeration behavior: the same minimal body is returned for nonexistent ids, revoked tokens, and members-only resources, so there is no oracle. This was previously deliberated and locked by a contract test (ISSUE-009 / DF-04 / DF-018) that explicitly forbids a members-only "sign in" prompt firing for real member ids alone.
The dogfood recommendation to redirect anonymous users to
/auth/plexis rejected: a redirect would occur only when the resource exists and is private-oauth, while a nonexistent id returns 404 - redirect-vs-404 is itself a direct enumeration oracle. No source or test change;WRAPPED_NOT_FOUND_MESSAGE, both wrapped routes, and the sharing test literals/contract are byte-identical tomain.Verification
bun run check- 0 errors / 0 warningsbun run check:biome- cleanbun run test- 2154 pass / 0 fail, coverage gate green; the sharing suite (256 tests) passes unchanged, confirming anonymous-denial byte-identity is preserved_deriveFunFactsSummarybranch test passes (bun test -t "FunFactsSummary"-> 3 pass)Notes