[packagekit] API change/clarification: RequireRestart

Richard Hughes hughsient at gmail.com
Thu Jan 15 06:52:49 PST 2009


At the moment the API type for the RequireRestart signal is "ss", i.e.
two strings. The first string is the enumerated type, but the second is
specified as "Optional details about the restart".

None of the front-end tools use this optional field, and there's only
one place in the post-trans hook in the daemon that sets it's to
anything other than NULL. Basically it's unused.

I propose we change the second parameter to be a PkPackageObj or a
PkPackageId so that we can display as a tooltip what package caused the
restart required signal. This allows users to either defer the decision,
or do the action based on real information. At the moment we don't tell
the user what package caused the signal to be emitted. Changing the use
won't change the signal type, and so won't break the bindings.

The obvious advantages of a PkPackageObj is that it gives us what the
package was doing (e.g. INSTALLING) and also a localised summary to
display in a tooltip. I don't really want to resolve a load of
package_id's just to get a tooltip that people probably won't read.

How does this sound?

Richard.





More information about the PackageKit mailing list