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
Decide on caching behaviour for parsed tzinfo data #719
Comments
I don't think we really have natural API surface where this could be configured. Absent configuration API, I see 3 options:
I wonder what libc does? Arguably we will attain maximum compatibility if we do the same thing as, say, glibc. |
From a brief look at glibc it seems to do the following:
We could potentially check the symlink metadata each time and only re-parse if it has been modified (in the case of using a file) which is I think quite similar to what glic does. |
Yeah, checking the symlink mtime (not sure it's always a symlink?) seems like a decent improvement. As a further optimization, I suppose we could only check the mtime once per minute or so? We could take the |
@esheppa would you be able to take a stab at this? IMO getting a 0.4.20 out with what we've got so far (especially the advisory fixes) is higher priority than triaging old pull issues/PRs. |
Solved via #728 |
Currently we parse this lazily the first time that a user interacts with a
Local
timezone. This could be problematic in cases where the symlink for /etc/localtime is updated. See linked comment for further discussion#683 (comment)
The text was updated successfully, but these errors were encountered: