From e1c2ea29dd85b2207bbdc5d56c7139b125732b37 Mon Sep 17 00:00:00 2001 From: Stefan van der Walt Date: Mon, 7 Mar 2016 01:38:22 -0800 Subject: [PATCH] Warn if user tries to build with older Cython version --- skimage/_build.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/skimage/_build.py b/skimage/_build.py index f5db582d..2905ee26 100644 --- a/skimage/_build.py +++ b/skimage/_build.py @@ -1,7 +1,7 @@ import sys import os import hashlib -import subprocess +from distutils.version import LooseVersion # WindowsError is not defined on unix systems try: @@ -25,6 +25,10 @@ def cython(pyx_files, working_path=''): return try: + from Cython import __version__ + if LooseVersion(__version__) < '0.23': + raise RuntimeError('Cython >= 0.23 needed to build scikit-image') + from Cython.Build import cythonize except ImportError: # If cython is not found, we do nothing -- the build will make use of