MCPcopy Create free account
hub / github.com/AcademySoftwareFoundation/xstudio / py_remote_spawn

Method py_remote_spawn

src/python_module/src/py_context.cpp:195–209  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

193}
194
195caf::actor py_context::py_remote_spawn(const py::args &xs) {
196 if (xs.size() < 1) {
197 set_py_exception("Too few arguments to call py_remote_spawn");
198 return {};
199 }
200 auto i = xs.begin();
201 auto name = (*i).cast<std::string>();
202 auto msg = py_build_message(xs);
203 auto remote = system_.middleman().remote_spawn<caf::actor>(
204 remote_.node(), name, *msg, std::chrono::seconds(30));
205 if (remote)
206 return *remote;
207 set_py_exception("Failed to spawn remote actor.");
208 return {};
209}
210
211// void py_context::py_join(const py::args &xs) {
212// if (xs.size() < 1) {

Callers

nothing calls this directly

Calls 4

set_py_exceptionFunction · 0.85
secondsFunction · 0.85
sizeMethod · 0.45
beginMethod · 0.45

Tested by

no test coverage detected