feat: allow for a configurable time zone database#41
Conversation
|
hi @benwilson512, First of all, thanks for your contribution. It's great learning that someone is using this package and takes care providing improvements. I've been thinking about your PR and, taking into account the current maintenance state of I'm wondering what's the best way of articulating the flexibility you're introducing with this change. Until now I'm not against introducing breaking changes, actually the opposite. This looks like a good change providing flexibility to the users so it can be a good moment for a first major release, however we need to figure out the best way to do so. |
|
An excellent point. While I think it's in practice extremely unlikely this would mess someone up I do think it's reasonable to make this a 0.4 release. This sort of change would be pretty expected in a pretty 1.0 library. Notably if for whatever reason a user did not want to configure Elixir itself or if they wanted to configure a different database for open hours, that is possible under this PR. I will update the PR to ensure the tests pass, as well as provide some changelog / readme entries to cover the full config story. |
|
That'd be awesome @benwilson512 I have just merged a change in the CI that will unblock the elixir 1.18 ci test. It was failing due to a Erlang certificate problem. So please rebase your branch :-) |
|
Synced with main and changelog / readme notes added. |
Hey folks!
We're in the middle of trying to minimize our dependency on Hackney, after a variety of recently released CVEs and the decision to only remediate them in
~ 4.0. Unfortunatelytzdatahas a direct dependency on hackney.That said we were already on a path to remove
tzdataastzhas a more rigorous overall approach, and this one library is the standout on our end.This PR makes
tzdataoptional, and allows the user to specify one for this library. If one is not specified it falls back to whatever is configured on Elixir itself.While I realize the motivation for this PR on our end is pretty tangential to this library's goals, I do think the approach of not binding to a specific timezone database is a good one.