Re: On updates
- From: Richard Hughes <hughsient gmail com>
- To: Joaquim Rocha <jrocha endlessm com>
- Cc: gnome-software-list gnome org
- Subject: Re: On updates
- Date: Mon, 22 Jan 2018 21:14:52 +0000
On 16 January 2018 at 11:14, Joaquim Rocha <
jrocha endlessm com> wrote:
> The information I have is that most of Endless' users have some sort of
> connectivity, but it is unstable and metered or very limited. So they're
> very conscious about it's used.
So in this case you'd just default to "automatic downloads and updates" being turned off? I can see a way forward, and we'd be moving from what we have now, which is two modes:
* download automatically, deploy manually
* download manually, deploy manually
which is achieved using:
refresh(METADATA) -> download new metadata
refresh(PAYLOAD) -> download but not deploy components (where the PAYLOAD bit is set by the gsetting)
get_updates() -> gets the updates ready to be deployed
get_updates_pending() -> gets the updates not yet downloaded or deployed (where the method is chosen using the gsetting)
update(app) -> deploy the previously downloaded app
to something that can support:
* download automatically, deploy automatically
* download manually, deploy manually
which would be achieved by:
refresh() -> download new metadata
get_updates() -> gets the updates that are not downloaded or deployed
update(app) -> download and deploy the previously downloaded app
Assuming the auto-updates setting is TRUE, in the update monitor rather than calling refresh(PAYLOAD) we'd be calling get_updates(), and feeding that into update(app). The only slight fly in the ointment is that the update vfunc needs to know if the update() is being called interactively (i.e. with a button press) or noninteractively (i.e. from the update_monitor. I don't know if a different vfunc is a good idea here.
We'd still get update progress if we stumbled on the GsApp in the installed, details or update panel, and we'd still be able to cancel the download/deploy action using the GsApp-specific cancellable.
This allows us to delete get_updates_pending, GsPluginRefreshFlags and a whole ton of code in gs-flatpak.c. It also means we can close a few dozen bugs of the kind "gnome-software doesn't show any updates when pkcon does" where the updates are waiting to be downloaded.
For non-live-deployable updates (like PackageKit OS updates) we'd simply download the apps during update() and set them to be deployed on next boot.
Richard
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]