After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 324296 - Generalize Yelp's document detection to cope with new mimetype for DocBook
Generalize Yelp's document detection to cope with new mimetype for DocBook
Status: RESOLVED FIXED
Product: yelp
Classification: Applications
Component: General
2.13.x
Other Linux
: Immediate blocker
: ---
Assigned To: Yelp maintainers
Yelp maintainers
Depends on:
Blocks:
 
 
Reported: 2005-12-16 20:15 UTC by Dave Malcolm
Modified: 2005-12-20 22:58 UTC
See Also:
GNOME target: ---
GNOME version: 2.13/2.14


Attachments
Support alternate mimetypes for DocBook (564 bytes, patch)
2005-12-16 20:17 UTC, Dave Malcolm
committed Details | Review

Description Dave Malcolm 2005-12-16 20:15:17 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...
Comment 1 Dave Malcolm 2005-12-16 20:17:59 UTC
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)
Comment 2 Brent Smith (smitten) 2005-12-17 03:38:50 UTC
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.
Comment 3 Brent Smith (smitten) 2005-12-17 06:35:14 UTC
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.
Comment 4 Dave Malcolm 2005-12-19 21:00:48 UTC
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
Comment 5 Brent Smith (smitten) 2005-12-20 01:25:11 UTC
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...
Comment 6 Dave Malcolm 2005-12-20 22:58:09 UTC
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)