Bug 495301

Summary: setting TZ environment variable knackers digital clock widget
Product: [Plasma] plasmashell Reporter: lvm
Component: Digital Clock widgetAssignee: Plasma Bugs List <plasma-bugs-null>
Status: RESOLVED DOWNSTREAM    
Severity: normal    
Priority: NOR    
Version First Reported In: 5.18.8   
Target Milestone: 1.0   
Platform: Ubuntu   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:

Description lvm 2024-10-24 13:30:11 UTC
SUMMARY
If TZ environment variable is set at plasma startup, digital clock widget shows nothing at all and uses all available free space on the panel for local time ("Your system time zone" on the Time Zone tab of the Digital Clock settings), and treats local time as UTC when explicit time zone is selected on the Time Zone tab, i.e. selecting time zone UTC+1 shows local time +1hr. My KDE is ancient, but I found no similar bugs - open or closed.

STEPS TO REPRODUCE
1. set TZ=MSK-3 before starting plasma - I did it in /etc/environment
2. start plasma/reboot
3. add digital clock widget to a panel, ensure that it shows local time
4. switch to UTC+0 timezone

OBSERVED RESULT
3. clock uses all available space on the panel and is blank
4. clock shows local time, not GMT (assuming you are not in the UK - then they are the same)

EXPECTED RESULT
3. clock shows time and uses no more space than needed
4. clock shows GMT

SOFTWARE/OS VERSIONS
Linux/KDE Plasma:
KDE Plasma Version:  5.18.8
KDE Frameworks Version: 5.68.0
Qt Version: 5.12.8

ADDITIONAL INFORMATION
Comment 1 Bug Janitor Service 2024-10-24 13:33:37 UTC
Thank you for the bug report!

However Plasma 5.18.8 is no longer eligible for support or maintenance from KDE; supported versions are 5.27 (LTS), and 5.27 (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.18.8, 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.