@dxos/client-services 0.1.0 → 0.1.1

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/client-services",
3
- "version": "0.1.0",
3
+ "version": "0.1.1",
4
4
  "homepage": "https://dxos.org",
5
5
  "bugs": "https://github.com/dxos/dxos/issues",
6
6
  "license": "MIT",
@@ -15,28 +15,28 @@
15
15
  "src"
16
16
  ],
17
17
  "dependencies": {
18
- "@dxos/async": "0.1.0",
19
- "@dxos/codec-protobuf": "0.1.0",
20
- "@dxos/config": "0.1.0",
21
- "@dxos/credentials": "0.1.0",
22
- "@dxos/crypto": "0.1.0",
23
- "@dxos/debug": "0.1.0",
24
- "@dxos/echo-db": "0.1.0",
25
- "@dxos/feed-store": "0.1.0",
26
- "@dxos/keyring": "0.1.0",
27
- "@dxos/keys": "0.1.0",
28
- "@dxos/log": "0.1.0",
29
- "@dxos/messaging": "0.1.0",
30
- "@dxos/model-factory": "0.1.0",
31
- "@dxos/network-manager": "0.1.0",
32
- "@dxos/object-model": "0.1.0",
33
- "@dxos/protocol-plugin-rpc": "0.1.0",
34
- "@dxos/protocols": "0.1.0",
35
- "@dxos/random-access-storage": "0.1.0",
36
- "@dxos/rpc": "0.1.0",
37
- "@dxos/testutils": "0.1.0",
38
- "@dxos/timeframe": "0.1.0",
39
- "@dxos/util": "0.1.0",
18
+ "@dxos/async": "0.1.1",
19
+ "@dxos/codec-protobuf": "0.1.1",
20
+ "@dxos/config": "0.1.1",
21
+ "@dxos/credentials": "0.1.1",
22
+ "@dxos/crypto": "0.1.1",
23
+ "@dxos/debug": "0.1.1",
24
+ "@dxos/echo-db": "0.1.1",
25
+ "@dxos/feed-store": "0.1.1",
26
+ "@dxos/keyring": "0.1.1",
27
+ "@dxos/keys": "0.1.1",
28
+ "@dxos/log": "0.1.1",
29
+ "@dxos/messaging": "0.1.1",
30
+ "@dxos/model-factory": "0.1.1",
31
+ "@dxos/network-manager": "0.1.1",
32
+ "@dxos/object-model": "0.1.1",
33
+ "@dxos/protocol-plugin-rpc": "0.1.1",
34
+ "@dxos/protocols": "0.1.1",
35
+ "@dxos/random-access-storage": "0.1.1",
36
+ "@dxos/rpc": "0.1.1",
37
+ "@dxos/testutils": "0.1.1",
38
+ "@dxos/timeframe": "0.1.1",
39
+ "@dxos/util": "0.1.1",
40
40
  "abstract-leveldown": "~7.0.0",
41
41
  "assert": "^2.0.0",
42
42
  "base-x": "~3.0.9",
@@ -46,7 +46,7 @@
46
46
  "memdown": "^5.1.0"
47
47
  },
