@dxos/rpc 0.8.4-main.f9ba587 → 0.8.4-main.fd6878d

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dxos/rpc",
3
- "version": "0.8.4-main.f9ba587",
3
+ "version": "0.8.4-main.fd6878d",
4
4
  "description": "A lightweight, transport-agnostic RPC implementation",
5
5
  "homepage": "https://dxos.org",
6
6
  "bugs": "https://github.com/dxos/dxos/issues",
@@ -10,6 +10,7 @@
10
10
  "type": "module",
11
11
  "exports": {
12
12
  ".": {
13
+ "source": "./src/index.ts",
13
14
  "types": "./dist/types/src/index.d.ts",
14
15
  "browser": "./dist/lib/browser/index.mjs",
15
16
  "node": "./dist/lib/node-esm/index.mjs"
@@ -24,14 +25,14 @@
24
25
  "src"
25
26
  ],
26
27
  "dependencies": {
27
- "@dxos/async": "0.8.4-main.f9ba587",
28
- "@dxos/codec-protobuf": "0.8.4-main.f9ba587",
29
- "@dxos/debug": "0.8.4-main.f9ba587",
30
- "@dxos/invariant": "0.8.4-main.f9ba587",
31
- "@dxos/node-std": "0.8.4-main.f9ba587",
32
- "@dxos/protocols": "0.8.4-main.f9ba587",
33
- "@dxos/util": "0.8.4-main.f9ba587",
34
- "@dxos/log": "0.8.4-main.f9ba587"
28
+ "@dxos/async": "0.8.4-main.fd6878d",
29
+ "@dxos/codec-protobuf": "0.8.4-main.fd6878d",
30
+ "@dxos/debug": "0.8.4-main.fd6878d",
31
+ "@dxos/log": "0.8.4-main.fd6878d",
32
+ "@dxos/invariant": "0.8.4-main.fd6878d",
33
+ "@dxos/node-std": "0.8.4-main.fd6878d",
34
+ "@dxos/protocols": "0.8.4-main.fd6878d",
35
+ "@dxos/util": "0.8.4-main.fd6878d"
35
36
  },
36
37
  "publishConfig": {
37
38
  "access": "public"
package/src/index.ts CHANGED
@@ -2,8 +2,8 @@
2
2
  // Copyright 2021 DXOS.org
3
3
  //
4
4
 
5
- export * from './rpc';
6
5
  export * from './errors';
6
+ export * from './rpc';
7
7
  export * from './service';
8
8
  export * from './testing';
9
9
  export * from './trace';
package/src/rpc.ts CHANGED
@@ -2,12 +2,12 @@
2
2
  // Copyright 2021 DXOS.org
3
3
  //
4
4
 
5
- import { asyncTimeout, synchronized, Trigger } from '@dxos/async';
6
- import { type Any, Stream, type RequestOptions, type ProtoCodec } from '@dxos/codec-protobuf';
5
+ import { Trigger, asyncTimeout, synchronized } from '@dxos/async';
6
+ import { type Any, type ProtoCodec, type RequestOptions, Stream } from '@dxos/codec-protobuf';
7
7
  import { StackTrace } from '@dxos/debug';
8
8
  import { invariant } from '@dxos/invariant';
9
9
  import { log } from '@dxos/log';
10
- import { encodeError, RpcClosedError, RpcNotOpenError } from '@dxos/protocols';
10
+ import { RpcClosedError, RpcNotOpenError, encodeError } from '@dxos/protocols';
11
11
  import { schema } from '@dxos/protocols/proto';
12
12
  import { type Request, type Response, type RpcMessage } from '@dxos/protocols/proto/dxos/rpc';
13
13
  import { exponentialBackoffInterval } from '@dxos/util';
@@ -4,17 +4,17 @@
4
4
 
5
5
  import { beforeEach, describe, expect, test } from 'vitest';
6
6
 
7
- import { sleep, latch } from '@dxos/async';
7
+ import { latch, sleep } from '@dxos/async';
8
8
  import { Stream } from '@dxos/codec-protobuf/stream';
9
9
  import { SystemError } from '@dxos/protocols';
10
10
  import { schema } from '@dxos/protocols/proto';
11
11
  import {
12
- type TestStreamService,
13
12
  type TestRpcResponse,
14
13
  type TestService,
14
+ type TestStreamService,
15
15
  } from '@dxos/protocols/proto/example/testing/rpc';
16
16
 
17
- import { createProtoRpcPeer, type ProtoRpcPeer, createServiceBundle } from './service';
17
+ import { type ProtoRpcPeer, createProtoRpcPeer, createServiceBundle } from './service';
18
18
  import { createLinkedPorts, encodeMessage } from './testing';
19
19
 
20
20
  // TODO(dmaretskyi): Rename alice and bob to peer1 and peer2.