nxt.remote.server module

exception NxtServerException(err, tb, layer_path, err_path, lineno, bad_line, err_depth=0)[source]

Bases: nxt.runtime.GraphError

class NxtServer(address, allow_none=True, log_requests=False)[source]

Bases: socketserver.ThreadingMixIn, xmlrpc.server.SimpleXMLRPCServer

class ServerFunctions(log_filepath)[source]

Bases: object

get_log_location()[source]

Simple method for getting the filepath of the file the server is logging to. May be an empty string if the server isn’t logging to a custom filepath. :return: str

static is_alive()[source]

Simple method for clients to use to check if the server is still alive. :return: True

static exec_in_headless(filepath, start_node, cache_path, parameters, context_name)[source]

Executed the given graph (filepath) with the given start_node in the dcc exe (as a sub-process). The temp path (if provided) must be a location that the server can read/write. If no temp path is given one will be generated. The file at the temp path is used to store the cache data to be returned to the caller. Only the file path is returned to the caller, not the actual data. :param filepath: Path to nxt save file :param start_node: start node path :param cache_path: Path to store output cache data (if none is given one will be generated) :param parameters: Optional parameters dict :param context_name: name of context, defaults to python :return: filepath to temp file

kill()[source]

Shuts down the running rpc server and attemps to remove the server log file if there is one. :return: None

secure_address()[source]
run_server(address=None, log_requests=False)[source]