File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 4242try :
4343 # pylint: disable=wrong-import-position
4444 import happybase # pylint: disable=unused-import
45- # weird this is only importable after happybase, must global implicit import
4645 # happybase.hbase.ttypes.IOError no longer there in Happybase 1.0
47- from Hbase_thrift import IOError as HBaseIOError # pylint: disable=import-error
46+ try :
47+ # this is only importable after happybase module
48+ # pylint: disable=import-error
49+ from Hbase_thrift import IOError as HBaseIOError
50+ except ImportError :
51+ # probably Happybase <= 0.9
52+ # pylint: disable=import-error,no-name-in-module,ungrouped-imports
53+ from happybase .hbase .ttypes import IOError as HBaseIOError
4854 from thriftpy .thrift import TException as ThriftException
4955except ImportError as _ :
5056 print ('Happybase / thrift module import error - did you forget to build this project?\n \n '
6369 sys .exit (4 )
6470
6571__author__ = 'Hari Sekhon'
66- __version__ = '0.3 '
72+ __version__ = '0.4 '
6773
6874
6975class HBaseCompactTables (CLI ):
You can’t perform that action at this time.
0 commit comments