-
Notifications
You must be signed in to change notification settings - Fork 18
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Transitive dependencies on TimeZones.jl #184
Comments
Not relevent to you in this case as you have already swapped to IntervalSets.jl We could use Requires.jl to make it an optionally loaded dependency, so that the code isn't loaded. But we might we be to do, as you say is just remove those methods entirely. Intervals.jl/src/anchoredinterval.jl Lines 387 to 393 in f873f70
Lines 483 to 492 in a785b56
don't really seem idoiomatic julia in the first place. Since they are kind of like implict broadcasting (removed in julia 1.5) -- not exactly the same. The timezone of an interval IMO should be found out by asking about time timezone of the endpoints (or the anchor), and set similarly. I always forget you can do that. I don't think we do that anywhere in our internal codebase |
I was surprised to note that TimeZones was added as a dependency of my project after adding SpecialPolynomials. The dependency graph is through this package, Intervals.jl. The TimeZones library is rather heavy, and brings in multiple dependencies of its own.
It would be preferable if math-only libraries which have no need for date arithmetic didn't have to depend on the entire IANA TZ database. What I propose is hiding the TimeZones dependency behind a Requires.jl
@requires
block, like so:where
timezones.jl
would include all of the TimeZones-specific methods (there are six such methods).Other options:
TimeIntervals.jl
or something).The easiest is the
Requires.jl
option. I already have tests passing that way, so let me know if a PR is welcome.Note that all of the above also goes for the dependency on
Dates
-- that's not so heavy because it's in the stdlib, but if I were benevolent dictator for life of this package, I would make that dependency optional as well.Thanks!
The text was updated successfully, but these errors were encountered: