Skip to content

bpo-40503: Check in <prefix>/share/zoneinfo for zoneinfo files on windows #28495

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

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

isuruf
Copy link
Contributor

@isuruf isuruf commented Sep 21, 2021

…dows

This is a relocatable path and conda uses this path for zoneinfo files on windows.

https://bugs.python.org/issue40503

@github-actions
Copy link

This PR is stale because it has been open for 30 days with no activity.

@github-actions github-actions bot added the stale Stale PR or inactive for long period of time. label Oct 22, 2021
@@ -489,7 +489,11 @@ def _init_non_posix(vars):
vars['EXE'] = '.exe'
vars['VERSION'] = _PY_VERSION_SHORT_NO_DOT
vars['BINDIR'] = os.path.dirname(_safe_realpath(sys.executable))
vars['TZPATH'] = ''
check_tzpath = os.path.join(vars['prefix'], 'share', 'zoneinfo')
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
check_tzpath = os.path.join(vars['prefix'], 'share', 'zoneinfo')
# No standard path exists on Windows for this, but we'll check
# whether someone is imitating a POSIX-like layout
check_tzpath = os.path.join(vars['prefix'], 'share', 'zoneinfo')

@zooba
Copy link
Member

zooba commented Feb 26, 2024

LGTM, though I'd like to have a comment at least acknowledging that this path is one guess, and not in any way a standard or expectation.

There's also a merge conflict of some kind.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
awaiting review OS-windows stale Stale PR or inactive for long period of time.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants