KPackageKit Progress

Over the past week or so, Daniel and I have been hacking on improving KPackageKit. Our original goal was to get it into the 4.2 release. Doing this depended on getting PolicyKit-KDE into base before release time, but that didn’t happen either. But hey, now we’ve got a few months to do tons more improvement.

The biggest change was how the automatic updates are handled. Previously, kded ran kpackagekit --smart-update once a day to check PackageKit if there were any interesting updates. Then it’d show a notification about it and ask the user if they want to upgrade. Now, I’ve moved that chunk into our transaction list icon. kded now calls kpackagekit-smart-icon --update to check for updates. The interval is configurable.

KPackageKit's 'updates available' icon in the plasma tray

KPackageKit's 'updates available' icon in the plasma tray


Once updates are found, a notification is displayed and an ‘updates available’ icon is added to the tray. If any security updates are available, it shows the security icon. If bugfixes are the highest priority available, the bugfix icon is shown, etc. The picture here shows bugfixes in my tray.

Clicking it immediately shows the update KCModule. The module is in the icon app, so loading is lightning fast. An optimization we might do is to go directly from the get-updates transaction and into the KCM’s model. Otherwise, the KCM has to re-fetch the same list we showed in the notification.

By default, all updates are selected and the apply button is enabled. We’re currently discussing some UI tweaks to this that might make it look a bit like this:

A slightly tweaked updater UI

A slightly tweaked updater UI

Icons are added, and the interaction is changed a little. Instead of everything being selected by default, thats all been replaced with a ‘apply all updates’ button. Its still one-click to update everything, but now its also one-click to close the dialog and not have systemsettings ask if you want to save your changes. Of course, if you really want to select everything and click Apply, its at most 3 clicks. Complaining against that will be a federal offense.

The other really important feature I finished was installing unsigned local files. Now I can install Cedega with only one click! There currently is a bug in the released PackageKit yum backend that prevents local files not existing in a repository from being installed, but there’s a patch I wrote getting pushed to git soon.

The last feature I added was reporting all errors with the tray icon. Now when your automatic updates fail, you’ll know why. Once we get the dbus interfaces implemented, we’ll be adding a little bit of code to the icon to only show messages for transactions that don’t have a dialog associated with them.

Oh yeah, and I start my spring semester at Akron tomorrow :)

Leave a Reply