Null pointer for ray object reference

How severe does this issue affect your experience of using Ray?

  • Medium: It contributes to significant difficulty to complete my task, but I can work around it.

I am trying to read multiple data from a list of paths. Imagine that there might be paths that does not exist. Normally in local functions, the function could just return None indicating that the path does not exist. However, for ray remote functions, the return object is always wrapped as object reference, and there is no way to tell if such address contains None until getting the object to local using ray.get().

In C++ there is null pointer that can solve this problem, is it possible to have this in ray object reference?

@kentropy obj ref doesn’t have the concept as null ptr. In application layer, even it’s null, it’s still a value.

I think for you case, you can try this. For example, you can return two objects, one is the indicator whether there is value or not and the other one is the actually value.

With this, you can ray.get the first one to avoid the data copying.