FS#11886 - gtk cannot read image files

Attached to Project: Arch Linux
Opened by Thomas Hoernes (tyr0) - Sunday, 26 October 2008, 10:04 GMT
Last edited by Aaron Griffin (phrakture) - Wednesday, 19 November 2008, 21:09 GMT
Task Type Bug Report
Category Packages: Extra
Status Closed
Assigned To No-one
Architecture All
Severity High
Priority Normal
Reported Version None
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:
gtk cannot read image files anymore. Gtk application report unrecogniced image files. A lot of applications do not start (e.g. sonata, nitrogen, thunar, mirage, gdm with themes or even Gnome...), others (e.g. medit, geany) start without icons. The problem is discussed here: http://bbs.archlinux.org/viewtopic.php?id=57468
For example: Sonata produces this error: "glib.GError: Unrecognized image file format"
gdm, thunar, nitrogen or mirage complain about the image files in the same way.

Additional info:
* gtk2 2.14.4-1
* glib2 2.18.2-1


Steps to reproduce:
- Start one of the applications mentioned above.
This task depends upon

Closed by  Aaron Griffin (phrakture)
Wednesday, 19 November 2008, 21:09 GMT
Reason for closing:  Fixed
Comment by Jan de Groot (JGC) - Sunday, 26 October 2008, 10:24 GMT
I think your /etc/gtk-2.0/gdk-pixbuf.loaders is corrupted or unreadable. Try running these commands:
/usr/bin/gtk-query-immodules-2.0 > /etc/gtk-2.0/gtk.immodules
/usr/bin/gdk-pixbuf-query-loaders > /etc/gtk-2.0/gdk-pixbuf.loaders
Comment by Thomas Hoernes (tyr0) - Sunday, 26 October 2008, 10:43 GMT
Thank you for your answer, however, it didn't help.
Comment by Jan de Groot (JGC) - Sunday, 26 October 2008, 10:49 GMT
could you upload your /etc/gtk-2.0/gdk-pixbuf.loaders?
Comment by Thomas Hoernes (tyr0) - Sunday, 26 October 2008, 10:51 GMT
Here it is.
Comment by Jan de Groot (JGC) - Sunday, 26 October 2008, 11:06 GMT
Try deleting ~/.local/share/mime/mime.cache, the mime cache file format has changed with later versions of shared-mime-info.
If that doesn't fix your problems, try running this python script with strace and attach the log: (strace -o fs11886.log python fs11886.py)

#!/usr/bin/python
import pygtk
pygtk.require("2.0")
import gtk
import gtk.gdk
print gtk.gdk.pixbuf_new_from_file_at_size("/usr/share/pixmaps/gnome-talk.png", 32, 32)
Comment by Thomas Hoernes (tyr0) - Sunday, 26 October 2008, 11:22 GMT
strace produces this error:
╭─[thomas::Heraklit]
╰─[12:19]> strace -o fs11886.log python fs11886.py ~
Traceback (most recent call last):
File "fs11886.py", line 6, in <module>
print gtk.gdk.pixbuf_new_from_file_at_size("/usr/share/pixmaps/gnome-talk.png", 32, 32)
glib.GError: Format der Bilddatei unbekannt
The log is in the attachment.
   fs11886.log (207.3 KiB)
Comment by Jan de Groot (JGC) - Sunday, 26 October 2008, 12:20 GMT
Try this:
update-mime-database ~/.local/share/mime
Comment by Thomas Hoernes (tyr0) - Sunday, 26 October 2008, 12:44 GMT
Sorry, doesn't help.
Comment by Jan de Groot (JGC) - Monday, 27 October 2008, 08:07 GMT
Could you try to reinstall shared-mime-info? Someone on the list reported that works in his case.
Comment by Thomas Hoernes (tyr0) - Monday, 27 October 2008, 15:36 GMT
Didn't work, but thank you for your help. I've reinstalled the whole gtk stuff without any improvement.
Comment by Jan de Groot (JGC) - Thursday, 30 October 2008, 07:46 GMT
Could you tar the contents of ~/.local/share/mime and attach it to this bug? You could also try to remove that directory to see if it fixes your problem.
Comment by Thomas Hoernes (tyr0) - Thursday, 30 October 2008, 16:29 GMT
Removing the directory did not help. Here is the file.
   mime.tar (110 KiB)
Comment by Jan de Groot (JGC) - Wednesday, 05 November 2008, 08:10 GMT
What version of shared-mime-info do you have btw?
Comment by Slash Bunny (Slash) - Thursday, 06 November 2008, 00:31 GMT
This issue went away for me in a recent update (Oct 25th)- If you check the forum thread in the original post, I pasted my pacman.log from that update. It stands to reason that one of those packages may be involved. Don't know if that helps at all.
Comment by Thomas Hoernes (tyr0) - Thursday, 06 November 2008, 16:13 GMT
shared-mime-info 0.51-1 is installed. Thank you, slash. I've studied your log already, however, I can't find a solution.

Comment by Thomas Hoernes (tyr0) - Friday, 07 November 2008, 16:21 GMT
It's not a shared-mime-info problem. I've recompiled version 0.30 and the same error occurs.
Comment by Thomas Hoernes (tyr0) - Friday, 14 November 2008, 18:27 GMT
Try to export these lines:
export XDG_CONFIG_DIRS="/etc/xdg"export
export XDG_DATA_DIRS="/usr/share:/usr/local/share"
(solution by Alpheth. Thank you!)

Loading...