File tree Expand file tree Collapse file tree 2 files changed +7
-2
lines changed Expand file tree Collapse file tree 2 files changed +7
-2
lines changed Original file line number Diff line number Diff line change 68
68
69
69
# oh the troubles to reduce import time
70
70
_table_mod = None
71
- _table_supports_index = True
71
+ _table_supports_index = False
72
72
73
73
def _tables ():
74
74
global _table_mod
@@ -79,7 +79,7 @@ def _tables():
79
79
80
80
# version requirements
81
81
major , minor , subv = tables .__version__ .split ('.' )
82
- if major >= 2 and minor >= 3 :
82
+ if int ( major ) >= 2 and int ( minor ) >= 3 :
83
83
_table_supports_index = True
84
84
85
85
return _table_mod
Original file line number Diff line number Diff line change @@ -184,6 +184,11 @@ def test_create_table_index(self):
184
184
self .store .put ('f2' , df )
185
185
self .assertRaises (Exception , self .store .create_table_index , 'f2' )
186
186
187
+ # try to change the version supports flag
188
+ from pandas .io import pytables
189
+ pytables ._table_supports_index = False
190
+ self .assertRaises (Exception , self .store .create_table_index , 'f' )
191
+
187
192
def test_append_diff_item_order (self ):
188
193
wp = tm .makePanel ()
189
194
wp1 = wp .ix [:, :10 , :]
You can’t perform that action at this time.
0 commit comments