Bug 427015 - file-type associations not remembered
Summary: file-type associations not remembered
Status: REPORTED
Alias: None
Product: krusader
Classification: Applications
Component: general (show other bugs)
Version: 2.7.2
Platform: FreeBSD Ports FreeBSD
: NOR normal
Target Milestone: ---
Assignee: Krusader Bugs Distribution List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-09-27 08:09 UTC by Friedrich Volkmann
Modified: 2020-10-21 21:37 UTC (History)
2 users (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Friedrich Volkmann 2020-09-27 08:09:45 UTC
SUMMARY
File-type associations are defunct.

STEPS TO REPRODUCE, OBSERVED RESULT
1) When I double-click a JPG in the file list, the "open with..." dialog opens. Then I specify a graphics viewer (either just the command name or the full path, doesn't seem to matter) and click the checkbox to always use that association. The JPG is then indeed opened with that graphics viewer, but the next time I click a JPG (even if it is the same file) the dialog appears again and asks me for an associated program. It doesn't even present the previously selected program as a default.

2) When I right-click the file, select the "settings" context menu entry, and click the button for the file-type settings, nothing happens.

EXPECTED RESULT
1) After associating a program and checking the checkbox, the file should either be opened automatically with that program the next time I double-click it, or at least the file-open dialog should default to the selected program henceforth, so I can can just hit the enter key or click the default button. 

2) When I click the button for the file-type settings, a settings window should open, with either the file type and selectable actions for that file, or a list of all file types, with the chosen file type pre-selected.

3) If something goes wrong (e.g. some KDE component is missing or returns an error), a descriptive error message should appear.

SOFTWARE/OS VERSIONS
Windows: -
macOS: -
Linux/KDE Plasma: -
(available in About System)
KDE Plasma Version: -
KDE Frameworks Version: -
Qt Version: 5

ADDITIONAL INFORMATION
1) I'm using Krusader as a standalone application, without most of the other KDE components (apart from those that are automatically started with Krusader, I guess).

2) Console output on Krusader start:
QCoreApplication::applicationDirPath: Please instantiate the QApplication object first
09:33:43.964-debug default unknown@0 # System icon theme: "hicolor"
09:33:44.207-warning default unknown@0 # QWidget::insertAction: Attempt to insert null action
09:33:44.209-warning default unknown@0 # QWidget::insertAction: Attempt to insert null action
QKqueueFileSystemWatcherEngine::addPaths: open: No such file or directory
09:33:44.495-warning default unknown@0 # virtual QStringList Solid::Backends::Hal::HalManager::allDevices()  error:  "org.freedesktop.DBus.Error.Disconnected" 

09:33:44.496-warning default unknown@0 # virtual QStringList Solid::Backends::Hal::HalManager::allDevices()  error:  "org.freedesktop.DBus.Error.Disconnected" 

09:33:44.496-warning default unknown@0 # virtual QStringList Solid::Backends::Hal::HalManager::allDevices()  error:  "org.freedesktop.DBus.Error.Disconnected" 

09:33:44.496-warning default unknown@0 # virtual QStringList Solid::Backends::Hal::HalManager::allDevices()  error:  "org.freedesktop.DBus.Error.Disconnected" 

09:33:44.496-warning org.kde.solid.udisks2 unknown@0 # Failed enumerating UDisks2 objects: "org.freedesktop.DBus.Error.Disconnected" 
 "Not connected to D-Bus server"
09:33:44.496-warning org.kde.solid.udisks2 unknown@0 # Failed enumerating UDisks2 objects: "org.freedesktop.DBus.Error.Disconnected" 
 "Not connected to D-Bus server"
09:33:44.496-warning org.kde.solid.udisks2 unknown@0 # Failed enumerating UDisks2 objects: "org.freedesktop.DBus.Error.Disconnected" 
 "Not connected to D-Bus server"
09:33:44.496-warning org.kde.solid.udisks2 unknown@0 # Failed enumerating UDisks2 objects: "org.freedesktop.DBus.Error.Disconnected" 
 "Not connected to D-Bus server"
09:33:44.496-warning org.kde.solid.udisks2 unknown@0 # Failed enumerating UDisks2 objects: "org.freedesktop.DBus.Error.Disconnected" 
 "Not connected to D-Bus server"
09:33:44.496-warning org.kde.solid.udisks2 unknown@0 # Failed enumerating UDisks2 objects: "org.freedesktop.DBus.Error.Disconnected" 
 "Not connected to D-Bus server"
09:33:44.496-warning org.kde.solid.udisks2 unknown@0 # Failed enumerating UDisks2 objects: "org.freedesktop.DBus.Error.Disconnected" 
 "Not connected to D-Bus server"
09:33:44.496-warning org.kde.solid.udisks2 unknown@0 # Failed enumerating UDisks2 objects: "org.freedesktop.DBus.Error.Disconnected" 
 "Not connected to D-Bus server"
09:33:44.497-warning default unknown@0 # virtual QStringList Solid::Backends::Hal::HalManager::allDevices()  error:  "org.freedesktop.DBus.Error.Disconnected" 

