8000
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent bbebd46 commit e719856Copy full SHA for e719856
Tests/test_NaiveBayes.py
@@ -4,11 +4,20 @@
4
5
try:
6
import numpy
7
- del numpy
8
except ImportError:
9
from Bio import MissingPythonDependencyError
10
raise MissingPythonDependencyError(
11
"Install NumPy if you want to use Bio.NaiveBayes.")
+try:
12
+ hash(numpy.float64(123.456))
13
+except TypeError:
14
+ # Due to a bug in NumPy 1.12.1, this is unhashable under
15
+ # PyPy3.5 v5.7 beta - it has been fixed in NumPy
16
+ from Bio import MissingPythonDependencyError
17
+ raise MissingPythonDependencyError(
18
+ "Please update NumPy if you want to use Bio.NaiveBayes "
19
+ "(under this version numpy.float64 is unhashable).")
20
+del numpy
21
22
from Bio import NaiveBayes
23
0 commit comments