File tree Expand file tree Collapse file tree 1 file changed +7
-4
lines changed Expand file tree Collapse file tree 1 file changed +7
-4
lines changed Original file line number Diff line number Diff line change 1212import bz2
1313import gzip
1414import sys
15+ import warnings
1516from os .path import splitext
1617from distutils .version import StrictVersion
1718
1819# is indexed_gzip present and modern?
1920try :
2021 from indexed_gzip import SafeIndexedGzipFile , __version__ as version
2122
22- if StrictVersion (version ) < StrictVersion ("0.6.0" ):
23- raise ImportError ('indexed_gzip is present, but too old '
24- '(>= 0.6.0 required): {})' .format (version ))
23+ HAVE_INDEXED_GZIP = True
24+
25+ if StrictVersion (version ) < StrictVersion ('0.6.0' ):
26+ warnings .warn ('indexed_gzip is present, but too old '
27+ '(>= 0.6.0 required): {})' .format (version ))
28+ HAVE_INDEXED_GZIP = False
2529
2630 del version
27- HAVE_INDEXED_GZIP = True
2831
2932except ImportError :
3033 HAVE_INDEXED_GZIP = False
You can’t perform that action at this time.
0 commit comments