You are not logged in.

#1 2012-04-24 18:58:43

mhh91
Member
From: Cairo,Egypt
Registered: 2009-05-14
Posts: 21

Has anyone used Packagekit-python here?

I'm trying to write a python script that interacts with PackageKit to do basic package management (install, remove, search, update), but I've run into this problem.

Here's the code I'm trying to execute

Python 2.7.3 (default, Apr 14 2012, 23:17:35) 
[GCC 4.7.0 20120407 (prerelease)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> from packagekit.client import PackageKitClient
>>> pk = PackageKitClient()
>>> pk.search_name('pacman')

And here's the error I'm getting

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/lib/python2.7/site-packages/packagekit/client.py", line 254, in search_details
    exit_handler)
  File "/usr/lib/python2.7/site-packages/packagekit/client.py", line 447, in _run_transaction
    return trans.run()
  File "/usr/lib/python2.7/site-packages/packagekit/client.py", line 162, in run
    polkit_auth_wrapper(self._method, *self._args)
  File "/usr/lib/python2.7/site-packages/packagekit/client.py", line 461, in polkit_auth_wrapper
    return fn(*args, **kwargs)
  File "/usr/lib/python2.7/site-packages/dbus/proxies.py", line 145, in __call__
    **keywords)
  File "/usr/lib/python2.7/site-packages/dbus/connection.py", line 651, in call_blocking
    message, timeout)
dbus.exceptions.DBusException: org.freedesktop.DBus.Error.UnknownMethod: Method "SearchDetails" with signature "ss" on interface "org.freedesktop.PackageKit.Transaction" doesn't exist

Is this a bug? or a problem with my code?

Offline

Board footer

Powered by FluxBB