File tree 2 files changed +6
-5
lines changed
2 files changed +6
-5
lines changed Original file line number Diff line number Diff line change @@ -237,9 +237,9 @@ static PyObject *get_values(PyObject *obj) {
237
237
}
238
238
}
239
239
240
- if ((values == NULL ) && PyObject_HasAttrString (obj , "get_block_values " )) {
240
+ if ((values == NULL ) && PyObject_HasAttrString (obj , "get_block_values_for_json " )) {
241
241
PRINTMARK ();
242
- values = PyObject_CallMethod (obj , "get_block_values " , NULL );
242
+ values = PyObject_CallMethod (obj , "get_block_values_for_json " , NULL );
243
243
244
244
if (values == NULL ) {
245
245
// Clear so we can subsequently try another method
Original file line number Diff line number Diff line change @@ -231,11 +231,12 @@ def get_values(self, dtype=None):
231
231
return self .values .astype (object )
232
232
return self .values
233
233
234
- def get_block_values (self , dtype = None ) :
234
+ def get_block_values_for_json (self ) -> np . ndarray :
235
235
"""
236
- This is used in the JSON C code
236
+ This is used in the JSON C code.
237
237
"""
238
- return self .get_values (dtype = dtype )
238
+ # TODO(2DEA): reshape will be unnecessary with 2D EAs
239
+ return np .asarray (self .values ).reshape (self .shape )
239
240
240
241
def to_dense (self ):
241
242
return self .values .view ()
You can’t perform that action at this time.
0 commit comments