if currentSongURI:
    busType = Gio.BusType.SESSION
flags = 0
ratingInterface = None
proxy = Gio.DBusProxy.new_for_bus_sync(busType, flags, ratingInterface,
    'org.gnome.Rhythmbox3', '/org/gnome/Rhythmbox3/RhythmDB',
    'org.gnome.Rhythmbox3.RhythmDB', None)
variantRating = GLib.Variant('d', float(rating))
How can I set the rating of a song playing in Rhythmbox 2.96?