Skip to content

Commit 24b8e38

Browse files
committed
Try more specific locale setting
1 parent ef6eb3e commit 24b8e38

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

pandas/_testing/__init__.py

+6-3
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@
2626
)
2727

2828
from pandas._typing import Dtype
29+
from pandas.compat import is_platform_linux
2930

3031
from pandas.core.dtypes.common import (
3132
is_float_dtype,
@@ -191,9 +192,11 @@
191192
EMPTY_STRING_PATTERN = re.compile("^$")
192193

193194
# Our Linux CI environments install the associated language packs
194-
TESTING_LOCALES = [
195-
loc for loc in get_locales() or [] if loc in {"it_IT.UTF-8", "zh_CN.UTF-8"}
196-
]
195+
if os.environ.get("PANDAS_CI", "0") == "1" and is_platform_linux():
196+
ci_locales = get_locales() or []
197+
else:
198+
ci_locales = []
199+
TESTING_LOCALES = [loc for loc in ci_locales if loc in {"it_IT.UTF-8", "zh_CN.UTF-8"}]
197200

198201
# set testing_mode
199202
_testing_mode_warnings = (DeprecationWarning, ResourceWarning)

0 commit comments

Comments
 (0)