Bug 438932 - Offline updates still used, even though explicitly deactivated
Summary: Offline updates still used, even though explicitly deactivated
Status: REPORTED
Alias: None
Product: Discover
Classification: Applications
Component: Updates (offline) (show other bugs)
Version: 5.22.1
Platform: Other Other
: NOR normal
Target Milestone: ---
Assignee: Dan Leinir Turthra Jensen
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-06-20 00:00 UTC by Tobias G.
Modified: 2023-12-13 20:14 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tobias G. 2021-06-20 00:00:10 UTC
SUMMARY
Hey there, 
I'm using Kubuntu 21.04 with backports activated, so I get the newest version of Plasma. In Plasma 5.21 I was annoyed by the offline updates being applied when using automatic updates, but to solve that, Plasma 5.22 introduced a system settings option to deactivate offline updates, but still use automatic updates. 
So, I deactivated offline updates and kept automatic updates enabled. 
But it still happens sometimes that "a reboot is required to apply updates" and the updates are then applied during the reboot. 

I already tried to enable offline updates and deactivate them, but that didn't solve the issue. 

Is there a way to check, if offline updates are actually deactivated? 
Has anyone a clue, how this could happen? 
Or did I misunderstand something? 

Thanks in advance! 


STEPS TO REPRODUCE
1. Deactivate offline updates, activate automatic updates
2. Wait for available updates, let them being installed automatically 
3. Reboot, updates are sometimes applied during reboot

OBSERVED RESULT
Updates are applied during reboot

EXPECTED RESULT
Updates should not be applied during reboot

SOFTWARE/OS VERSIONS
Windows: 
macOS: 
Linux/KDE Plasma: 
(available in About System)
KDE Plasma Version: 
KDE Frameworks Version: 
Qt Version: 

ADDITIONAL INFORMATION
Comment 1 Aleix Pol 2021-07-06 14:48:27 UTC
Can you confirm that "kreadconfig5 --file discoverrc --group Software --key UseOfflineUpdates" returns false on your system?
Comment 2 Tobias G. 2021-07-06 14:53:00 UTC
(In reply to Aleix Pol from comment #1)
> Can you confirm that "kreadconfig5 --file discoverrc --group Software --key
> UseOfflineUpdates" returns false on your system?

I cannot confirm that, when I activate the offline option, it returns true. But when I deactivate it, it just returns nothing.
So that might be the issue I guess. :D
Comment 3 Aleix Pol 2021-07-06 15:22:25 UTC
Weeeird.

Can you see what's on the config file? "$ cat .config/discoverrc"

You should have something like:

[Software]
UseOfflineUpdates=false
Comment 4 Tobias G. 2021-07-06 15:24:40 UTC
(In reply to Aleix Pol from comment #3)
> Weeeird.
> 
> Can you see what's on the config file? "$ cat .config/discoverrc"
> 
> You should have something like:
> 
> [Software]
> UseOfflineUpdates=false

It shows me this when deactivated:
$ cat .config/discoverrc
[FlatpakSources]
Sources=flathub-beta,flathub

[Window]
geometry=2501,1006,933,597
visibility=2

when activated this:
$ cat .config/discoverrc
[FlatpakSources]
Sources=flathub-beta,flathub

[Software]
UseOfflineUpdates=true

[Window]
geometry=2501,1006,933,597
visibility=2

It is really strange that the entry just completely disappears, when deactivated, instead of being set to false.
Comment 5 Aleix Pol 2021-07-06 15:38:06 UTC
Can you check that your system isn't setting the PK_OFFLINE_UPDATE environment variable?
Comment 6 Tobias G. 2021-07-06 15:43:58 UTC
(In reply to Aleix Pol from comment #5)
> Can you check that your system isn't setting the PK_OFFLINE_UPDATE
> environment variable?

Checked it, using $ env | grep PK_OFFLINE_UPDATE
but no output, so that doesn't seem to be the case either.
Comment 7 Nate Graham 2021-07-30 16:43:18 UTC
The entry disappears when you turn it off because that's the default value; this is standard behavior for config files across all KDE software. I wonder if Kubuntu uses true as its own default such that having no value in the config file falls back to true and gives you offline updates again.

Can you try adding

[Software]
UseOfflineUpdates=false

to your config file and see if that works?
Comment 8 Tobias G. 2021-07-30 21:13:10 UTC
(In reply to Nate Graham from comment #7)
> The entry disappears when you turn it off because that's the default value;
> this is standard behavior for config files across all KDE software. I wonder
> if Kubuntu uses true as its own default such that having no value in the
> config file falls back to true and gives you offline updates again.
> 
> Can you try adding
> 
> [Software]
> UseOfflineUpdates=false
> 
> to your config file and see if that works?

I tried that, but it still used offline updates when it updated my system. :(

I really can't understand why now...
Comment 9 Nate Graham 2021-08-02 17:04:03 UTC
Well that's disturbing.