[issue40503] PEP 615: Add zoneinfo module

2021-09-21 Thread Steve Dower
Steve Dower added the comment: We'd need to implement some form of data store for values on Windows, which currently are not compiled in anywhere, and it would need a substitution syntax to be updated at runtime. We're talking a big feature now, and you'd end up having just as much code on

[issue40503] PEP 615: Add zoneinfo module

2021-09-21 Thread Isuru Fernando
Isuru Fernando added the comment: Do you have a suggestion for how to make it configurable at compile time? In POSIX platforms, we can set `--with-tzpath` to make it configurable at compile time. -- ___ Python tracker

[issue40503] PEP 615: Add zoneinfo module

2021-09-21 Thread Steve Dower
Steve Dower added the comment: I meant I don't think we want that path upstream, and you should keep it as your own patch. We don't have a "share" directory as part of CPython, but this would codify it. That would then conflict with your use of it in conda-forge. It also makes sysconfig

[issue40503] PEP 615: Add zoneinfo module

2021-09-21 Thread Isuru Fernando
Isuru Fernando added the comment: Thanks @steve.dower for the info. I've created https://github.com/python/cpython/pull/28495. Let me know if it needs to have a separate bpo issue. -- ___ Python tracker

[issue40503] PEP 615: Add zoneinfo module

2021-09-21 Thread Isuru Fernando
Change by Isuru Fernando : -- pull_requests: +26890 pull_request: https://github.com/python/cpython/pull/28495 ___ Python tracker ___

[issue40503] PEP 615: Add zoneinfo module

2021-09-20 Thread STINNER Victor
Change by STINNER Victor : -- nosy: -vstinner ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue40503] PEP 615: Add zoneinfo module

2021-09-20 Thread Steve Dower
Steve Dower added the comment: That looks like a relocatable path anyway, which means you wouldn't want to compile it into the binary. Your patch to select a default value at runtime is probably better. The compile-time option is meant for a system directory. --

[issue40503] PEP 615: Add zoneinfo module

2021-09-16 Thread Isuru Fernando
Isuru Fernando added the comment: > If anyone building Python for Windows shows up needing support for this, we > can re-visit the issue — I don't believe it's technically infeasible, just > that the usage patterns of Python on Windows mean that it's not worth doing. At conda-forge, we need

[issue40503] PEP 615: Add zoneinfo module

2020-05-18 Thread STINNER Victor
STINNER Victor added the comment: I suggest to open a separated issue to discuss how tzdata can be installed on Travis CI, Azure Pipelines, Buildbots, etc. when running tests. -- ___ Python tracker

[issue40503] PEP 615: Add zoneinfo module

2020-05-16 Thread Paul Ganssle
Paul Ganssle added the comment: New changeset b17e49e0def23238b9e7f48c8a02e2d7bbf1f653 by Paul Ganssle in branch 'master': bpo-40503: Add documentation and what's new entry for zoneinfo (GH-20006) https://github.com/python/cpython/commit/b17e49e0def23238b9e7f48c8a02e2d7bbf1f653 --

[issue40503] PEP 615: Add zoneinfo module

2020-05-16 Thread STINNER Victor
STINNER Victor added the comment: New changeset 62972d9d73e83d6eea157617cc69500ffec9e3f0 by Paul Ganssle in branch 'master': bpo-40503: PEP 615: Tests and implementation for zoneinfo (GH-19909) https://github.com/python/cpython/commit/62972d9d73e83d6eea157617cc69500ffec9e3f0 --

[issue40503] PEP 615: Add zoneinfo module

2020-05-13 Thread Paul Ganssle
Paul Ganssle added the comment: Talked to Steve Dower in a sidebar about the issue with compile-time configuration, he is convinced that compile-time configuration is not something that would be useful or worth doing on Windows. I am indifferent on the matter, so I am fine with calling the

[issue40503] PEP 615: Add zoneinfo module

2020-05-11 Thread Paul Ganssle
Paul Ganssle added the comment: Here are some benchmarks run using the latest implementation. The pure Python code is pretty optimized, but the C code is still ~4-5x faster. Running from_utc in zone Europe/Paris c_zoneinfo: mean: 494.82 ns ± 3.80 ns; min: 489.23 ns (k=5, N=50)

[issue40503] PEP 615: Add zoneinfo module

2020-05-11 Thread Paul Ganssle
Paul Ganssle added the comment: I mean, theoretically we don't "need" it, but it's much, much faster, and without it nearly every operation that needs time zone offsets will be slower than pytz (which has a mechanism for caching). Also, I've already written it, so I see no reason why not

[issue40503] PEP 615: Add zoneinfo module

2020-05-11 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Do we need the C implementation if there is the Python implementation? -- nosy: +serhiy.storchaka ___ Python tracker ___

[issue40503] PEP 615: Add zoneinfo module

2020-05-11 Thread Paul Ganssle
Paul Ganssle added the comment: Thanks Thomas, that was super helpful. I've created GH-20034 to add in the compile-time arguments on POSIX systems at least, do you mind having a look? For the moment I have made it non-configurable on Windows, but I think the right thing to do is to add an

[issue40503] PEP 615: Add zoneinfo module

2020-05-11 Thread Paul Ganssle
Change by Paul Ganssle : -- pull_requests: +19343 pull_request: https://github.com/python/cpython/pull/20034 ___ Python tracker ___

[issue40503] PEP 615: Add zoneinfo module

2020-05-11 Thread Thomas Wouters
Thomas Wouters added the comment: The normal way to do this (for make/autoconf) is to add a --with-tzpath argument to configure.ac, and a make variable to pass it to the compilation of anything that needs it. You can then access it from Python code with sysconfig.get_config_var(). In

[issue40503] PEP 615: Add zoneinfo module

2020-05-08 Thread Paul Ganssle
Paul Ganssle added the comment: I've separated this into two separate PRs, one for docs and one for tests/implementation. I have not yet implemented the logic for the ability to configure the TZPATH at compile time because I'm not quite sure how to start on that. How are other compile-time

[issue40503] PEP 615: Add zoneinfo module

2020-05-08 Thread Paul Ganssle
Change by Paul Ganssle : -- pull_requests: +19318 pull_request: https://github.com/python/cpython/pull/20006 ___ Python tracker ___

[issue40503] PEP 615: Add zoneinfo module

2020-05-04 Thread Paul Ganssle
Change by Paul Ganssle : -- keywords: +patch pull_requests: +19224 stage: needs patch -> patch review pull_request: https://github.com/python/cpython/pull/19909 ___ Python tracker

[issue40503] PEP 615: Add zoneinfo module

2020-05-04 Thread Paul Ganssle
New submission from Paul Ganssle : This is an issue to track the implementation of PEP 615: https://www.python.org/dev/peps/pep-0615/ It should mostly involve migrating from the reference implementation: https://github.com/pganssle/zoneinfo/ -- assignee: p-ganssle components: