Repository navigation
fix(sessions): recognize the German, French and Spanish placeholder titles - #1757
Conversation
…itles PLACEHOLDER_TITLES had no entries for the German, French, and Spanish chat.untitledTask labels even though those locales ship their own text (Neue Aufgabe / Nouvelle tâche / Nueva tarea) — the comment claimed they fall back to the English label, and they do not. The host therefore recorded those sessions as title_source='manual' and the first prompt never re-titled them: automatic and plugin-provided titles stayed dead in all three locales (vastsa#1755). vastsa#1725 fixed ASCII case-insensitivity; the missing locales remained. The three lowercased labels join PLACEHOLDER_TITLES and the renderer's LEGACY_DEFAULT_TITLES, with a behavioral test over the real catalogs on both sides. Also corrects the AppSettings doc comment that still said the sidebar running affordances default off after vastsa#1749 defaulted them on.
|
Fix is correct and the tests cover the important part (both the capitalized catalog label and the lowercased persisted form, on both sides of the boundary). Two gaps worth closing before merge: 1. The migration list was not updated. WHEN title IN ('', 'New task', 'New chat', '新建任务', …,
'Tarefa sem título', 'Nova conversa',
'Yeni görev', 'Yeni sohbet') THEN 'default'That migration has already run for existing installs, so it will not re-execute — but the same file's comment asks the three lists to stay in sync, and any future database that goes through v22→v23 will classify German/French/Spanish rows as 2. The Also worth noting for the PR body: the array is now mixed-case ( |
|
I confirmed the reported locale mismatch. This head fixes recognition for newly created sessions, but it leaves previously affected rows stuck: |
Review follow-ups on vastsa#1757: the v22→v23 migration list gains the six German/French/Spanish labels it was missing (future databases migrating from v22 classify those rows default instead of manual), PLACEHOLDER_TITLES now also carries the nav.newChat labels for the locales that had no entry yet (neuer chat / nuevo chat / nouvelle discussion — sessions created from that label were treated as manually named in every locale), and the whole list is stored lowercase with is_default_title comparing through to_lowercase, so a future entry with a non-ASCII uppercase letter cannot slip past ASCII-case-insensitive matching.
|
Both gaps closed in b2f29a4:
The behavioral test now drives all four forms per locale (display + persisted, both keys) against the real catalogs and asserts the host list carries all six entries. 6/6 green locally; the Rust unit test (extended with the |
|
Verified both fixes in
That closes both gaps I raised. All five checks are green and the branch is |
|
Verified both fixes in
That closes both gaps I raised. All five checks are green and the branch is One thing to keep in the description: the stuck-row repair for already-migrated installs is still a separate follow-up (as you noted) — worth an explicit line so a reviewer does not read this as fixing existing affected databases too. |
|
Thanks for the focused fix. I verified the host/renderer placeholder lists and the forward-migration labels against the reported German, French, and Spanish title path. The PR was refreshed to include the latest main, all five required checks passed on |
Fixes #1755
Fixes #1755
Summary
PLACEHOLDER_TITLESgains the lowercased German, French, and Spanishchat.untitledTasklabels (neue aufgabe,nouvelle tâche,nueva tarea), and the misleading "fall back to the English label" comment is replaced with the actual rule (entries are stored as the renderer writes them: lowercased, one per localized label).LEGACY_DEFAULT_TITLESgains the same three entries.AppSettingsdoc comment for the sidebar running affordances still said "absent means disabled" after fix(sidebar): default running activity to count badge #1749 defaulted them on (!== falsenormalization inlib/api.ts); the comment now matches the behavior.Rationale
#1755: with UI language French/German/Spanish, new sessions carry their localized placeholder, the host's
is_default_titlemissed it,title_sourcebecamemanual, and thetitle_source != defaultguard kept the first prompt from ever re-titling the session — auto-titling and plugin titles permanently dead in three locales. #1725 fixed ASCII case-insensitivity; the missing labels remained.Affected specs / ADRs / E2E scenarios
session-titlecases: NOT RUN; the new behavioral test drives the real catalogs and the realisDefaultSessionTitle, and asserts the host list carries the three labels.title_source='manual'from before this change are not re-classified — that would be a data migration (the v22→v23 migration is already applied and must not be edited). Left as a follow-up decision; new sessions are fixed by this change.Validation (on latest
origin/main)session-title-prompt-fallback.test.mjs: for each of the three locales, the catalog still owns its label,isDefaultSessionTitlerecognizes both the display and persisted forms, andPLACEHOLDER_TITLEScarries the entries. File: 6 pass / 0 fail.default_title_matches_the_german_french_and_spanish_placeholdersadded next tois_default_title. NOT RUN locally — no Rust toolchain on this Windows box; the ubuntu Rust lane covers it.tsc --noEmitinapps/desktop: pass.Compatibility / remaining risk
title_source=default; real user titles are unaffected (eq_ignore_ascii_caseover a closed list).