-
Notifications
You must be signed in to change notification settings - Fork 5.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Client] Provide common ObjectRefType #14042
Comments
Related to modin-project/modin#2688 |
Hey guys, can you verify if this example works with current nightlies - https://docs.ray.io/en/master/modin/index.html#modin-with-the-ray-client? I run into this issue when I try to load Modin csv's or parquets using ray client. Here's the corresponding issue on Modin's side - modin-project/modin#2688 |
This turns out to be quite tricky to do, since ObjectRef is a native cdef that depends on the C++ runtime. Would the following workaround work?
Then you can type check around ObjectRefType instead of ObjectRef directly. |
Yes, that will work for our purposes. Something like: from ray import ObjectRefType
assert isinstance(myobj, ObjectRefType) edit: Did you mean from Ray or within our code to add this line? |
@devin-petersohn it seems there are some
In the short term, I'd recommend implementing a custom is_object_ref_type function in Modin that checks if it's either ObjectRef or ClientObjectRef to unblock Ray client users. In Ray 1.3 we can add either |
Sounds good @ericl, we'll do that. |
Moving to core bugs for tracking |
Would it be possible to only have a single If the implementation requires it, the |
It's a possibility, we'd have to look into how much refactoring is needed, since ObjectRef is a Cython type. |
Describe your feature request
We do a lot of defensive type checking in Modin when using Ray to make sure that things are working. It would be very convenient if
ClientObjectRef
extendedObjectRef
so that assertions likeassert(isinstance(obj, ray.ObjectRef))
would still work without needing to handle the Client object separately.The text was updated successfully, but these errors were encountered: