[h5py] 448/455: More graceful failure when NumPy not installed

Ghislain Vaillant ghisvail-guest at moszumanska.debian.org
Thu Jul 2 18:20:00 UTC 2015


This is an automated email from the git hooks/post-receive script.

ghisvail-guest pushed a commit to annotated tag 1.3.0
in repository h5py.

commit aa8b270ee783a0d00a007ddd0306443f5c995a03
Author: andrewcollette <andrew.collette at gmail.com>
Date:   Sun Mar 14 00:45:13 2010 +0000

    More graceful failure when NumPy not installed
---
 setup.py | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/setup.py b/setup.py
index e613f35..5b780da 100644
--- a/setup.py
+++ b/setup.py
@@ -26,7 +26,6 @@
 """
 
 import sys, os
-import numpy
 import os.path as op
 
 VERSION = '1.3.0-beta'
@@ -44,6 +43,11 @@ from distutils.cmd import Command
 from distutils.command.build_ext import build_ext
 import detect
 
+try:
+    import numpy
+except ImportError:
+    fatal("NumPy 1.0.3 or higher is required to use h5py (http://numpy.scipy.org).")
+
 # --- Convenience functions ---------------------------------------------------
 
 def debug(what):

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/h5py.git



More information about the debian-science-commits mailing list