Bug 1259292 - 'Videos' is listed twice in Music/Video default applications
'Videos' is listed twice in Music/Video default applications
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: totem (Show other bugs)
x86_64 Linux
unspecified Severity low
: rc
: ---
Assigned To: Ray Strode [halfline]
Desktop QE
: 1259763 (view as bug list)
Depends On: 1235413
  Show dependency treegraph
Reported: 2015-09-02 07:35 EDT by Vadim Rutkovsky
Modified: 2015-11-19 03:43 EST (History)
6 users (show)

See Also:
Fixed In Version: gtk3-3.14.13-16.el7 totem-3.14.3-5.el7 gedit-3.14.3-8.el7 file-roller-3.14.2-6.el7 nautilus-3.14.3-6.el7
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2015-11-19 03:43:17 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)
Screenshot (224.00 KB, image/png)
2015-09-02 07:43 EDT, Vadim Rutkovsky
no flags Details

  None (edit)
Description Vadim Rutkovsky 2015-09-02 07:35:50 EDT
Description of problem:
'Videos' is listed twice in Default Application's Music and Video list

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1. Open Control Center
2. Open Details - Default Applications
3. Expand Music and Video list

Actual results:
'Videos' is listed twice

Expected results:
Each item in the list should be unique

Additional info:
Comment 1 Vadim Rutkovsky 2015-09-02 07:43:29 EDT
Created attachment 1069381 [details]
Comment 2 Bastien Nocera 2015-09-02 12:24:41 EDT
What's the output of:
gvfs-mime --query video/x-ogm+ogg

Is this a clean installation, or an upgrade?
Comment 3 Vadim Rutkovsky 2015-09-02 18:52:42 EDT
Clean install of RHEL-7.2-20150824.n.0 compose

[root@wlan-r2s30 ~]# gvfs-mime --query video/x-ogm+ogg
Default application for 'video/x-ogm+ogg': totem.desktop
Registered applications:
Recommended applications:

Both files are provided by totem-3.14.3-2.el7.x86_64
Comment 4 Bastien Nocera 2015-09-04 10:16:35 EDT
This is caused by:

commit c6c23140c939c52be137bd64ead1681a81de5292
Author: Ray Strode <rstrode@redhat.com>
Date:   Fri Jun 26 13:05:55 2015 -0400

    Add totem.desktop to keep user mime associates working
    Related: #1174589 123541

I'm not sure we want to have this...
Comment 5 Ray Strode [halfline] 2015-09-08 08:19:48 EDT
So the problem the duplicate file tries to solve is keeping user defined custom mime handlers working.  See bug 1235413 comment 5 part 2

I agree though a duplicate icon in the applications list isn't really acceptable. We also have duplicate icons in the notification list (see bug 1259763 ) 

I think maybe we need to drop the duplicate file an come at the custom mime handler problem a different way.
Comment 6 Matthias Clasen 2015-09-18 13:36:34 EDT
Also see bug See bug 1259763
Comment 7 Matthias Clasen 2015-09-21 14:19:36 EDT
I would suggest that we make the code populating the notification panel and the default mime handler combos respect the NoDisplay key. That should solve the problem, and is probably the right thing to do, regardless.
Comment 8 Ray Strode [halfline] 2015-09-21 15:01:11 EDT
So we can't actually filter on NoDisplay since the Notifications panel depends on being able to show entries with NoDisplay=true (for instance the sharing panel).

I guess we can filter out by duplicate name except that runs into problems when running under a translated desktop.  We'd have to side step GDesktopAppInfo and load the desktop file a second time into a keyfile to get the untranslated names.

We could add a new key X-GNOME-Compat-Entry=true or something and check for that, but then we have to touch all the compat desktop files again, and we have to touch all the code that looks at the files to support the new key.

We could also copy the compat map that gnome-shell has to glib and use it for the mime handlers, and then drop all the compat files, but it could be that there are other things using the old names we aren't specifically aware of yet.

not sure what the best way forward is.
Comment 9 Ray Strode [halfline] 2015-09-21 15:07:14 EDT
okay so i think the easiest way forward is to put

X-GNOME-UsesNotifications=false in all the compat files to hide them from the notifications list, and then fixes the details panel to filter out NoDisplay applications.
Comment 10 Ray Strode [halfline] 2015-09-23 09:48:22 EDT
grr, so apparently filtering out NoDisplay was tried 2 years ago and reverted:

Comment 11 Ray Strode [halfline] 2015-09-23 09:53:21 EDT
So at this point I'm going to go with a downstream patch to filter out X-GNOME-Compat-Entry=true lines
Comment 12 Tomas Pelka 2015-09-23 10:43:52 EDT
Is this a right component?
Comment 13 Ray Strode [halfline] 2015-09-23 10:50:30 EDT
totem is one of the components affected. to minimize paperwork i'm using this bug for all the components

(gtk+, totem, file-roller, nautilus, gedit)
Comment 14 Ray Strode [halfline] 2015-09-23 10:51:50 EDT
(to be clear, the main fix is in gtk+ but all the compat desktop entries need to be updated as per comment 9 and comment 11)
Comment 15 Ray Strode [halfline] 2015-09-23 12:03:51 EDT
okay should be all set now.

for the custom key I ended up going with X-RHEL-AliasOf=name-of-new-file instead of X-GNOME-Compat-Entry=true.  This is because of a limitation in the GDesktopAppInfo api that would have required me to load each file twice if I wanted to check the value of a new custom key, but I can use the api without reloading the file if all I want to do is check the existence of a new key.
Comment 18 Matthias Clasen 2015-09-28 12:57:00 EDT
*** Bug 1259763 has been marked as a duplicate of this bug. ***
Comment 19 Michael Boisvert 2015-09-30 15:06:58 EDT
"Videos" is no longer listed twice under Music or Video. Verified.
Comment 21 errata-xmlrpc 2015-11-19 03:43:17 EST
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.


Note You need to log in before you can comment on or make changes to this bug.