Well, the "dbus" trick didn't make it either.
I tried with the following script:
-------------------------------------------
import dbus, traceback
bus = dbus.SystemBus()
mgr = bus.get_object('org.freedesktop.ConsoleKit', '/org/freedesktop/ConsoleKit/Manager')
for seat_name in mgr.GetSeats():
seat = bus.get_object('org.freedesktop.ConsoleKit', seat_name)
for session_name in seat.GetSessions():
session = bus.get_object('org.freedesktop.ConsoleKit', session_name)
if session.is_local:
print "### Session '%s':" % (session.GetId(),)
try: session.Activate()
except: traceback.print_exc()
-------------------------------------------
and all tells me is (ran with sudo):
### Session '/org/freedesktop/ConsoleKit/Session2':
Traceback (most recent call last):
File "./x.py", line 15, in <module>
session.Activate()
File "/usr/lib/pymodules/python2.6/dbus/proxies.py", line 140, in __call__
**keywords)
File "/usr/lib/pymodules/python2.6/dbus/connection.py", line 620, in call_blocking
message, timeout)
DBusException: org.freedesktop.DBus.GLib.UnmappedError.CkSeatError.Code0: Activation is not supported for this kind of seat
Well, the "dbus" trick didn't make it either. ------- ------- ------- ------- ------- -
I tried with the following script:
-------
import dbus, traceback
bus = dbus.SystemBus() object( 'org.freedeskto p.ConsoleKit' ,
'/org/ freedesktop/ ConsoleKit/ Manager' ) object( 'org.freedeskto p.ConsoleKit' ,
seat_ name) object( 'org.freedeskto p.ConsoleKit' ,
session_ name)
session. Activate( )
traceback. print_exc( ) ------- ------- ------- ------- ------- -
mgr = bus.get_
for seat_name in mgr.GetSeats():
seat = bus.get_
for session_name in seat.GetSessions():
session = bus.get_
if session.is_local:
print "### Session '%s':" % (session.GetId(),)
try:
except:
-------
and all tells me is (ran with sudo): op/ConsoleKit/ Session2' : Activate( ) pymodules/ python2. 6/dbus/ proxies. py", line 140, in __call__ pymodules/ python2. 6/dbus/ connection. py", line 620, in call_blocking .DBus.GLib. UnmappedError. CkSeatError. Code0: Activation is not supported for this kind of seat
### Session '/org/freedeskt
Traceback (most recent call last):
File "./x.py", line 15, in <module>
session.
File "/usr/lib/
**keywords)
File "/usr/lib/
message, timeout)
DBusException: org.freedesktop
What is the "kind" of seat am I sitting on ?!???