Skip to content

Commit

Permalink
Fix version check of h5py
Browse files Browse the repository at this point in the history
  • Loading branch information
Maximilian Schmidt committed Apr 18, 2018
1 parent 02899ca commit d5efe80
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion h5py_wrapper/wrapper.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,11 @@
quantities_found = False

# make sure correct h5py version is available
if int(re.sub('\.', '', h5py.version.version)) < 231:
h5py_version = h5py.version.version_tuple
h5py_version_int = int('{}{}{}'.format(h5py_version.major,
h5py_version.minor,
h5py_version.bugfix))
if h5py_version_int < 231:
raise ImportError("Using h5py version {version}. Version must "
"be >= 2.3.1".format(version=h5py.version.version))

Expand Down

0 comments on commit d5efe80

Please sign in to comment.