09:33:44.497-warning default unknown@0 # virtual QStringList Solid::Backends::Hal::HalManager::allDevices()  error:  "org.freedesktop.DBus.Error.Disconnected" 

09:33:44.497-warning default unknown@0 # virtual QStringList Solid::Backends::Hal::HalManager::allDevices()  error:  "org.freedesktop.DBus.Error.Disconnected"

09:33:44.497-warning default unknown@0 # virtual QStringList Solid::Backends::Hal::HalManager::allDevices()  error:  "org.freedesktop.DBus.Error.Disconnected" 

09:33:44.497-warning org.kde.solid.udisks2 unknown@0 # Failed enumerating UDisks2 objects: "org.freedesktop.DBus.Error.Disconnected" 
 "Not connected to D-Bus server"
09:33:44.497-warning org.kde.solid.udisks2 unknown@0 # Failed enumerating UDisks2 objects: "org.freedesktop.DBus.Error.Disconnected" 
 "Not connected to D-Bus server"
09:33:44.497-warning org.kde.solid.udisks2 unknown@0 # Failed enumerating UDisks2 objects: "org.freedesktop.DBus.Error.Disconnected" 
 "Not connected to D-Bus server"
09:33:44.497-warning org.kde.solid.udisks2 unknown@0 # Failed enumerating UDisks2 objects: "org.freedesktop.DBus.Error.Disconnected" 
 "Not connected to D-Bus server"
09:33:44.497-warning org.kde.solid.udisks2 unknown@0 # Failed enumerating UDisks2 objects: "org.freedesktop.DBus.Error.Disconnected" 
 "Not connected to D-Bus server"
09:33:44.497-warning org.kde.solid.udisks2 unknown@0 # Failed enumerating UDisks2 objects: "org.freedesktop.DBus.Error.Disconnected" 
 "Not connected to D-Bus server"
09:33:44.497-warning org.kde.solid.udisks2 unknown@0 # Failed enumerating UDisks2 objects: "org.freedesktop.DBus.Error.Disconnected" 
 "Not connected to D-Bus server"
09:33:44.497-warning org.kde.solid.udisks2 unknown@0 # Failed enumerating UDisks2 objects: "org.freedesktop.DBus.Error.Disconnected" 
 "Not connected to D-Bus server"
09:33:44.544-warning default unknown@0 # virtual QStringList Solid::Backends::Hal::HalManager::allDevices()  error:  "org.freedesktop.DBus.Error.Disconnected" 

09:33:44.544-warning org.kde.solid.udisks2 unknown@0 # Failed enumerating UDisks2 objects: "org.freedesktop.DBus.Error.Disconnected" 
 "Not connected to D-Bus server"
09:33:44.544-warning org.kde.solid.udisks2 unknown@0 # Failed enumerating UDisks2 objects: "org.freedesktop.DBus.Error.Disconnected" 
 "Not connected to D-Bus server"
09:33:44.564-warning default unknown@0 # virtual QStringList Solid::Backends::Hal::HalManager::allDevices()  error:  "org.freedesktop.DBus.Error.Disconnected" 

09:33:44.564-warning org.kde.solid.udisks2 unknown@0 # Failed enumerating UDisks2 objects: "org.freedesktop.DBus.Error.Disconnected" 
 "Not connected to D-Bus server"
09:33:44.564-warning org.kde.solid.udisks2 unknown@0 # Failed enumerating UDisks2 objects: "org.freedesktop.DBus.Error.Disconnected" 
 "Not connected to D-Bus server"
Comment 1 Davide Gianforte 2020-10-07 06:31:13 UTC
KDE uses ~/.config/mimeapps.list to store this configuration, you can check the file to see if the association exists (mime type for .jpg files is image/jpeg).

You can set association even through the file properties (default: Alt+Return) - File Type Options.

Both this ways are managed by external KDE packages; while you have installed minimum required packages to run Krusader, there could be other packages to install.
Comment 2 Friedrich Volkmann 2020-10-21 21:37:11 UTC
(In reply to Davide Gianforte from comment #1)
> KDE uses ~/.config/mimeapps.list to store this configuration, you can check
> the file to see if the association exists (mime type for .jpg files is
> image/jpeg).
It exists:
image/jpeg=xv-6.desktop;qiv-4.desktop;qiv-3.desktop;qiv-2.desktop;qiv.desktop;xv-5.desktop;xv-4.desktop;xv-3.desktop;xv-2.desktop;xv.desktop;mirage.desktop;

And the first value does change when I select another default app. But it is ignored the next time I open a JPG, even if I restart Krusader in between.

I also don't see why ".desktop" is appended to all of the commands.

> You can set association even through the file properties (default:
> Alt+Return) - File Type Options.
Same result as when reaching that dialog via the context menu. The button doesn't work.

> Both this ways are managed by external KDE packages; while you have
> installed minimum required packages to run Krusader, there could be other
> packages to install.
Most certainly. Anyway, an error message should show up, indicating what is missing, or what went wrong.