You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hey @bmuller. As you can probably already tell, I've been reading a fair bit of your work in the past few days. :-)
Right now I'm trying to understand (and maybe help you to write a docstring for) RPCProtocol.getattr.
If I understand correctly, it behaves normally for attrs which begin with "_" or "rpc_".
For others, it behaves normally if they exist but otherwise, instead of raising AttributeError, it returns a closure that will attempt to call the function on a remote node?
The text was updated successfully, but these errors were encountered:
If I understand correctly, it behaves normally for attrs which begin with "" or "rpc".
Exactly
For others, it behaves normally if they exist but otherwise, instead of raising AttributeError, it returns a closure that will attempt to call the function on a remote node?
Yep. The idea is you call protocol.doSomething(args) which then sends a message to a remote node, and on the remote node the method other_protocol.rpc_doSomething(args) is then called and the result is sent back (see here for where rpc_doSomething is looked up).
A PR for a docstring on getattr would be quickly accepted :)
And btw - for general questions like this - please feel free to email me directly at the addy on my github profile.
Hey @bmuller. As you can probably already tell, I've been reading a fair bit of your work in the past few days. :-)
Right now I'm trying to understand (and maybe help you to write a docstring for) RPCProtocol.getattr.
If I understand correctly, it behaves normally for attrs which begin with
"_"
or"rpc_"
.For others, it behaves normally if they exist but otherwise, instead of raising
AttributeError
, it returns a closure that will attempt to call the function on a remote node?The text was updated successfully, but these errors were encountered: