time-admin: User-selected time zone will not stick (for some locations)

Bug #16285 reported by Ivan Jekic
18
This bug affects 1 person
Affects Status Importance Assigned to Milestone
GST
Invalid
Unknown
gnome-system-tools (Ubuntu)
Confirmed
Low
Ubuntu Desktop Bugs
system-tools-backends (Ubuntu)
New
Undecided
Unassigned

Bug Description

Everytime I set my timezone Europe/Belgrade, click "ok" and return to the settings, "Europe/Sarajevo" shows instead.
I tried with different cities - Zagreb, Ljubljana, Skopje - they all disappear after window closes and Europe/Sarajevo returns.

Original reporter said "This happens for Ex-Yugoslav republics only" but there are examples of other locations with similar problems in the comments.

Ubuntu is 5.04 final.

Revision history for this message
Sebastien Bacher (seb128) wrote :

what application are you using?

Revision history for this message
Daniel Robitaille (robitaille) wrote :

No answer from initial reporter in a long time. I'll close this bug report for now. Please feel free to re-open it if you are still experiencing this problem.

If you do please answer the question of Sebastien Bacher in a previous comment of this report ("what application are you using?"). Thanks.

Revision history for this message
Ivan Jekic (the-edge) wrote :

I think applications here are not so important, because it happens just after the installation of Ubuntu (fresh install) and remains later. I'm using Breezy now and the bug is still present.

Revision history for this message
Carthik Sharma (carthik) wrote :

On an updated Dapper install, I can observe the same behavior. Setting the timezone to Europe/Belgrade does not stick. The next time I open the Adjust Date & Time option in the clock on the desktop, the TimeZone is set to Europe/Sarajevo.

Confirming.

Revision history for this message
DSmidge (dsmidge1) wrote :

Setting TimeZone to Ljubljana in "Gnome desktop, System menu, Time and Date" is ignored and sets it to Sarajevo.
I'm using 6.10 desktop.

Revision history for this message
Mark Fraser (launchpad-mfraz) wrote :

I'm having a similar problem here in England and Kubuntu 7.04. Even though /etc/timezone shows Europe/London, System Settings:Date & Time shows my local timezone as Europe/Guernsey (BST). Going into admin mode and changing it has no effect.

Revision history for this message
Pascal De Vuyst (pascal-devuyst) wrote :

This bug did not have a package associated with it, which is important for ensuring that it gets looked at by the proper developers. You can learn more about finding the right package at [WWW] https://wiki.ubuntu.com/Bugs/FindRightPackage. I have classified this bug as a bug in gnome-system-tools.

Revision history for this message
era (era) wrote :

A very similar bug was fixed in the Clock applet a while back http://bugzilla.gnome.org/show_bug.cgi?id=519823 -- basically, the code would guess your location based on latitude and longitude, and map to a fairly random location from its database.

I'm guessing a similar fix should be applied for the time-admin component (and/or down the line, this sort of logic should be centralized into a single module or library).

description: updated
summary: - Wrong timezone location for ex-YU Europe countries in Time & Date
- settings
+ time-admin: User-selected time zone will not stick (for some locations)
Changed in gst:
status: Unknown → New
Revision history for this message
era (era) wrote :

I was able to reproduce that Europe/Belgrade, Europe/Ljubljana, Europe/Skopje, and Europe/Zagreb get mapped to Europe/Sarajevo, but was unable to get any discrepancy for Europe/London (also since Mark Fraser is using Kubuntu, his is bound to be a different problem). This was on Jaunty 9.04.

Revision history for this message
era (era) wrote :

In http://git.gnome.org./cgit/gnome-system-tools/tree/src/time/time-tool.c the function oobs_time_config_get_timezone is used to populate the GUI. This appears to use the functions from System Tools Backends to actually obtain the current time zone.

Now, my understanding of the relationships and dependencies is far from perfect, but I was able to read and roughly understand the code in Time::TimeDate.pm -- it basically compares your /etc/localtime to the available time zone files, and (duh) reports the first match.

But why doesn't it simply read my /etc/timezone?

jaunty$ perl -I/usr/share/system-tools-backends-2.0/scripts -MTime::TimeDate -MUtils::File \
> -le 'print Time::TimeDate::get_timezone("/etc/localtime", "/usr/share/zoneinfo")'
Europe/Mariehamn

jaunty$ cat /etc/timezone
Europe/Helsinki

jaunty$ ls -l /etc/localtime /usr/share/zoneinfo/Europe/{Helsinki,Mariehamn}
-rw-r--r-- 1 root root 1883 2009-07-04 22:07 /etc/localtime
-rw-r--r-- 2 root root 1883 2009-06-18 19:15 /usr/share/zoneinfo/Europe/Helsinki
-rw-r--r-- 2 root root 1883 2009-06-18 19:15 /usr/share/zoneinfo/Europe/Mariehamn

jaunty$ md5sum /etc/localtime /usr/share/zoneinfo/Europe/{Helsinki,Mariehamn}
a2a75461ac17557cba12a846a564e467 /etc/localtime
a2a75461ac17557cba12a846a564e467 /usr/share/zoneinfo/Europe/Helsinki
a2a75461ac17557cba12a846a564e467 /usr/share/zoneinfo/Europe/Mariehamn

Thus, the following locations exhibit the problem:

jaunty$ grep -v '^#' /usr/share/zoneinfo/zone.tab | cut -sf3 |
> perl -I/usr/share/system-tools-backends-2.0/scripts -MTime::TimeDate -MUtils::File -lne '
> $a = $_;
> $tz = Time::TimeDate::get_timezone("/usr/share/zoneinfo/$_", "/usr/share/zoneinfo");
> print "$a != $tz" unless ($a eq $tz)'
Antarctica/South_Pole != Antarctica/McMurdo
Europe/Helsinki != Europe/Mariehamn
Europe/Guernsey != Europe/London
America/Guadeloupe != America/St_Barthelemy
Europe/Zagreb != Europe/Sarajevo
Europe/Isle_of_Man != Europe/London
Europe/Jersey != Europe/London
Europe/Podgorica != Europe/Sarajevo
America/Marigot != America/St_Barthelemy
Europe/Skopje != Europe/Sarajevo
Europe/Belgrade != Europe/Sarajevo
Europe/Ljubljana != Europe/Sarajevo
Arctic/Longyearbyen != Europe/Oslo
Europe/Bratislava != Europe/Prague
Europe/San_Marino != Europe/Rome
America/Shiprock != America/Denver
Europe/Vatican != Europe/Rome

As predicted by this list, I was able to reproduce for Longyearbyen and Jersey as well, and would expect the rest of the list to reprodce this problem as well. For Longyearbyen -> Olso and Jersey -> London the mapping is luckily to the proper main city in the governing territory, so I guess it's less sensitive for them, but it's still a bug. If Rome mapped to San Marino, or Denver to Shiprock, that would be similar to the situation wrt Helsinki/Mariehamn. And Bratislava -> Prague is pretty grave, of course.

Revision history for this message
era (era) wrote :

> unable to get any discrepancy for Europe/London
> (also since Mark Fraser is using Kubuntu,
> his is bound to be a different problem).

Actually, if he means that he sets his time zone to Guernsey in time-admin, and it gets reset to London, that is the same problem.

Revision history for this message
Mark Fraser (launchpad-mfraz) wrote :

> > unable to get any discrepancy for Europe/London
> > (also since Mark Fraser is using Kubuntu,
> > his is bound to be a different problem).

> Actually, if he means that he sets his time zone to Guernsey in time-admin, and it gets reset to London, that is the same
> problem.

Almost, but if I set my time zone to London, it gets set to Guernsey.

Revision history for this message
era (era) wrote :

@Mark Fraser: perhaps you should submit a separate bug report, because this one is about a similar problem in Gnome. Do include a link to this bug report. Sorry, can't help you with which KDE component to file a bug against.

Revision history for this message
Savvas Radevic (medigeek) wrote :

I agree with era :)
The problem was fixed in system-tools-backends package which is not used by any kde package:

$ apt-cache rdepends system-tools-backends
system-tools-backends
Reverse Depends:
  gnome-system-tools
  liboobs-1-4
  gnome-system-tools

$ apt-cache rdepends liboobs-1-4
liboobs-1-4
Reverse Depends:
  gnome-network-admin
  gnome-system-tools
  gnome-applets
  moblin-applets
  gnome-network-admin
  liboobs-1-dev
  liboobs-1-4-dbg
  gnome-system-tools
  gnome-applets

Changed in gst:
status: New → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.