<div dir="ltr"><div style="word-wrap:break-word;line-break:after-white-space">Stephen Colebourne's recent attempts to define requirements and use cases for tzdb got me thinking about the source data files.</div><div style="word-wrap:break-word;line-break:after-white-space"><br></div><div style="word-wrap:break-word;line-break:after-white-space">There have been several discussions over the years regarding the intended stability of the source format, separate from TZif binary files. These generally arise when the answer to a data query is "use this special compile-time flag". The most recent example is from Stephen at <a href="http://mm.icann.org/pipermail/tz/2021-September/030561.html" target="_blank">http://mm.icann.org/pipermail/tz/2021-September/030561.html</a></div><div style="word-wrap:break-word;line-break:after-white-space"><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div style="word-wrap:break-word;line-break:after-white-space">The subtlety is in how the data set is consumed. While many downstream<br>projects use the makefile, not all do. A significant portion of<br>downstream users make use of the source files directly, with their own<br>parsers. ie. there is no ability to use a compile-time option. Those<br>parsers are not setup to use backzone even if it were a valid option</div></blockquote><div><br></div><div>I think some of these discussions come about because there's disagreement about the intended use of the source files. The impression I've got from this list over the years is that the source files weren't intended to be a stable API; only the compiled TZif binary files were intended to be consumed downstream (and in later years, the .zi text representations). But many projects do use the source files as their primary interface, leading to tension when the format changes.<br></div><div style="word-wrap:break-word;line-break:after-white-space"><br></div><div style="word-wrap:break-word;line-break:after-white-space">So this is my attempt to list the use cases that people have for the source data files. This could prompt a wider discussion about what counts as a defined, stable interface for tzdb. Not every consumer of tzdb data is relying solely on the pre-compiled binary files.<br></div><div style="word-wrap:break-word;line-break:after-white-space"><br></div>NOTE: This is a separate issue from the recent pre-/post-1970 data discussions. I'm trying to stay away from wading into that topic.<br><div style="word-wrap:break-word;line-break:after-white-space"><br></div><div style="word-wrap:break-word;line-break:after-white-space">-----------------------</div><div style="word-wrap:break-word;line-break:after-white-space"><br></div><div style="word-wrap:break-word;line-break:after-white-space">Consumers of the source data text files:<br></div><div dir="auto" style="word-wrap:break-word;line-break:after-white-space"><div><br></div><div>1) The zic compiler for producing TZif binary files and .zi text files in an official tzdb release.<br></div><div><br></div><div>2) People reading the file comments to understand the history of certain zones.<br></div><div><br></div><div>3) Libraries/projects that need to parse/compile the data into a different representation than that provided by zic. This is often, but not exclusively, to preserve the distinction between Link and Zone entries, either for API or data compression reasons.</div><div><br></div><div>4) Data analysis or visualisations that care about knowing the higher-level Rule definitions ("transition on the last Sunday of October every year") rather than the exact transition timestamps for each year.<br></div><div><br></div><div>5) IDE or text editor plugins that provide syntax highlighting for the source files.</div><div><br></div><div><div style="overflow-wrap: break-word;">All of these are based just on my own experiences and from lurking on this list. Any corrections/additions are welcome.</div><div style="overflow-wrap: break-word;"><br></div></div></div>
</div>