[tz] Version in zoneinfo files?

Paul G paul at ganssle.io
Sun Oct 25 17:26:21 UTC 2015


On 10/25/2015 01:10 PM, John Haxby wrote:
> Downstream providers sometimes choose to ship an unofficial patch early.  There have been a few RHEL/CentOS/OL updates like this.   If there was a version string embedded in some file it would usually be left alone.   (For example, “ls --version” shows a particular version and it’s not updated with patches applied downstream, this sometimes confuses people.)

Thank you for this clarification! I suspect that this is a problem with all versioned software, and it's generally solved either by versioning that includes a build number or a "buyer beware" attitude. That said, if it's really worrisome, the first patch of any new release cycle could be to change the version number to something like '2015g-unstable' or '2015g-rc', which is only changed to '2015g' as part of the final release process.


> I think, as Paul E suggests, keeping the version external is a good choice here.   It encourages people to use whatever the platform provides to find out the exact, local version information.   If anyone knows how to find out what version of tzdata is installed on this macbook I’d love to know :)

I think this perfectly illustrates the reason why the versioning should be at the zic level and not downstream. If every downstream provider is implementing the versioning in a different way, unless you ship your own version of the built zoneinfo file with your application, there's no reliable way to get the version information in a cross-platform way.

This is a problem for organizations where timezone data is critical but with a large architecture - in those cases, it's often best to have all consumers of zoneinfo files point to the same binaries (this way you don't have to redeploy every zoneinfo consumer on every tzdata update), in which case everyone has to standardize on one way to store the zoneinfo metadata anyway, or you're going to get a proliferation of different types of metadata you have to store along with zoneinfo.

> 
>> On 10/25/2015 03:13 AM, Paul Eggert wrote:
>>> Paul G wrote:
>>>> If not, I would like to suggest that a VERSION or METADATA file be added
>>>> to the zoneinfo output.
>>>
>>> Although there is a version number in those files, it's not what you're
>>> looking for: it's the version number of the zic format (a number that
>>> changes only very slowly), not the tzdata version number. There's no
>>> provision in the current zic format for storing an arbitrary tzdata
>>> version number like '2015g'. Perhaps we could add one, but there would
>>> be a downside: people might take strings like '2015g' too seriously, and
>>> assume that two files from different sources labeled '2015g' would be
>>> identical (an assumption that would not be true). This downside has made
>>> me reluctant to change the zic format in this area.
>>
> 



More information about the tz mailing list