From 37eab03d7db75e550652658bd1af1988cb0f1707 Mon Sep 17 00:00:00 2001 From: Marcel Bargull Date: Thu, 12 Jul 2018 06:58:14 -0500 Subject: on Windows+PY2 get_config_var('Py_UNICODE_SIZE') is None --- compat.py | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/compat.py b/compat.py index 521b8e6..022762b 100644 --- a/compat.py +++ b/compat.py @@ -7,7 +7,6 @@ from __future__ import print_function import sys import os import types -import sysconfig if False: # MYPY from typing import Any, Dict, Optional, List, Union, BinaryIO, IO, Text, Tuple # NOQA @@ -113,9 +112,7 @@ if PY3: else: builtins_module = '__builtin__' -UNICODE_SIZE = sysconfig.get_config_var('Py_UNICODE_SIZE') -if UNICODE_SIZE is None: # on Python >= 3.3 unicode has no fixed bytesize - UNICODE_SIZE = 4 +UNICODE_SIZE = 4 if sys.maxunicode > 65535 else 2 def with_metaclass(meta, *bases): -- cgit v1.2.1