bpo-40275: test.support imports lazily locale import (GH-19761)

This commit is contained in:
Hai Shi 2020-05-05 02:05:02 +08:00 committed by GitHub
parent 785f5e6d67
commit 975408c065
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -13,7 +13,6 @@ import gc
import glob
import importlib
import importlib.util
import locale
import os
import platform
import re
@ -2311,6 +2310,7 @@ def skip_if_buggy_ucrt_strfptime(test):
See bpo-37552 [Windows] strptime/strftime return invalid
results with UCRT version 17763.615
"""
import locale
global _buggy_ucrt
if _buggy_ucrt is None:
if(sys.platform == 'win32' and