Bug 630931 - kpackagekit: malformed D-Bus introspection data
Summary: kpackagekit: malformed D-Bus introspection data
Keywords:
Status: CLOSED NEXTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: kpackagekit
Version: 14
Hardware: i686
OS: Linux
low
medium
Target Milestone: ---
Assignee: Steven M. Parrish
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: abrt_hash:7f76d4ce
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2010-09-07 12:19 UTC by Alexander Kurtakov
Modified: 2011-09-01 07:15 UTC (History)
9 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2011-09-01 07:15:24 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
File: backtrace (18.84 KB, text/plain)
2010-09-07 12:19 UTC, Alexander Kurtakov
no flags Details
Introspection file from gnome-packagekit (3.38 KB, application/octet-stream)
2010-09-13 12:03 UTC, Jirka Klimes
no flags Details
Introspection file from kpackagekit (17.24 KB, text/plain)
2010-09-13 12:04 UTC, Jirka Klimes
no flags Details

Description Alexander Kurtakov 2010-09-07 12:19:04 UTC
abrt version: 1.1.13
architecture: i686
Attached file: backtrace
cmdline: /usr/bin/python /usr/bin/d-feet
component: d-feet
executable: /usr/bin/d-feet
kernel: 2.6.33.8-149.fc13.i686
package: d-feet-0.1.12-1.fc13
reason: _introspect_parser.py:150:process_introspection_data:IntrospectionParserException: Error parsing introspect data: <class 'xml.parsers.expat.ExpatError'>: unbound prefix: line 5, column 4
release: Fedora release 13 (Goddard)
time: 1283861679
uid: 500

How to reproduce
-----
1. Start d-feet
2. Filter org.freedesktop.PackageKit in the session bus
3. Notice that /org/freedesktop/PackageKit object is missing because it is failing to parse

Comment 1 Alexander Kurtakov 2010-09-07 12:19:09 UTC
Created an attachment (id=443495)
File: backtrace

Comment 2 John (J5) Palmieri 2010-09-07 19:10:44 UTC
Sounds like a PackageKit error.  I don't have any PackageKit service, only PackageKit.Application and PackageKit.UpdateIcon in my session.  On my system bus I do get a PackageKit service.  No error occur in parsing the introspect data.

Comment 3 Jirka Klimes 2010-09-10 09:57:12 UTC
Package: d-feet-0.1.12-1.fc13
Architecture: x86_64
OS Release: Fedora release 13 (Goddard)


Comment
-----
Doesn't have exact steps. Just clicking on bus names on Session Bus.

Comment 4 Alexander Kurtakov 2010-09-10 10:01:30 UTC
This seems to happen to me only under kde with kpackagekit.

Comment 5 Jirka Klimes 2010-09-13 12:01:47 UTC
I can confirm that it has something to do with kpackagekit.
It seems to be a bug in kpackagekitsmarticon that provides 'org.freedesktop.PackageKit' service.
However, it returns bad introspection file that expat fails to parse (doc namespace) - probably missing namespace definition:
<node name="/" xmlns:doc="http://www.freedesktop.org/dbus/1.0/doc.dtd">

gnome-packagekit provides clean introspection, though.

See introspection files generated by:
qdbus --session org.freedesktop.PackageKit /org/freedesktop/PackageKit org.freedesktop.DBus.Introspectable.Introspect

both for gnome-packagekit (gpk-dbus-service) and kpackagekit (kpackagekitsmarticon).

Comment 6 Jirka Klimes 2010-09-13 12:03:16 UTC
Created attachment 446902 [details]
Introspection file from gnome-packagekit

Comment 7 Jirka Klimes 2010-09-13 12:04:28 UTC
Created attachment 446903 [details]
Introspection file from kpackagekit

Comment 8 John (J5) Palmieri 2010-09-13 18:31:53 UTC
Seems like a namespace issue.  This should be filed upstream with kpackagekit unless it crashes D-Feet.  Does it it cause D-Feet to stop working or does D-Feet just continue without showing introspection data for kpackagekit?

Comment 9 Jirka Klimes 2010-09-20 08:35:23 UTC
D-Feet continues to work normally. The only issue is that abrt catches the error (from comment #1) and indicates a crash and kpackagekit data are not available, of course.

I checked kpackagekit upstream and the namespace definition is there:
http://websvn.kde.org/trunk/playground/sysadmin/kpackagekit/SmartIcon/org.freedesktop.PackageKit.xml?revision=1055286&view=markup
I hope it will get to Fedora soon.

Comment 10 John (J5) Palmieri 2010-09-20 14:48:20 UTC
Reassigning to kpackagekit.  Fix is upstream.  Please patch or upgrade kpackagekit in Fedora 13

Comment 11 Kevin Kofler 2010-09-20 15:08:29 UTC
That commit is 9 months old and already in the 0.6.0 release we're shipping in F13, so it cannot be the fix. (And by the way, 0.6.1 is already queued for testing.)

Comment 12 Kevin Kofler 2010-09-20 15:09:22 UTC
(It's already in testing and sitting there for a week, actually. But there's nothing that changed with respect to that XML file between 0.6.0 and 0.6.1.)

Comment 13 Jirka Klimes 2010-09-21 13:08:46 UTC
I've tested kpackagekit-0.6.1-1.fc13.x86_64. There is no change against kpackagekit-0.6.0-2.fc13.x86_64 in respect to the introspection.

qdbus org.freedesktop.PackageKit /org/freedesktop/PackageKit Introspect
produces the same output as in comment #7.
Note there is <node> tag without arguments (name and xmlns:doc namespace)

It is probably a bug in qdbusxml2cpp (or some other component), because qdbusxml2cpp generates adaptor class that *doesn't* have any <node> tag in introspection data. Then an empty <node> is included when introspection is required.

Comment 14 Alexander Kurtakov 2010-12-08 14:40:34 UTC
Problem is still here on F-14.

Comment 15 Håkon Løvdal 2011-05-22 04:49:16 UTC
This is still the case with kpackagekit-0.6.3.3-1.fc14.x86_64. The following was what I had drafted and intended to put up as a  new bug,  but then I found that it already were reported here:


Trying to add an network ipp printer with system-config-printer fails.

Server -> New -> Printer, fill inn hostname and path. Pressing the Verify button results in "This print share is accessible."

So far everything is working ok. But when pressing Forward, KPackageKit starts searching for a driver but fails shortly after with "Could not find printer driver in any configured software source" and on standard output the following is printed:

ERROR:dbus.proxies:Introspect error on :1.31:/org/freedesktop/PackageKit: dbus.exceptions.IntrospectionParserException: Error parsing introspect data: <class 'xml.parsers.expat.ExpatError'>: unbound prefix: line 5, column 4


Debugging with strace and capturing all strings I can assemble the whole XML content (attached as dbus-communication.xml.orig), the first 10 lines are

<!DOCTYPE node PUBLIC "-//freedesktop//DTD D-BUS Object Introspection 1.0//EN"
"http://www.freedesktop.org/standards/dbus/1.0/introspect.dtd">
<node>
  <interface name="org.freedesktop.PackageKit.Modify">
    <doc:doc>
      <doc:description>
        <doc:para>
          The interface used for modifying the package database.
        </doc:para>
      </doc:description>

Running xmllint on this file, it complains about all the "doc:" prefixes.

dbus-communication.xml.orig:5: namespace error : Namespace prefix doc on doc is not defined
    <doc:doc>
            ^

And while searching around I find that it seems that the name space should have been present, like

-<node>
+<node xmlns:doc="http://www.freedesktop.org/dbus/1.0/doc.dtd">

and with this change xmllint is happy.

I tried to find out where and how to add but I am now giving up trying to fix it myself and instead report it.

Comment 16 Alexander Kurtakov 2011-09-01 07:15:24 UTC
Works fine with kpackagekit-0.6.3.3-2.fc15.
Closing.


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