hypha-rpc 0.21.40 → 0.21.42

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -86,7 +86,7 @@
86
86
  <div class='footer quiet pad2 space-top1 center small'>
87
87
  Code coverage generated by
88
88
  <a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
89
- at 2026-04-18T12:07:11.181Z
89
+ at 2026-06-13T16:17:55.291Z
90
90
  </div>
91
91
  <script src="prettify.js"></script>
92
92
  <script>
@@ -3365,6 +3365,14 @@ async function _connectToServerHTTP(config) {
3365
3365
  if (_getService.__schema__) {
3366
3366
  wm.getService.__schema__ = _getService.__schema__;
3367
3367
  }
3368
+ // Share the underlying RemoteFunction's encoded object so the
3369
+ // manager_refreshed retarget loop (which iterates wm[key].__rpc_object__)
3370
+ // can update getService's _rtarget after reconnection. Without this the
3371
+ // wrapper hides the original method and getService keeps a stale
3372
+ // "*/<old_manager_id>" target, causing a 400 on the next call.
3373
+ if (_getService.__rpc_object__) {
3374
+ wm.getService.__rpc_object__ = _getService.__rpc_object__;
3375
+ }
3368
3376
 
3369
3377
  async function serve() {
3370
3378
  await new Promise(() => {}); // Wait forever
@@ -11520,6 +11528,13 @@ async function connectToServer(config) {
11520
11528
  description,
11521
11529
  parameters,
11522
11530
  });
11531
+ // webrtcGetService routes through _wm.getService (the original
11532
+ // RemoteFunction captured in the shallow copy). Share its encoded object
11533
+ // so the manager_refreshed retarget loop updates the manager target it
11534
+ // uses after reconnection, instead of leaving a stale "*/<old_manager_id>".
11535
+ if (_wm.getService && _wm.getService.__rpc_object__) {
11536
+ wm.getService.__rpc_object__ = _wm.getService.__rpc_object__;
11537
+ }
11523
11538
 
11524
11539
  wm.getRTCService = (0,_utils_schema_js__WEBPACK_IMPORTED_MODULE_3__.schemaFunction)(_webrtc_client_js__WEBPACK_IMPORTED_MODULE_4__.getRTCService.bind(null, wm), {
11525
11540
  name: "getRTCService",
@@ -11548,6 +11563,12 @@ async function connectToServer(config) {
11548
11563
  return svc;
11549
11564
  };
11550
11565
  wm.getService.__schema__ = _getService.__schema__;
11566
+ // Share the underlying RemoteFunction's encoded object so the
11567
+ // manager_refreshed retarget loop can update getService's _rtarget after
11568
+ // reconnection (otherwise the wrapper retains a stale manager target).
11569
+ if (_getService.__rpc_object__) {
11570
+ wm.getService.__rpc_object__ = _getService.__rpc_object__;
11571
+ }
11551
11572
  }
11552
11573
 
11553
11574
  async function registerProbes(probes) {