From 6eab9614c918bf61f96e826ae02070a69b02df6b Mon Sep 17 00:00:00 2001 From: Christopher De Vries Date: Mon, 22 Sep 2025 14:16:42 -0400 Subject: [PATCH 1/2] Remove an assert from the code which should not crash the library --- src/tzif/database.gleam | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/tzif/database.gleam b/src/tzif/database.gleam index 1f0b52c..8ebdb00 100644 --- a/src/tzif/database.gleam +++ b/src/tzif/database.gleam @@ -48,7 +48,9 @@ pub fn load_from_os() -> Result(TzDatabase, Nil) { pub fn load_from_path(path: String) -> Result(TzDatabase, Nil) { let parts = filepath.split(path) let drop_number = list.length(parts) - let assert Ok(filenames) = simplifile.get_files(path) + use filenames <- result.try( + simplifile.get_files(path) |> result.replace_error(Nil), + ) let data = filenames From bc560d81e918a7c19e63d1a1678785c50b895602 Mon Sep 17 00:00:00 2001 From: Christopher De Vries Date: Mon, 22 Sep 2025 16:24:49 -0400 Subject: [PATCH 2/2] add a changelog --- CHANGELOG.md | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 CHANGELOG.md diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 0000000..7229ddb --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1,13 @@ +## Unreleased +- Fix bug where the library will crash if asked to load Time Zone information + from a nonexistant directory. + +## v1.0.0 - 2025-09-21 +- Initial release +- Exposes parser as a module +- Adds support for leap seconds +- Explicit loading of time zone database into an opaque record +- Completely overhauled API + +## v0.1.0 - 2025-09-17 +- Initial proof of concept.