Rename _verify_python3_env

This commit is contained in:
James R. Barlow
2017-11-29 13:43:18 -08:00
parent 2cc044feed
commit d2217632df
2 changed files with 6 additions and 3 deletions

View File

@@ -28,7 +28,7 @@ from . import PROGRAM_NAME, VERSION
from .exceptions import *
from . import exceptions as ocrmypdf_exceptions
from . import _unicodefun
from ._unicodefun import verify_python3_env
warnings.simplefilter('ignore', pypdf.utils.PdfReadWarning)
@@ -50,7 +50,10 @@ def complain(message):
if 'IDE_PROJECT_ROOTS' in os.environ:
os.environ['PATH'] = '/usr/local/bin:' + os.environ['PATH']
_unicodefun._verify_python3_env()
# --------
# Critical environment tests
verify_python3_env()
if tesseract.version() < MINIMUM_TESS_VERSION:
complain(

View File

@@ -38,7 +38,7 @@ import sys
import codecs
def _verify_python3_env():
def verify_python3_env():
"""Ensures that the environment is good for unicode on Python 3."""
try:
import locale