for latest js zerorpc version v0.9.8
:
# npm list zerorpc
xxx/electron-python-example
└── zerorpc@0.9.8
and latest python zerorpc version v0.6.3
# pip show zerorpc
Name: zerorpc
Version: 0.6.3
Summary: zerorpc is a flexible RPC based on zeromq.
Home-page: https://github.com/0rpc/zerorpc-python
Author: François-Xavier Bourlet <bombela+zerorpc@gmail.com>.
Author-email: UNKNOWN
License: MIT
Location: xxx/venv/lib/python3.8/site-packages
Requires: msgpack, future, pyzmq, gevent
Required-by:
which provide you already said the heartbeatInterval
.
so my here using code electron-python-example/renderer.js
:
const constLargeEnoughHeartbeat = 60 * 60 * 24 * 30 * 12 // 1 Year
clientOptions = {
"heartbeatInterval": constLargeEnoughHeartbeat,
}
let client = new zerorpc.Client(clientOptions)
can implement you expected: large enough to 1 year heartbeat -> so longer than 10s, js and python still running, no more error
- js:
invoke startSaver: error=Error: Lost remote after 10000ms
- python:
zerorpc.exceptions.LostRemote: Lost remote after 10s heartbeat