fix(ssh-auth-sock): warn when override path looks bogus#1439
Conversation
Two reviewer findings on the SSH_AUTH_SOCK override path (post-merge of #1438): - src/util.h: doc tweak — clarify that the "no validation" line refers to the runtime environment-setup step. The Settings dialog now does a soft check at save time. - src/configdialog.cpp: when the user types a non-empty override and saves, do a soft check before writing the setting: - QFileInfo::exists() and isReadable() - on Unix, stat() + S_ISSOCK to confirm it's a Unix domain socket (Windows ssh-agent uses a named pipe, so we skip the socket check there) When any check fails, show a non-blocking QMessageBox::warning telling the user the path looks invalid and that the value will still be saved as entered. This preserves the "QtPass trusts the user choice" stance (e.g. user might start their agent after launching QtPass) while giving immediate feedback on typos. The runtime probe in Util::initialiseSshAuthSock() is unchanged — it still uses the override verbatim, no ssh-add validation, matching the existing contract. No new tests: the warning is a UI-side soft check on data the user just typed, with no side effects beyond the dialog. The existing initialiseSshAuthSockOverrideSkipsAgentValidation test continues to verify the runtime "no validation" contract. lupdate refreshed the .ts files to pick up the four new tr() strings (dialog title + 3 reasons + body template). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
|
Caution Review failedFailed to post review comments 📝 WalkthroughWalkthroughRetargets many locale .ts UI message locations to generated ui_*.h headers and adds new ConfigDialog runtime and validation messages (required-field, filesystem/SSH_AUTH_SOCK checks, profile/password-store prompts/errors, GnuPG install guidance, and dependency notices) across numerous language files. ChangesQt Translation Update (ConfigDialog + UI headers)
Sequence Diagram(s)(Conditions for sequence diagrams are met: new control flow across multiple components.) sequenceDiagram
participant User
participant ConfigDialog
participant Filesystem
participant GnuPG
participant UI
User->>UI: open ConfigDialog / change SSH_AUTH_SOCK
UI->>ConfigDialog: submit override/path
ConfigDialog->>Filesystem: check path exists/readable/is-socket
Filesystem-->>ConfigDialog: result (ok/error)
ConfigDialog->>GnuPG: optional autodetect probe
GnuPG-->>ConfigDialog: probe result
ConfigDialog->>UI: show validation message / profile prompts / dependency hints
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Possibly related PRs
Suggested labels
Suggested reviewers
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
|
There was a problem hiding this comment.
Actionable comments posted: 18
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@localization/localization_af.ts`:
- Around line 486-513: Add Afrikaans translations for the five empty messages
corresponding to the source strings "The path does not exist.", "The path is not
readable.", "The path is not a Unix domain socket.", "Potentially invalid
SSH_AUTH_SOCK override", and the multi-line "The SSH_AUTH_SOCK override value
may be invalid...\n\n%1\n\nThe value will still be saved as entered." in
localization_af.ts by filling each <translation> element with a best-effort
Afrikaans sentence while preserving type="unfinished" (do not remove or change
the attribute) and ensure the multi-line message includes the %1 placeholder
verbatim in the translated text; update only the <translation> contents for
those message entries.
In `@localization/localization_ar.ts`:
- Around line 453-480: Fill the five empty translation entries in
localization_ar.ts for the SSH_AUTH_SOCK validation messages by providing
best-effort Arabic translations (keep the attribute type="unfinished") for these
source strings: "The path does not exist.", "The path is not readable.", "The
path is not a Unix domain socket.", "Potentially invalid SSH_AUTH_SOCK
override", and the multi-line message starting "The SSH_AUTH_SOCK override value
may be invalid.\n\n%1\n\nThe value will still be saved as entered."; ensure each
corresponding <translation> element contains the Arabic text and retains
type="unfinished" so Weblate can refine them later.
In `@localization/localization_bg.ts`:
- Around line 486-513: Add Bulgarian translations (marked type="unfinished") for
the five new message entries that are currently empty: the strings "The path
does not exist.", "The path is not readable.", "The path is not a Unix domain
socket.", "Potentially invalid SSH_AUTH_SOCK override", and the multiline "The
SSH_AUTH_SOCK override value may be invalid.\n\n%1\n\nThe value will still be
saved as entered." in localization_bg.ts; update the corresponding <translation>
elements to contain accurate Bulgarian text (keeping type="unfinished") so the
bg locale no longer falls back to English, and ensure the multiline message
preserves %1 placeholder and paragraph breaks.
In `@localization/localization_bn.ts`:
- Around line 531-558: Add best-effort Bengali translations for the four new
SSH_AUTH_SOCK validation messages by replacing the empty <translation
type="unfinished"></translation> entries corresponding to the source texts "The
path does not exist.", "The path is not readable.", "The path is not a Unix
domain socket.", and the two-line "Potentially invalid SSH_AUTH_SOCK override" /
"The SSH_AUTH_SOCK override value may be invalid.\n\n%1\n\nThe value will still
be saved as entered." with appropriate Bengali strings (retain
type="unfinished") so Weblate has initial translations to refine; ensure the
exact source strings above are matched to update the correct <translation>
elements and do not change the surrounding XML structure or attributes.
In `@localization/localization_ca.ts`:
- Around line 486-513: Replace the five empty translation entries for the
SSH_AUTH_SOCK validation messages in localization_ca.ts (the messages with
source texts "The path does not exist.", "The path is not readable.", "The path
is not a Unix domain socket.", "Potentially invalid SSH_AUTH_SOCK override", and
the multi-line "The SSH_AUTH_SOCK override value may be invalid.\n\n%1\n\nThe
value will still be saved as entered.") with concise Catalan translations,
keeping the translation attributes as type="unfinished" so Weblate reviewers can
verify them; update only the <translation> content for those specific message
blocks referenced from configdialog.cpp without changing other tags or
structure.
In `@localization/localization_cs.ts`:
- Around line 338-365: Add Czech translations for the five new empty
<translation type="unfinished"> entries corresponding to the messages from
configdialog.cpp: "The path does not exist.", "The path is not readable.", "The
path is not a Unix domain socket.", "Potentially invalid SSH_AUTH_SOCK
override", and the multi-line "The SSH_AUTH_SOCK override value may be
invalid.\n\n%1\n\nThe value will still be saved as entered." — update each empty
<translation type="unfinished"> element in localization_cs.ts with a best-effort
Czech string (keep type="unfinished") matching the meaning and punctuation of
the source, preserving the %1 placeholder and paragraph breaks exactly for the
multi-line message.
In `@localization/localization_cy.ts`:
- Around line 1904-1908: The translation for the source "Show unusable keys" in
localization/localization_cy.ts is truncated ("Dangos bysellau na ellir eu");
replace it with a complete Welsh translation such as "Dangos bysellau na ellir
eu defnyddio" (or "Dangos allweddi na ellir eu defnyddio" if preferred), update
the translation element for that message (the one matching source "Show unusable
keys"), and if you’re not 100% confident mark the translation with
type="unfinished"; ensure the replacement uses the same XML/TS attribute
structure and correct encoding.
- Around line 531-557: Add Welsh translations for the five new source strings
from configdialog.cpp: "The path does not exist.", "The path is not readable.",
"The path is not a Unix domain socket.", "Potentially invalid SSH_AUTH_SOCK
override", and the multi-line "The SSH_AUTH_SOCK override value may be
invalid.\n\n%1\n\nThe value will still be saved as entered."; update their
corresponding <translation> elements in localization/localization_cy.ts (leave
type="unfinished"), ensure placeholders like %1 and any newlines/formatting are
preserved exactly, and avoid altering other attributes or tags so the
translations replace the empty entries without changing structure.
In `@localization/localization_da.ts`:
- Around line 486-513: Add Danish translations for the empty SSH_AUTH_SOCK
messages in localization_da.ts by filling the <translation> elements for the
source strings "The path does not exist.", "The path is not readable.", "The
path is not a Unix domain socket.", "Potentially invalid SSH_AUTH_SOCK override"
and the multi-line message containing "%1" with best-effort Danish text while
keeping type="unfinished"; ensure the placeholder %1 remains exactly as in the
source and no HTML or script changes are introduced so the strings stay safe for
runtime replacement.
In `@localization/localization_de_DE.ts`:
- Around line 478-505: Fill the five empty German translations in
localization_de_DE.ts for the new SSH_AUTH_SOCK-related messages: provide
best-effort German text for the source strings "The path does not exist.", "The
path is not readable.", "The path is not a Unix domain socket.", "Potentially
invalid SSH_AUTH_SOCK override" and the multi-line "The SSH_AUTH_SOCK override
value may be invalid.\n\n%1\n\nThe value will still be saved as entered." while
keeping each translation element marked type="unfinished"; update the
corresponding <translation> text entries (referencing the source strings from
configdialog.cpp shown in the diff) with concise German translations that
preserve the placeholder %1.
In `@localization/localization_de_LU.ts`:
- Around line 467-494: Add German (Luxembourg) best-effort translations for the
four empty SSH_AUTH_SOCK-related entries in localization/localization_de_LU.ts
corresponding to the source strings "The path does not exist.", "The path is not
readable.", "The path is not a Unix domain socket.", and the multi-line "The
SSH_AUTH_SOCK override value may be invalid.\n\n%1\n\nThe value will still be
saved as entered."; replace the empty <translation
type="unfinished"></translation> tags with appropriate German translations
(keeping type="unfinished") so the de_LU locale no longer falls back to English
but still signals the translation is provisional.
In `@localization/localization_el.ts`:
- Around line 457-484: Provide Greek translations for the five empty
<translation> entries corresponding to the source strings "The path does not
exist.", "The path is not readable.", "The path is not a Unix domain socket.",
"Potentially invalid SSH_AUTH_SOCK override", and the multiline "The
SSH_AUTH_SOCK override value may be invalid.\n\n%1\n\nThe value will still be
saved as entered."; ensure each translation preserves the %1 placeholder exactly
and keep type="unfinished" on each <translation> element; craft concise, natural
Greek text that matches the original meanings (including the multiline structure
for the SSH_AUTH_SOCK message) so the placeholder and line breaks remain intact.
In `@localization/localization_en_GB.ts`:
- Around line 486-513: Fill the empty <translation type="unfinished"> entries
for the six SSH_AUTH_SOCK validation messages by providing British English
translations that match the source meanings (e.g. "The path does not exist.",
"The path is not readable.", "The path is not a Unix domain socket.",
"Potentially invalid SSH_AUTH_SOCK override", and the multi-line warning
starting "The SSH_AUTH_SOCK override value may be invalid.\n\n%1\n\nThe value
will still be saved as entered."). Keep each translation marked with
type="unfinished" (do not remove or change that attribute) and ensure spelling
and phrasing follow British English conventions used elsewhere in the file.
In `@localization/localization_en_US.ts`:
- Around line 486-513: Fill the empty <translation> tags by copying the
corresponding <source> text into each <translation> for the six messages shown
(e.g., "The path does not exist.", "The path is not readable.", "The path is not
a Unix domain socket.", "Potentially invalid SSH_AUTH_SOCK override", and the
multi-line SSH_AUTH_SOCK override message) while leaving the attribute
type="unfinished" intact so Weblate can refine them later; locate these messages
in the same message blocks referencing configdialog.cpp (the strings above) and
replace the empty translations with the exact source text.
In `@localization/localization_es_AR.ts`:
- Around line 536-563: Translate the five empty Spanish entries in
localization/localization_es_AR.ts corresponding to the configdialog messages:
"The path does not exist.", "The path is not readable.", "The path is not a Unix
domain socket.", "Potentially invalid SSH_AUTH_SOCK override", and the
multi-line message beginning "The SSH_AUTH_SOCK override value may be invalid."
Replace each empty <translation type="unfinished"></translation> with an
appropriate es_AR translation (keep type="unfinished"), ensuring the placeholder
%1 remains exactly as-is in the multi-line message and do not alter surrounding
XML structure or tags; use the exact source strings to locate the correct
<message> blocks (from configdialog.cpp entries) and update only their
<translation> contents.
In `@localization/localization_es_EC.ts`:
- Around line 536-563: Add best-effort Spanish translations (marked
type="unfinished") for the five empty SSH_AUTH_SOCK validation messages shown by
the source strings "The path does not exist.", "The path is not readable.", "The
path is not a Unix domain socket.", "Potentially invalid SSH_AUTH_SOCK
override", and the multi-line "The SSH_AUTH_SOCK override value may be
invalid.\n\n%1\n\nThe value will still be saved as entered." — update the
corresponding <translation> elements to contain appropriate Spanish text (short,
natural translations) while preserving the type="unfinished" attribute so
Weblate can refine them later.
In `@localization/localization_es_ES.ts`:
- Around line 536-563: Add best-effort Spanish translations for the five
unfinished SSH_AUTH_SOCK validation messages in localization_es_ES.ts by
populating the empty <translation type="unfinished">...</translation> tags for
the source strings "The path does not exist.", "The path is not readable.", "The
path is not a Unix domain socket.", "Potentially invalid SSH_AUTH_SOCK override"
and the multi-line message beginning "The SSH_AUTH_SOCK override value may be
invalid." — use terminology consistent with existing SSH_AUTH_SOCK entries
(e.g., "sustitución", "detección automática") and keep each translation marked
type="unfinished" so Weblate can refine them later.
In `@localization/localization_es_MX.ts`:
- Around line 536-563: The Spanish localization file localization_es_MX.ts
contains empty translations for the SSH_AUTH_SOCK validation messages; fill in
best-effort Spanish translations for the source strings "The path does not
exist.", "The path is not readable.", "The path is not a Unix domain socket.",
"Potentially invalid SSH_AUTH_SOCK override", and the multi-line message
starting "The SSH_AUTH_SOCK override value may be invalid.\n\n%1\n\nThe value
will still be saved as entered.", ensuring each translation is added as the
translation text and retains type="unfinished" so Weblate can refine them later;
update the translation entries corresponding to those source strings in the file
(eg. entries from configdialog.cpp referenced in the diff) only—do not change
source texts or attributes other than populating the translation content.
🪄 Autofix (Beta)
❌ Autofix failed (check again to retry)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI (base), Organization UI (inherited)
Review profile: ASSERTIVE
Plan: Pro
Run ID: 35c8cdbe-6992-489f-8cd9-727386d6f9b1
📒 Files selected for processing (66)
localization/localization_af.tslocalization/localization_ar.tslocalization/localization_bg.tslocalization/localization_bn.tslocalization/localization_ca.tslocalization/localization_cs.tslocalization/localization_cy.tslocalization/localization_da.tslocalization/localization_de_DE.tslocalization/localization_de_LU.tslocalization/localization_el.tslocalization/localization_en_GB.tslocalization/localization_en_US.tslocalization/localization_es_AR.tslocalization/localization_es_EC.tslocalization/localization_es_ES.tslocalization/localization_es_MX.tslocalization/localization_es_UY.tslocalization/localization_et.tslocalization/localization_fa.tslocalization/localization_fi.tslocalization/localization_fr_BE.tslocalization/localization_fr_FR.tslocalization/localization_fr_LU.tslocalization/localization_fy_NL.tslocalization/localization_gl.tslocalization/localization_he.tslocalization/localization_hi.tslocalization/localization_hr.tslocalization/localization_hu.tslocalization/localization_id.tslocalization/localization_it.tslocalization/localization_ja.tslocalization/localization_ko.tslocalization/localization_lb_LU.tslocalization/localization_lt.tslocalization/localization_lv.tslocalization/localization_mr.tslocalization/localization_nb.tslocalization/localization_nl_BE.tslocalization/localization_nl_NL.tslocalization/localization_pa_IN.tslocalization/localization_pl.tslocalization/localization_pt_BR.tslocalization/localization_pt_PT.tslocalization/localization_ro.tslocalization/localization_ru.tslocalization/localization_si.tslocalization/localization_sk.tslocalization/localization_sl.tslocalization/localization_sq.tslocalization/localization_sr_Cyrl.tslocalization/localization_sr_RS.tslocalization/localization_sv.tslocalization/localization_sw.tslocalization/localization_ta.tslocalization/localization_te.tslocalization/localization_th.tslocalization/localization_tr.tslocalization/localization_uk.tslocalization/localization_ur.tslocalization/localization_vi.tslocalization/localization_zh_CN.tslocalization/localization_zh_Hant.tssrc/configdialog.cppsrc/util.h
|
Note Autofix is a beta feature. Expect some limitations and changes as we gather feedback and continue to improve it. Fixes Applied SuccessfullyFixed 17 file(s) based on 18 unresolved review comments. Files modified:
Commit: The changes have been pushed to the Time taken: |
|
Note Autofix is a beta feature. Expect some limitations and changes as we gather feedback and continue to improve it. The branch was updated while autofix was in progress. Please try again. |
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #1439 +/- ##
==========================================
- Coverage 33.39% 33.26% -0.14%
==========================================
Files 44 44
Lines 4324 4341 +17
==========================================
Hits 1444 1444
- Misses 2880 2897 +17
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
Fixed 17 file(s) based on 18 unresolved review comments. Co-authored-by: CodeRabbit <noreply@coderabbit.ai>
There was a problem hiding this comment.
Actionable comments posted: 3
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (2)
localization/localization_en_US.ts (2)
727-1007:⚠️ Potential issue | 🟡 Minor | ⚡ Quick winExport/Import dialog en_US entries are still empty
In changed
ExportPublicKeyDialogandImportKeyDialogblocks, many translations remain empty (e.g., Line 731, Line 737, Line 743, Line 932, Line 938, Line 944). These should be filled with best-effort en_US text (typically identical to<source>) while keepingtype="unfinished".As per coding guidelines, "fill empty entries with best-effort translations marked
type="unfinished"".🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@localization/localization_en_US.ts` around lines 727 - 1007, Fill all empty <translation> entries in the ExportPublicKeyDialog and ImportKeyDialog message blocks by copying the corresponding <source> text into each <translation> element while leaving the attribute type="unfinished" intact; target the strings associated with ExportPublicKeyDialog (e.g., "Export Public Key", "Public key", "Copy to Clipboard", "Save to File...", "Public key for %1", "Copied!", "Save Public Key", "ASCII-armored key (*.asc);;All files (*)", "Could not open %1 for writing: %2", "Could not write to %1: %2") and ImportKeyDialog (e.g., "Import GPG Key", the descriptive import sentence, "From File...", "From Clipboard", "Paste an ASCII-armored GPG key here...", "Import", "ASCII-armored GPG key", "All Files", "Import Key", "Could not open file: %1", "%1 does not look like an ASCII-armored GPG key. Convert it with <code>gpg --armor --export</code> first, or paste the armored block via <b>From Clipboard</b>.", "GPG import failed:\n%1", "Could not parse imported key id from GPG output.", "Successfully imported key: %1"); ensure each translation exactly matches its source text and preserve any placeholders like %1 and markup.
13-608:⚠️ Potential issue | 🟡 Minor | ⚡ Quick winFill empty en_US translations in changed message blocks
Multiple changed entries still have empty
<translation type="unfinished"></translation>(for example, Line 16, Line 94, Line 166, Line 172, Line 184, Line 483, Line 521). Please populate these with the source text so the locale file is complete while remainingtype="unfinished".Suggested pattern
- <translation type="unfinished"></translation> + <translation type="unfinished">Settings</translation>- <translation type="unfinished"></translation> + <translation type="unfinished">Show process output</translation>As per coding guidelines, "fill empty entries with best-effort translations marked
type="unfinished"".Also applies to: 1319-1790
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@localization/localization_en_US.ts` around lines 13 - 608, Several message entries in localization_en_US.ts (e.g., source strings "Show process output", "Enable content search (pass grep)", "(Optional path ...)", "This field is required", "Create profile directory?", "Would you like to create a password store at %1?", "Could not create profile directory: %1", "Select recipients for %1", "New Profile", "Failed to create password-store at: %1", "New profile: %1 at %2", "Profile: %1 at %2", "Fill in all required fields", etc.) have empty <translation type="unfinished"></translation> tags; populate each empty translation by copying the corresponding <source> text into its <translation> value while keeping type="unfinished" unchanged so the locale remains marked unfinished but complete. Locate these messages by their source strings (and related functions in configdialog.cpp like the ones producing "This field is required" and profile/create prompts) and update the translation nodes accordingly for all affected blocks.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@localization/localization_ca.ts`:
- Around line 496-499: Update the Catalan translation for the source string "The
path is not a Unix domain socket." in localization_ca.ts by replacing the
incorrect word "sòcol" with the proper technical term "socket" (i.e., change "El
camí no és un sòcol de domini Unix." to use "socket" so it reads "El camí no és
un socket de domini Unix."). Ensure the translation string for that <message>
entry matches the corrected wording and retains the existing attributes (e.g.,
type="unfinished") if present.
In `@localization/localization_en_GB.ts`:
- Around line 193-196: The en_GB translation for the source string "Optional
path to override SSH_AUTH_SOCK. Leave empty to auto-probe via gpgconf (issue
`#543`)." was altered to add the extra word "see"; update the <translation> entry
corresponding to that <source> so it matches the source wording exactly (replace
"Optional path to override SSH_AUTH_SOCK. Leave empty to auto-detect via gpgconf
(see issue `#543`)." with the same phrasing as the <source> text, preserving
"auto-probe" and "(issue `#543`)"). Ensure the <translation> tag content exactly
mirrors the source text and save the .ts file.
In `@localization/localization_es_EC.ts`:
- Around line 536-567: Update the Spanish translations for the SSH_AUTH_SOCK
override messages so terminology is consistent: for the source strings
"Potentially invalid SSH_AUTH_SOCK override" and "The SSH_AUTH_SOCK override
value may be invalid.\n\n%1\n\nThe value will still be saved as entered."
replace "Sustitución de SSH_AUTH_SOCK" and "El valor de sustitución de
SSH_AUTH_SOCK" with "Anulación de SSH_AUTH_SOCK" and "El valor de anulación de
SSH_AUTH_SOCK" respectively, preserving the %1 placeholder and line breaks
exactly and leaving other translations unchanged.
---
Outside diff comments:
In `@localization/localization_en_US.ts`:
- Around line 727-1007: Fill all empty <translation> entries in the
ExportPublicKeyDialog and ImportKeyDialog message blocks by copying the
corresponding <source> text into each <translation> element while leaving the
attribute type="unfinished" intact; target the strings associated with
ExportPublicKeyDialog (e.g., "Export Public Key", "Public key", "Copy to
Clipboard", "Save to File...", "Public key for %1", "Copied!", "Save Public
Key", "ASCII-armored key (*.asc);;All files (*)", "Could not open %1 for
writing: %2", "Could not write to %1: %2") and ImportKeyDialog (e.g., "Import
GPG Key", the descriptive import sentence, "From File...", "From Clipboard",
"Paste an ASCII-armored GPG key here...", "Import", "ASCII-armored GPG key",
"All Files", "Import Key", "Could not open file: %1", "%1 does not look like an
ASCII-armored GPG key. Convert it with <code>gpg --armor --export</code> first,
or paste the armored block via <b>From Clipboard</b>.", "GPG import
failed:\n%1", "Could not parse imported key id from GPG output.", "Successfully
imported key: %1"); ensure each translation exactly matches its source text and
preserve any placeholders like %1 and markup.
- Around line 13-608: Several message entries in localization_en_US.ts (e.g.,
source strings "Show process output", "Enable content search (pass grep)",
"(Optional path ...)", "This field is required", "Create profile directory?",
"Would you like to create a password store at %1?", "Could not create profile
directory: %1", "Select recipients for %1", "New Profile", "Failed to create
password-store at: %1", "New profile: %1 at %2", "Profile: %1 at %2", "Fill in
all required fields", etc.) have empty <translation
type="unfinished"></translation> tags; populate each empty translation by
copying the corresponding <source> text into its <translation> value while
keeping type="unfinished" unchanged so the locale remains marked unfinished but
complete. Locate these messages by their source strings (and related functions
in configdialog.cpp like the ones producing "This field is required" and
profile/create prompts) and update the translation nodes accordingly for all
affected blocks.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI (base), Organization UI (inherited)
Review profile: ASSERTIVE
Plan: Pro
Run ID: 5b8f0ad6-92dc-435d-b812-394283d72014
📒 Files selected for processing (17)
localization/localization_af.tslocalization/localization_ar.tslocalization/localization_bg.tslocalization/localization_bn.tslocalization/localization_ca.tslocalization/localization_cs.tslocalization/localization_cy.tslocalization/localization_da.tslocalization/localization_de_DE.tslocalization/localization_de_LU.tslocalization/localization_el.tslocalization/localization_en_GB.tslocalization/localization_en_US.tslocalization/localization_es_AR.tslocalization/localization_es_EC.tslocalization/localization_es_ES.tslocalization/localization_es_MX.ts
distclean+qmake6 regenerated the .ts files without the spurious
location pointers into generated headers (ui_configdialog.h,
ui_mainwindow.h, etc.) that lupdate had captured earlier. Net -9861
lines, no semantic change to translations or source strings.
Plus 3 reviewer findings on the new SSH_AUTH_SOCK strings:
- ca: "sòcol" → "socket" in "El camí no és un socket de domini Unix."
("sòcol" means a wall socket / plinth, not a Unix-domain socket).
- en_GB: undo a CodeRabbit auto-fix divergence — the en_GB translation
had drifted to "auto-detect via gpgconf (see issue #543)" when the
source uses "auto-probe" and "(issue #543)" with no leading "see".
Mirror the source exactly.
- es_EC: standardise on "Anulación" for the override-related strings.
The Settings-dialog warning had used "Sustitución" / "sustitución",
inconsistent with the existing override-label "Anulación de
SSH_AUTH_SOCK:" in the same file.
Skipped — out of scope for this PR:
- en_US bulk fills for ExportPublicKeyDialog and ImportKeyDialog
blocks (those source strings live behind separate features and were
not touched here).
- en_US bulk fills for unrelated ConfigDialog entries (pre-existing
empties; Weblate territory).
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
|
Pushed f6bbd0f. 1. Removed generated-header locations from .ts files ( lupdate had captured `<location filename="../src/ui_configdialog.h" ...>` etc. — pointers into Qt-generated headers that don't exist in source control. distclean wiped them, qmake6 regenerated cleanly. Net -9861 lines across 63 .ts files, zero string changes. 2. Three reviewer findings, all still valid:
Skipped — out of scope for #1439:
Validation: |
Best-effort Chinese translations for the validation strings introduced in #1439, kept type="unfinished" so Weblate can refine. Reuses the 覆盖 terminology established in PR #1441 for "override": - "The path does not exist." → "路径不存在。" - "The path is not readable." → "路径不可读。" - "The path is not a Unix domain socket." → "路径不是 Unix 域套接字。" - "Potentially invalid SSH_AUTH_SOCK override" → "SSH_AUTH_SOCK 覆盖值可能无效" - "The SSH_AUTH_SOCK override value may be invalid.\n\n%1\n\nThe value will still be saved as entered." → matching multi-line form, %1 placeholder preserved. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* i18n(zh_CN): "绕过" → "覆盖" for SSH_AUTH_SOCK override Reviewer-flagged: the existing translation rendered "override" as 绕过 (bypass / circumvent), which has the wrong semantic — "override" here means "replace with this value", not "skip". 覆盖 is the term used elsewhere in the file (e.g. "强制覆盖?" for "force overwrite") and is what the dialog label should read. Two strings touched: - "SSH_AUTH_SOCK override:" → "SSH_AUTH_SOCK 覆盖:" - "Optional path to override SSH_AUTH_SOCK..." → leading verb 覆盖 The "(auto-probe via gpgconf)" parenthetical was unaffected; left alone. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> * i18n(zh_CN): fill 5 SSH_AUTH_SOCK validation messages Best-effort Chinese translations for the validation strings introduced in #1439, kept type="unfinished" so Weblate can refine. Reuses the 覆盖 terminology established in PR #1441 for "override": - "The path does not exist." → "路径不存在。" - "The path is not readable." → "路径不可读。" - "The path is not a Unix domain socket." → "路径不是 Unix 域套接字。" - "Potentially invalid SSH_AUTH_SOCK override" → "SSH_AUTH_SOCK 覆盖值可能无效" - "The SSH_AUTH_SOCK override value may be invalid.\n\n%1\n\nThe value will still be saved as entered." → matching multi-line form, %1 placeholder preserved. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Reviewed every translation in the 31 locales sitting between 95% and 99.9% finished — all of them had non-empty <translation type="unfinished"> entries from earlier rounds (mostly the SSH_AUTH_SOCK + override-warn strings from #1438/#1439). Each translation preserves placeholders (%1) and source punctuation, matches established locale terminology (e.g. zh_CN/zh_Hant 覆盖/覆寫, sr_Cyrl/sr_RS надјачавање/nadjačavanje, ja 上書き), and reads naturally; promoted to "finished" by stripping type="unfinished". One small terminology fix on the way: - zh_CN: "Potentially invalid SSH_AUTH_SOCK override" was rendered "SSH_AUTH_SOCK 覆盖值可能无效" (= "SSH_AUTH_SOCK override value may be invalid"). Awkward as a dialog title — re-ordered to "可能无效的 SSH_AUTH_SOCK 覆盖" matching the natural Chinese pattern and the existing zh_Hant rendering ("可能無效的 SSH_AUTH_SOCK 覆寫"). Locales touched (31, all now 312/312 finished): cy, es_UY, et, fi, fr_BE, fr_LU, fy_NL, gl, hi, hr, hu, id, ja, ko, lb_LU, lt, lv, nl_BE, pa_IN, ro, si, sq, sr_Cyrl, sr_RS, sw, ta, te, uk, ur, zh_CN, zh_Hant. Out of scope (deliberately skipped per request): he, en_US, ru — sitting at 13.4% / 63.1% / 69.2% with hundreds of pre-existing untranslated entries that pre-date this PR's work. Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
…1469) The Settings dialog warning logic added in #1439 (configdialog.cpp on_accepted) had no unit tests. Extract the validation rules into a pure helper so they're testable without a Qt event loop or QMessageBox spy. Production change (mechanical, no semantic diff): - New Util::sshAuthSockOverrideStatus(QString) returning an enum: Valid / DoesNotExist / NotReadable / NotUnixDomainSocket. Same three checks as before (exists, readable, S_ISSOCK on Unix), now reusable and unit-testable. - ConfigDialog::on_accepted switches the three inline if/else branches to a switch over the enum. Translation strings stay in ConfigDialog (Util has no tr() callers). - Dropped now-unused #include <QFileInfo> and #include <sys/stat.h> from configdialog.cpp. Tests (tst_util.cpp): - sshAuthSockOverrideStatusDoesNotExist — non-existent path - sshAuthSockOverrideStatusRegularFileRejected — regular file (Unix) - sshAuthSockOverrideStatusNotReadable — chmod 0 (Unix; skipped under root since euid 0 ignores mode bits) - sshAuthSockOverrideStatusValid — bind(2) a real Unix domain socket and assert Valid POSIX socket(2)/bind(2) instead of QLocalServer to avoid pulling QtNetwork into the util test target. Unix-only tests SKIP on Windows where the production code also skips the socket check (ssh-agent uses a named pipe there). Build clean, 124/124 util tests pass (was 120, +4). Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Summary
Two reviewer findings on the SSH_AUTH_SOCK override (post-merge of #1438):
src/util.h— clarify that "no validation" applies to the runtime env-setup step, and note that the Settings dialog now does a soft check at save time.src/configdialog.cpp— when the user types a non-empty override and saves, soft-check the path before writing the setting:QFileInfo::exists()+isReadable()stat()+S_ISSOCKto confirm it's a Unix domain socket (Windows ssh-agent uses a named pipe — skipped there)QMessageBox::warningtells the user the path looks invalid and that the value will still be saved as entered.The runtime probe in
Util::initialiseSshAuthSock()is unchanged — it still uses the override verbatim, nossh-addvalidation. This preserves the "QtPass trusts the user choice" stance (e.g. agent started after QtPass launches) while giving immediate feedback on typos.Test plan
qmake6 && make -j4cleantests/auto/util/tst_util— 113 passed (no behavioural change to runtime probe; existinginitialiseSshAuthSockOverrideSkipsAgentValidationstill asserts the no-validation contract)doxygen Doxyfile— zero warningsclang-formatappliedlupdateran (4 newtr()strings: dialog title, 3 reasons, body template)🤖 Generated with Claude Code
Summary by CodeRabbit