Bug 509538 - Setting target language for the project has no effect (XFCE)
Summary: Setting target language for the project has no effect (XFCE)
Status: RESOLVED WORKSFORME
Alias: None
Product: lokalize
Classification: Applications
Component: project management (other bugs)
Version First Reported In: 25.08.0
Platform: Manjaro Linux
: NOR major
Target Milestone: ---
Assignee: Finley Watson
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2025-09-15 23:07 UTC by juliette.tux
Modified: 2025-09-21 10:27 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
same language in both fields (40.02 KB, image/png)
2025-09-15 23:07 UTC, juliette.tux
Details

Note You need to log in before you can comment on or make changes to this bug.
Description juliette.tux 2025-09-15 23:07:20 UTC
Created attachment 184968 [details]
same language in both fields

STEPS TO REPRODUCE
1. Choose target language from the dropdown menu in the project settings


OBSERVED RESULT
Language doesn't change

EXPECTED RESULT
Language is set correctly and the spellchecks work correctly

SOFTWARE/OS VERSIONS
DE: XFCE
Qt Version: 5.15.17

ADDITIONAL INFORMATION
Both valgrind and gdb show the same:
org.kde.lokalize: db "GNOME-networkmanager_lokalize_connection_452982464" opened 2600 "ru"
qt.sql.qsqldatabase: QSqlDatabasePrivate::database: requested database does not belong to the calling thread.
qt.sql.qsqldatabase: QSqlDatabasePrivate::removeDatabase: connection 'en_US-en_lokalize_connection_452982464' is still in use, all queries will cease to work.
qt.sql.qsqldatabase: QSqlDatabasePrivate::addDatabase: duplicate connection name 'en_US-en_lokalize_connection_452982464', old connection removed.
Comment 1 Finley Watson 2025-09-16 00:41:59 UTC
What version of Lokalize (is 25.08 correct)? Are you using it with Qt5 somehow? How did you install Lokalize?

This may be related to Sonnet since that text box and the language functionality is all Sonnet I think. We had an issue with Flatpak and dictionaries recently in Lokalize https://invent.kde.org/frameworks/sonnet/-/merge_requests/130 and there have also been some fixes to databases and threads a few months ago that may be relevant here.
Comment 2 juliette.tux 2025-09-20 13:55:43 UTC
Apologies for the long response, my computer died unexpectedly, had to replace the HW, but  the issue persists (same distro same software versions)
(In reply to Finley Watson from comment #1)
> What version of Lokalize (is 25.08 correct)? Are you using it with Qt5 somehow?
25.08 is correct, I'm using Qt5: QMake version 3.1 Using Qt version 5.15.17 in /usr/lib
>How did you install Lokalize?
default, through the pacman, not the flatpack

> https://invent.kde.org/frameworks/sonnet/-/merge_requests/130 
From what I've seen there my issue is a bit different: Lokalize cannot set the correct *target language* for the translated text field, the source language is set in both source and target field independently from whether the dictionaries are installed or not. The red spellchecks underscores are correct since the spellchecking works correctly -- it detects English-US in the field and underscores the Russian words. But Lokalize has to set *Russian* for this field, i.e. the target language, not English-US, that's the root of the problem.
Comment 3 juliette.tux 2025-09-20 14:25:13 UTC
The issue resolved by itself (for now at least), please close the bug, ty for your time (: