[tz] Time Zone City for China

Guy Harris guy at alum.mit.edu
Wed Jul 22 22:04:48 UTC 2015


On Jul 22, 2015, at 3:14 AM, Lester Caine <lester at lsces.co.uk> wrote:

> On 22/07/15 10:26, Guy Harris wrote:
>> It's even *better* if time zone selectors stopped turning the list of tzdb identifiers into a list of cities to offer to the user or, even worse, just offering the tzdb identifiers directly as choices to users. 
> 
> Distributions take the easy route,

Let's do what we can to try to get them to stop doing so.

> which is perhaps one reason that the
> base identifiers should be a reasonable fall back solution,

That means changing the criteria for choosing a tzid so that

        Use the most populous among locations in a zone,
                e.g. prefer 'Shanghai' to 'Beijing'.  Among locations with
                similar populations, pick the best-known location,
                e.g. prefer 'Rome' to 'Milan'.

is changed to "Use a location that's a 'reasonable fallback solution' for time zone choosers that don't have a good set of cities to choose from" or "Use the best-known location".

> but in
> practice the lookup for timezone based on location still needs a
> reliable source. geonames does provide a fairly accurate return on
> current tzid for a location, but it's not the sort of thing that would
> be built into a distribution.

	http://www.geonames.org/about.html

"GeoNames Users

	* Apple SnowLeopard, Ubuntu

	..."

so at least *one* distribution uses GeoNames for something.

This page:

	http://news.softpedia.com/news/Ubuntu-10-10-Will-Have-a-Revamped-Installer-146644.shtml

claims

	No more region and city boxes in the timezone setup page! All you'll have to do on this page is to type the city you live in and the installer will automatically get the correct timezone. This new functionality is based on the amazing work done by the developers at GeoNames.org.

although, as per the bug I filed, it didn't seem to work for me on 15.04.  If there's code there, it's probably using the Web services API for this:

	http://www.geonames.org/export/web-services.html#timezone

If it's *supposed* to work, that's getting close to what Apple does, but doing nothing when I type a city name into it and hitting Enter doesn't count as "working" in my book.

> I have to admit to taking the easy option
> myself, but a more powerful lookup package does have a place in these
> more global times? That is not something that TZ is tasked to supply though.

At *most*, I could see the tzdb providing tzdb zone boundaries; it's outside our scope to provide location services or lists of cities near particular locations.

And if the GeoNames people are willing to provide that - and to do what's necessary to update that whenever we introduce a new tzdb zone - we don't need to provide that ourselves.  Given that Web services API, they may well do that.


More information about the tz mailing list