48
48
  "devDependencies": {
49
- "@dxos/signal": "0.1.0",
49
+ "@dxos/signal": "0.1.1",
50
50
  "@types/json-stable-stringify": "^1.0.32",
51
51
  "@types/level-js": "~4.0.1",
52
52
  "@types/memdown": "^3.0.0",
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=observable.test.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"observable.test.d.ts","sourceRoot":"","sources":["../../../../src/packlets/invitations/observable.test.ts"],"names":[],"mappings":""}
@@ -1,43 +0,0 @@
1
- "use strict";
2
- //
3
- // Copyright 2022 DXOS.org
4
- //
5
- Object.defineProperty(exports, "__esModule", { value: true });
6
- const chai_1 = require("chai");
7
- const async_1 = require("@dxos/async");
8
- describe('observable', function () {
9
- it('sanity', function () {
10
- // TODO(burdon): Testing.
11
- const _ = async (space, spaceInvitations) => {
12
- // Impl.
13
- const doTest = () => {
14
- const observable = new async_1.ObservableImpl();
15
- (0, async_1.asyncCatch)(async () => {
16
- setTimeout(() => {
17
- var _a;
18
- (_a = observable.callbacks) === null || _a === void 0 ? void 0 : _a.onConnect({});
19
- }, 100);
20
- }, observable, 30000);
21
- return observable;
22
- };
23
- // TODO(burdon): Ability to cancel.
24
- // Caller.
25
- const observable = doTest();
26
- observable.subscribe({
27
- onConnect: (invitation) => {
28
- console.log(invitation);
29
- },
30
- onComplete: () => { },
31
- onReject: () => { },
32
- onTimeout: (err) => {
33
- console.log(err);
34
- },
35
- onError: (err) => {
36
- console.log(err);
37
- }
38
- });
39
- };
40
- (0, chai_1.expect)(true).to.be.true;
41
- });
42
- });
43
- //# sourceMappingURL=observable.test.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"observable.test.js","sourceRoot":"","sources":["../../../../src/packlets/invitations/observable.test.ts"],"names":[],"mappings":";AAAA,EAAE;AACF,0BAA0B;AAC1B,EAAE;;AAEF,+BAA8B;AAE9B,uCAAqF;AAkBrF,QAAQ,CAAC,YAAY,EAAE;IACrB,EAAE,CAAC,QAAQ,EAAE;QACX,yBAAyB;QACzB,MAAM,CAAC,GAAG,KAAK,EAAE,KAAY,EAAE,gBAAkC,EAAE,EAAE;YACnE,QAAQ;YACR,MAAM,MAAM,GAAG,GAAyB,EAAE;gBACxC,MAAM,UAAU,GAAG,IAAI,sBAAc,EAAoB,CAAC;gBAE1D,IAAA,kBAAU,EACR,KAAK,IAAI,EAAE;oBACT,UAAU,CAAC,GAAG,EAAE;;wBACd,MAAA,UAAU,CAAC,SAAS,0CAAE,SAAS,CAAC,EAA0B,CAAC,CAAC;oBAC9D,CAAC,EAAE,GAAG,CAAC,CAAC;gBACV,CAAC,EACD,UAAU,EACV,KAAM,CACP,CAAC;gBAEF,OAAO,UAAU,CAAC;YACpB,CAAC,CAAC;YAEF,mCAAmC;YAEnC,UAAU;YACV,MAAM,UAAU,GAAG,MAAM,EAAE,CAAC;YAC5B,UAAU,CAAC,SAAS,CAAC;gBACnB,SAAS,EAAE,CAAC,UAAU,EAAE,EAAE;oBACxB,OAAO,CAAC,GAAG,CAAC,UAAU,CAAC,CAAC;gBAC1B,CAAC;gBACD,UAAU,EAAE,GAAG,EAAE,GAAE,CAAC;gBACpB,QAAQ,EAAE,GAAG,EAAE,GAAE,CAAC;gBAClB,SAAS,EAAE,CAAC,GAAG,EAAE,EAAE;oBACjB,OAAO,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;gBACnB,CAAC;gBACD,OAAO,EAAE,CAAC,GAAU,EAAE,EAAE;oBACtB,OAAO,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;gBACnB,CAAC;aACF,CAAC,CAAC;QACL,CAAC,CAAC;QAEF,IAAA,aAAM,EAAC,IAAI,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,IAAI,CAAC;IAC1B,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"}
@@ -1,67 +0,0 @@
1
- //
2
- // Copyright 2022 DXOS.org
3
- //
4
-
5
- import { expect } from 'chai';
6
-
7
- import { asyncCatch, AsyncCallbacks, Observable, ObservableImpl } from '@dxos/async';
8
- import { Space } from '@dxos/echo-db';
9
- import { InvitationDescriptor } from '@dxos/protocols/proto/dxos/halo/invitations';
10
-
11
- // TODO(burdon): Timeout.
12
- // TODO(burdon): Objective: Service impl pattern with clean open/close semantics.
13
- // TODO(burdon): Isolate deps on protocol throughout echo-db.
14
-
15
- import { SpaceInvitations } from './space-invitations';
16
-
17
- interface InvitationEvents extends AsyncCallbacks {
18
- onConnect(invitation: InvitationDescriptor): void;
19
- onComplete(): void;
20
- onReject(): void;
21
- }
22
-
23
- type InvitationObservable = Observable<InvitationEvents>;
24
-
25
- describe('observable', function () {
26
- it('sanity', function () {
27
- // TODO(burdon): Testing.
28
- const _ = async (space: Space, spaceInvitations: SpaceInvitations) => {
29
- // Impl.
30
- const doTest = (): InvitationObservable => {
31
- const observable = new ObservableImpl<InvitationEvents>();
32
-
33
- asyncCatch(
34
- async () => {
35
- setTimeout(() => {
36
- observable.callbacks?.onConnect({} as InvitationDescriptor);
37
- }, 100);
38
- },
39
- observable,
40
- 30_000
41
- );
42
-
43
- return observable;
44
- };
45
-
46
- // TODO(burdon): Ability to cancel.
47
-
48
- // Caller.
49
- const observable = doTest();
50
- observable.subscribe({
51
- onConnect: (invitation) => {
52
- console.log(invitation);
53
- },
54
- onComplete: () => {},
55
- onReject: () => {},
56
- onTimeout: (err) => {
57
- console.log(err);
58
- },
59
- onError: (err: Error) => {
60
- console.log(err);
61
- }
62
- });
63
- };
64
-
65
- expect(true).to.be.true;
66
- });
67
- });