Details
-
Bug
-
Status: Resolved
-
Major
-
Resolution: Fixed
-
None
-
None
Description
At the moment, the following fails:
def test_serializaton_callback_error(): class TempClass(object): pass # Have a SerializationContext but TempClass is not # registered serialization_context = pa.SerializationContext() with pytest.raises(pa.SerializationCallbackError): serialized_object = pa.serialize(TempClass, serialization_context)
This is because serialize will raise a generic ArrowException instead of a SerializationCallbackError. We do need the latter because it contains the object that couldn't be serialized, which is important to give good error messages; in the case of Ray we sometimes want use the object to register additional serialization callbacks on the fly to make the user experience smoother.