Bug 497561 - kreadconfig5 --file kscreenlockerrc --group Daemon --key Autolock/Timeout returns unexpected value
Summary: kreadconfig5 --file kscreenlockerrc --group Daemon --key Autolock/Timeout ret...
Status: RESOLVED DOWNSTREAM
Alias: None
Product: kscreenlocker
Classification: Plasma
Component: general (show other bugs)
Version: 5.24.7
Platform: Ubuntu Linux
: NOR normal
Target Milestone: ---
Assignee: Plasma Bugs List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-12-16 14:14 UTC by jordy.swiggers
Modified: 2024-12-16 17:53 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
screenshot (82.28 KB, image/png)
2024-12-16 14:14 UTC, jordy.swiggers
Details
attachment-3254922-0.html (1.93 KB, text/html)
2024-12-16 17:51 UTC, jordy.swiggers
Details
attachment-3255473-0.html (2.75 KB, text/html)
2024-12-16 17:53 UTC, jordy.swiggers
Details

Note You need to log in before you can comment on or make changes to this bug.
Description jordy.swiggers 2024-12-16 14:14:52 UTC
Created attachment 176679 [details]
screenshot

SUMMARY
kreadconfig5 --file kscreenlockerrc --group Daemon --key Autolock

Should return "true" when atuomatic screen locking is enabled but instead it returns null

STEPS TO REPRODUCE
1. enable auto screen locking in settings, delay 5 minutes
2. Konsole: kreadconfig5 --file kscreenlockerrc --group Daemon --key Autolock
3. Konsole: kreadconfig5 --file kscreenlockerrc --group Daemon --key Timeout

OBSERVED RESULT
value is null or empty, curiously when setting is disabled autolock returns "false" just fine

EXPECTED RESULT
value is true / 5

SOFTWARE/OS VERSIONS
Windows: 
macOS: 
(available in the Info Center app, or by running `kinfo` in a terminal window)
Linux/KDE Plasma: Kubuntu 22.04.5 LTS
KDE Plasma Version: 5.24.7
KDE Frameworks Version:  5.92.0
Qt Version: 5.15.3

ADDITIONAL INFORMATION
Comment 1 Bug Janitor Service 2024-12-16 14:33:37 UTC
Thank you for the bug report!

However Plasma 5.24.7 is no longer eligible for support or maintenance from KDE; supported versions are 5.27. (LTS), and 6.2 (non-LTS) or newer. Please upgrade to a supported version as soon as your distribution makes it available to you. Plasma is a fast-moving project, and bugs in one version are often fixed in the next one.

If you need support for Plasma 5.24.7, please contact your distribution, who bears the responsibility of providing support for older releases that are no longer supported by KDE.

If you can reproduce the issue after upgrading to a supported version, feel free to re-open this bug report.
Comment 2 Nicolas Fella 2024-12-16 17:33:41 UTC
This is working as designed. Only non-default values are written to the config file, so querying a value that is at the default will return nothing.
Comment 3 jordy.swiggers 2024-12-16 17:51:56 UTC
Created attachment 176682 [details]
attachment-3254922-0.html

Hi Nicolas,

First of all thank you for taking the time to reply.

The thing is that i have been using both commands in a custom Intune
compliancy script for several months, up until very recently they were most
definitely returning "true" and "5".

The whole script is based around the lock enabled being true and the lock
delay less than or equal to 10.

Kind regards, Jordy


On Mon, Dec 16, 2024, 18:33 Nicolas Fella <bugzilla_noreply@kde.org> wrote:

> https://bugs.kde.org/show_bug.cgi?id=497561
>
> Nicolas Fella <nicolas.fella@gmx.de> changed:
>
>            What    |Removed                     |Added
>
> ----------------------------------------------------------------------------
>                  CC|                            |nicolas.fella@gmx.de
>
> --- Comment #2 from Nicolas Fella <nicolas.fella@gmx.de> ---
> This is working as designed. Only non-default values are written to the
> config
> file, so querying a value that is at the default will return nothing.
>
> --
> You are receiving this mail because:
> You reported the bug.
Comment 4 jordy.swiggers 2024-12-16 17:53:55 UTC
Created attachment 176684 [details]
attachment-3255473-0.html

Also see this thread i posted back when i was first writing the script:

https://discuss.kde.org/t/qdbus-kreadconfig5-method-to-find-screen-lock-setting-status-and-lock-timer/18400/2

Kind regards

On Mon, Dec 16, 2024, 18:51 Jordy Swiggers <jordy.swiggers@gmail.com> wrote:

> Hi Nicolas,
>
> First of all thank you for taking the time to reply.
>
> The thing is that i have been using both commands in a custom Intune
> compliancy script for several months, up until very recently they were most
> definitely returning "true" and "5".
>
> The whole script is based around the lock enabled being true and the lock
> delay less than or equal to 10.
>
> Kind regards, Jordy
>
>
> On Mon, Dec 16, 2024, 18:33 Nicolas Fella <bugzilla_noreply@kde.org>
> wrote:
>
>> https://bugs.kde.org/show_bug.cgi?id=497561
>>
>> Nicolas Fella <nicolas.fella@gmx.de> changed:
>>
>>            What    |Removed                     |Added
>>
>> ----------------------------------------------------------------------------
>>                  CC|                            |nicolas.fella@gmx.de
>>
>> --- Comment #2 from Nicolas Fella <nicolas.fella@gmx.de> ---
>> This is working as designed. Only non-default values are written to the
>> config
>> file, so querying a value that is at the default will return nothing.
>>
>> --
>> You are receiving this mail because:
>> You reported the bug.
>
>