GNOME Bugzilla – Bug 324296
Generalize Yelp's document detection to cope with new mimetype for DocBook
Last modified: 2005-12-20 22:58:09 UTC
Adapted from this bug report: https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=175880 Yelp seemed to be totally broken; any attempt to open an xml help file fails Version-Release number of selected component (if applicable): yelp-2.13.2-1 on Fedora (rawhide) mozilla-1.7.12-2 How reproducible: 100% Steps to Reproduce: 1. Click on Desktop/System menu -> Help, or run "yelp" from terminal 2. See "Help Topics", click on e.g. Desktop 3. Mouseover "User Guide", then click it. Actual results: mouseover shows a local URL of an xml file, of the form "file:/usr/share/blah/blah/blah.xml" Clicking on it brings up an error dialog: bold text "An unknown error occured" extra text: "There is no default action associated with this location." Expected results: It should open the help file. Turned out to be a mimetype problem... nautilus is reporting it as "application/docbook+xml", but inside yelp, gnome_vfs_get_mime_type is reporting it as "application/xml". (slow vs fast mime sniffing?) I'm about to attach a patch that enables yelp to survive either...
Created attachment 56081 [details] [review] Support alternate mimetypes for DocBook According to: http://www.docbook.org/specs/wd-docbook-docbook-4.5b1.html#a.mimetype the mimetype ought to be "application/docbook+xml". (In any case, it's useful to be able to cope with somewhat broken mime databases)
Very strange. Did something in gnome-vfs or some other module change lately that would cause this to happen? I did get one report about this happening, but it was never a problem before.. I will take a look at the patch ASAP.
Something changed in either gnome-vfs or shared-mime-info which changed the mime type returned by the gnome-vfs calls... Applied the patch and tested. Fixes the issue for me... Thanks for the patch - committed.
This change in the shared-mime-info database may have caused this: http://cvs.freedesktop.org/mime/shared-mime-info/freedesktop.org.xml.in?r1=1.67&r2=1.68
Yeah, I saw that.. Hard to imagine that bug has gone unnoticed since Aug 9th though. I guess if you didn't install a new shared-mime-info since then...
AFAIK the last shared-mime-info tarball release was 0.16, sometime around April 2005 (ages ago...) so you'd only see this bug if you were running jhbuild or a distribution shipping a CVS snapshot or similar (I'm running Fedora development builds, and we're shipping CVS snapshots)