@dxos/client-services 0.1.10 → 0.1.11
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/dist/src/index.d.ts +0 -1
- package/dist/src/index.d.ts.map +1 -1
- package/dist/src/index.js +0 -1
- package/dist/src/index.js.map +1 -1
- package/dist/src/packlets/deprecated/space.d.ts.map +1 -1
- package/dist/src/packlets/deprecated/space.js +21 -21
- package/dist/src/packlets/deprecated/space.js.map +1 -1
- package/dist/src/packlets/deprecated/system.d.ts +3 -1
- package/dist/src/packlets/deprecated/system.d.ts.map +1 -1
- package/dist/src/packlets/deprecated/system.js +3 -4
- package/dist/src/packlets/deprecated/system.js.map +1 -1
- package/dist/src/packlets/devtools/feeds.d.ts.map +1 -1
- package/dist/src/packlets/devtools/feeds.js +2 -1
- package/dist/src/packlets/devtools/feeds.js.map +1 -1
- package/dist/src/packlets/devtools/spaces.d.ts.map +1 -1
- package/dist/src/packlets/devtools/spaces.js +2 -1
- package/dist/src/packlets/devtools/spaces.js.map +1 -1
- package/dist/src/packlets/identity/authenticator.js +3 -3
- package/dist/src/packlets/identity/authenticator.js.map +1 -1
- package/dist/src/packlets/identity/identity-manager.js +5 -5
- package/dist/src/packlets/identity/identity-manager.js.map +1 -1
- package/dist/src/packlets/identity/identity.js +1 -1
- package/dist/src/packlets/identity/identity.js.map +1 -1
- package/dist/src/packlets/invitations/halo-invitations-handler.d.ts +2 -2
- package/dist/src/packlets/invitations/halo-invitations-handler.d.ts.map +1 -1
- package/dist/src/packlets/invitations/halo-invitations-handler.js +13 -13
- package/dist/src/packlets/invitations/halo-invitations-handler.js.map +1 -1
- package/dist/src/packlets/invitations/invitations-handler.d.ts +3 -3
- package/dist/src/packlets/invitations/invitations-handler.d.ts.map +1 -1
- package/dist/src/packlets/invitations/invitations-proxy.d.ts +2 -2
- package/dist/src/packlets/invitations/invitations-proxy.d.ts.map +1 -1
- package/dist/src/packlets/invitations/invitations-proxy.js +2 -2
- package/dist/src/packlets/invitations/invitations-proxy.js.map +1 -1
- package/dist/src/packlets/invitations/invitations-service.js +10 -10
- package/dist/src/packlets/invitations/invitations-service.js.map +1 -1
- package/dist/src/packlets/invitations/invitations.d.ts +6 -9
- package/dist/src/packlets/invitations/invitations.d.ts.map +1 -1
- package/dist/src/packlets/invitations/invitations.js +6 -5
- package/dist/src/packlets/invitations/invitations.js.map +1 -1
- package/dist/src/packlets/invitations/space-invitations-handler.d.ts +2 -2
- package/dist/src/packlets/invitations/space-invitations-handler.d.ts.map +1 -1
- package/dist/src/packlets/invitations/space-invitations-handler.js +15 -13
- package/dist/src/packlets/invitations/space-invitations-handler.js.map +1 -1
- package/dist/src/packlets/services/service-context.d.ts +1 -1
- package/dist/src/packlets/services/service-context.d.ts.map +1 -1
- package/dist/src/packlets/services/service-context.js +10 -6
- package/dist/src/packlets/services/service-context.js.map +1 -1
- package/dist/src/packlets/services/service-host.d.ts +6 -2
- package/dist/src/packlets/services/service-host.d.ts.map +1 -1
- package/dist/src/packlets/services/service-host.js +33 -25
- package/dist/src/packlets/services/service-host.js.map +1 -1
- package/dist/src/packlets/services/service-proxy.d.ts.map +1 -1
- package/dist/src/packlets/services/service-proxy.js +1 -1
- package/dist/src/packlets/services/service-proxy.js.map +1 -1
- package/dist/src/packlets/services/service-registry.test.js +3 -3
- package/dist/src/packlets/services/service-registry.test.js.map +1 -1
- package/dist/src/packlets/storage/storage.d.ts.map +1 -1
- package/dist/src/packlets/storage/storage.js +6 -6
- package/dist/src/packlets/storage/storage.js.map +1 -1
- package/dist/src/packlets/testing/test-builder.js +1 -1
- package/dist/src/packlets/testing/test-builder.js.map +1 -1
- package/dist/src/packlets/vault/worker-session.js +3 -3
- package/dist/src/packlets/vault/worker-session.js.map +1 -1
- package/package.json +28 -28
- package/src/index.ts +0 -2
- package/src/packlets/deprecated/space.ts +21 -20
- package/src/packlets/deprecated/system.ts +4 -4
- package/src/packlets/devtools/feeds.ts +2 -1
- package/src/packlets/devtools/spaces.ts +2 -1
- package/src/packlets/invitations/halo-invitations-handler.ts +2 -2
- package/src/packlets/invitations/invitations-handler.ts +3 -3
- package/src/packlets/invitations/invitations-proxy.ts +2 -2
- package/src/packlets/invitations/invitations.ts +6 -11
- package/src/packlets/invitations/space-invitations-handler.ts +4 -2
- package/src/packlets/services/service-context.ts +7 -2
- package/src/packlets/services/service-host.ts +42 -29
- package/src/packlets/services/service-proxy.ts +1 -1
- package/src/packlets/storage/storage.ts +6 -6
- package/src/packlets/testing/test-builder.ts +1 -1
- package/testing.d.ts +11 -0
- package/testing.js +5 -0
- package/dist/src/errors.d.ts +0 -8
- package/dist/src/errors.d.ts.map +0 -1
- package/dist/src/errors.js +0 -21
- package/dist/src/errors.js.map +0 -1
- package/src/errors.ts +0 -19
package/dist/src/index.d.ts
CHANGED
package/dist/src/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAIA,cAAc,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAIA,cAAc,uBAAuB,CAAC;AACtC,cAAc,qBAAqB,CAAC;AACpC,cAAc,qBAAqB,CAAC;AACpC,cAAc,wBAAwB,CAAC;AACvC,cAAc,qBAAqB,CAAC;AACpC,cAAc,oBAAoB,CAAC;AACnC,cAAc,kBAAkB,CAAC"}
|
package/dist/src/index.js
CHANGED
|
@@ -17,7 +17,6 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
17
17
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
18
18
|
};
|
|
19
19
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
20
|
-
__exportStar(require("./errors"), exports);
|
|
21
20
|
__exportStar(require("./packlets/deprecated"), exports);
|
|
22
21
|
__exportStar(require("./packlets/devtools"), exports);
|
|
23
22
|
__exportStar(require("./packlets/identity"), exports);
|
package/dist/src/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";AAAA,EAAE;AACF,0BAA0B;AAC1B,EAAE;;;;;;;;;;;;;;;;AAEF,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";AAAA,EAAE;AACF,0BAA0B;AAC1B,EAAE;;;;;;;;;;;;;;;;AAEF,wDAAsC;AACtC,sDAAoC;AACpC,sDAAoC;AACpC,yDAAuC;AACvC,sDAAoC;AACpC,qDAAmC;AACnC,mDAAiC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"space.d.ts","sourceRoot":"","sources":["../../../../src/packlets/deprecated/space.ts"],"names":[],"mappings":"AAOA,OAAO,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;
|
|
1
|
+
{"version":3,"file":"space.d.ts","sourceRoot":"","sources":["../../../../src/packlets/deprecated/space.ts"],"names":[],"mappings":"AAOA,OAAO,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;AAG9C,OAAO,EACL,6BAA6B,EAC7B,qBAAqB,EACrB,sBAAsB,EACtB,KAAK,EACL,YAAY,EACZ,YAAY,EACZ,oBAAoB,EACpB,uBAAuB,EACvB,wBAAwB,EACxB,uBAAuB,EACvB,qBAAqB,EACrB,sBAAsB,EACvB,MAAM,mCAAmC,CAAC;AAC3C,OAAO,EAAE,aAAa,EAAE,MAAM,0CAA0C,CAAC;AAGzE,OAAO,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAG7C;;;GAGG;AACH,qBAAa,gBAAiB,YAAW,YAAY;IAGvC,OAAO,CAAC,QAAQ,CAAC,cAAc;IAF3C,OAAO,CAAC,kBAAkB,CAAiC;gBAE9B,cAAc,EAAE,cAAc;IAE3D,gBAAgB,CAAC,OAAO,EAAE,qBAAqB,GAAG,MAAM,CAAC,sBAAsB,CAAC;IAuDhF,eAAe;IAkDT,eAAe,CAAC,OAAO,EAAE,sBAAsB,GAAG,OAAO,CAAC,YAAY,CAAC;IAQvE,WAAW,IAAI,OAAO,CAAC,KAAK,CAAC;IAU7B,UAAU,CAAC,QAAQ,EAAE,aAAa,GAAG,OAAO,CAAC,KAAK,CAAC;IAUnD,aAAa,CAAC,OAAO,EAAE,oBAAoB;IA+B3C,sBAAsB,CAAC,OAAO,EAAE,6BAA6B;IAWnE,gBAAgB,CAAC,OAAO,EAAE,uBAAuB,GAAG,MAAM,CAAC,wBAAwB,CAAC;IAyB9E,cAAc,CAAC,OAAO,EAAE,qBAAqB,GAAG,OAAO,CAAC,aAAa,CAAC;CAM7E"}
|
|
@@ -11,6 +11,7 @@ const node_assert_1 = __importDefault(require("node:assert"));
|
|
|
11
11
|
const async_1 = require("@dxos/async");
|
|
12
12
|
const codec_protobuf_1 = require("@dxos/codec-protobuf");
|
|
13
13
|
const debug_1 = require("@dxos/debug");
|
|
14
|
+
const log_1 = require("@dxos/log");
|
|
14
15
|
const util_1 = require("@dxos/util");
|
|
15
16
|
/**
|
|
16
17
|
* Space service implementation.
|
|
@@ -75,23 +76,23 @@ class SpaceServiceImpl {
|
|
|
75
76
|
return new codec_protobuf_1.Stream(({ next }) => {
|
|
76
77
|
const subscriptions = new async_1.EventSubscriptions();
|
|
77
78
|
const onUpdate = () => {
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
79
|
+
const spaces = Array.from(this.serviceContext.spaceManager.spaces.values()).map((space) => ({
|
|
80
|
+
publicKey: space.key,
|
|
81
|
+
isOpen: true,
|
|
82
|
+
isActive: true,
|
|
83
|
+
members: Array.from(space.spaceState.members.values()).map((member) => {
|
|
84
|
+
var _a, _b;
|
|
85
|
+
return ({
|
|
86
|
+
identityKey: member.key,
|
|
87
|
+
profile: {
|
|
86
88
|
identityKey: member.key,
|
|
87
|
-
profile:
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
});
|
|
89
|
+
displayName: (_b = (_a = member.assertion.profile) === null || _a === void 0 ? void 0 : _a.displayName) !== null && _b !== void 0 ? _b : (0, util_1.humanize)(member.key)
|
|
90
|
+
}
|
|
91
|
+
});
|
|
92
|
+
})
|
|
93
|
+
}));
|
|
94
|
+
(0, log_1.log)('update', { spaces }, { file: "packages/sdk/client-services/src/packlets/deprecated/space.ts", line: 114, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation.", callSite: (fn, args) => fn(...args) });
|
|
95
|
+
next({ spaces });
|
|
95
96
|
};
|
|
96
97
|
setTimeout(async () => {
|
|
97
98
|
if (!this.serviceContext.spaceManager) {
|
|
@@ -104,6 +105,9 @@ class SpaceServiceImpl {
|
|
|
104
105
|
});
|
|
105
106
|
onUpdate();
|
|
106
107
|
}));
|
|
108
|
+
this.serviceContext.spaceManager.spaces.forEach((space) => {
|
|
109
|
+
subscriptions.add(space.stateUpdate.on(onUpdate));
|
|
110
|
+
});
|
|
107
111
|
onUpdate();
|
|
108
112
|
});
|
|
109
113
|
return () => subscriptions.clear();
|
|
@@ -172,11 +176,7 @@ class SpaceServiceImpl {
|
|
|
172
176
|
(_a = invitation.secretTrigger) === null || _a === void 0 ? void 0 : _a.call(invitation);
|
|
173
177
|
}
|
|
174
178
|
subscribeMembers(request) {
|
|
175
|
-
return
|
|
176
|
-
next({
|
|
177
|
-
members: []
|
|
178
|
-
});
|
|
179
|
-
});
|
|
179
|
+
return (0, debug_1.todo)();
|
|
180
180
|
// const space = this.echo.getSpace(request.space_key);
|
|
181
181
|
// if (space) {
|
|
182
182
|
// return resultSetToStream(space.queryMembers(), (members): SubscribeMembersResponse => ({ members }));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"space.js","sourceRoot":"","sources":["../../../../src/packlets/deprecated/space.ts"],"names":[],"mappings":";AAAA,EAAE;AACF,0BAA0B;AAC1B,EAAE;;;;;;AAEF,8DAAiC;AAEjC,uCAAiD;AACjD,yDAA8C;AAC9C,uCAAmC;
|
|
1
|
+
{"version":3,"file":"space.js","sourceRoot":"","sources":["../../../../src/packlets/deprecated/space.ts"],"names":[],"mappings":";AAAA,EAAE;AACF,0BAA0B;AAC1B,EAAE;;;;;;AAEF,8DAAiC;AAEjC,uCAAiD;AACjD,yDAA8C;AAC9C,uCAAmC;AACnC,mCAAgC;AAgBhC,qCAAsC;AAKtC;;;GAGG;AACH,MAAa,gBAAgB;IAG3B,YAA6B,cAA8B;QAA9B,mBAAc,GAAd,cAAc,CAAgB;QAFnD,uBAAkB,GAAuB,IAAI,GAAG,EAAE,CAAC;IAEG,CAAC;IAE/D,gBAAgB,CAAC,OAA8B;QAC7C,OAAO,IAAI,uBAAM,CAAC,CAAC,EAAE,IAAI,EAAE,EAAE,EAAE;YAC7B,IAAI,CAAC;gBACH,KAAK,EAAE;oBACL,SAAS,EAAE,OAAO,CAAC,QAAQ;oBAC3B,MAAM,EAAE,IAAI;oBACZ,QAAQ,EAAE,IAAI;oBACd,OAAO,EAAE,EAAE;iBACZ;aACF,CAAC,CAAC;QACL,CAAC,CAAC,CAAC;QAEH,wEAAwE;QACxE,UAAU;QACV,2DAA2D;QAC3D,aAAa;QACb,0BAA0B;QAC1B,iCAAiC;QACjC,kCAAkC;QAClC,sCAAsC;QACtC,8CAA8C;QAC9C,UAAU;QACV,UAAU;QACV,oBAAoB;QACpB,8CAA8C;QAC9C,uBAAuB;QACvB,eAAe;QACf,mBAAmB;QACnB,QAAQ;QACR,MAAM;QACN,KAAK;QAEL,uEAAuE;QACvE,eAAe;QACf,0EAA0E;QAC1E,WAAW;QACX,sCAAsC;QACtC,wCAAwC;QACxC,gFAAgF;QAChF,mFAAmF;QACnF,0CAA0C;QAC1C,kEAAkE;QAClE,UAAU;QAC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;QAC1C,gFAAgF;QAChF,mFAAmF;QACnF,4CAA4C;QAC5C,kDAAkD;QAClD,8CAA8C;QAC9C,8FAA8F;QAC9F,UAAU;QACV,UAAU;QAEV,qBAAqB;QACrB,6BAA6B;QAC7B,8BAA8B;QAC9B,SAAS;QACT,QAAQ;QACR,IAAI;IACN,CAAC;IAED,KAAK,CAAC,cAAc,CAAC,OAA8B;QACjD,OAAO,IAAA,YAAI,GAAE,CAAC;QACd,6BAA6B;QAC7B,2GAA2G;QAC3G,iCAAiC;IACnC,CAAC;CACF;AAnND,4CAmNC"}
|
|
@@ -1,11 +1,13 @@
|
|
|
1
1
|
import { Config } from '@dxos/config';
|
|
2
2
|
import { SystemService } from '@dxos/protocols/proto/dxos/client';
|
|
3
|
+
import { ServiceContext } from '../services';
|
|
3
4
|
/**
|
|
4
5
|
* @deprecated
|
|
5
6
|
*/
|
|
6
7
|
export declare class SystemServiceImpl implements SystemService {
|
|
7
8
|
private readonly _config;
|
|
8
|
-
|
|
9
|
+
private readonly _serviceContext;
|
|
10
|
+
constructor(_config: Config, _serviceContext: ServiceContext);
|
|
9
11
|
initSession(): Promise<void>;
|
|
10
12
|
getConfig(request: void): Promise<import("@dxos/config").ConfigProto>;
|
|
11
13
|
reset(request: any): Promise<void>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"system.d.ts","sourceRoot":"","sources":["../../../../src/packlets/deprecated/system.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,MAAM,EAAE,MAAM,cAAc,CAAC;
|
|
1
|
+
{"version":3,"file":"system.d.ts","sourceRoot":"","sources":["../../../../src/packlets/deprecated/system.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,MAAM,EAAE,MAAM,cAAc,CAAC;AACtC,OAAO,EAAE,aAAa,EAAE,MAAM,mCAAmC,CAAC;AAElE,OAAO,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAE7C;;GAEG;AACH,qBAAa,iBAAkB,YAAW,aAAa;IACzC,OAAO,CAAC,QAAQ,CAAC,OAAO;IAAU,OAAO,CAAC,QAAQ,CAAC,eAAe;gBAAjD,OAAO,EAAE,MAAM,EAAmB,eAAe,EAAE,cAAc;IAGxF,WAAW;IAIX,SAAS,CAAC,OAAO,EAAE,IAAI;IAIvB,KAAK,CAAC,OAAO,EAAE,GAAG;CAGzB"}
|
|
@@ -4,13 +4,13 @@
|
|
|
4
4
|
//
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.SystemServiceImpl = void 0;
|
|
7
|
-
const debug_1 = require("@dxos/debug");
|
|
8
7
|
/**
|
|
9
8
|
* @deprecated
|
|
10
9
|
*/
|
|
11
10
|
class SystemServiceImpl {
|
|
12
|
-
constructor(_config) {
|
|
11
|
+
constructor(_config, _serviceContext) {
|
|
13
12
|
this._config = _config;
|
|
13
|
+
this._serviceContext = _serviceContext;
|
|
14
14
|
}
|
|
15
15
|
// TODO(burdon): Remove.
|
|
16
16
|
async initSession() {
|
|
@@ -19,9 +19,8 @@ class SystemServiceImpl {
|
|
|
19
19
|
async getConfig(request) {
|
|
20
20
|
return this._config.values;
|
|
21
21
|
}
|
|
22
|
-
// TODO(burdon): Reset ServiceContext
|
|
23
22
|
async reset(request) {
|
|
24
|
-
|
|
23
|
+
await this._serviceContext.reset();
|
|
25
24
|
}
|
|
26
25
|
}
|
|
27
26
|
exports.SystemServiceImpl = SystemServiceImpl;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"system.js","sourceRoot":"","sources":["../../../../src/packlets/deprecated/system.ts"],"names":[],"mappings":";AAAA,EAAE;AACF,0BAA0B;AAC1B,EAAE;;;
|
|
1
|
+
{"version":3,"file":"system.js","sourceRoot":"","sources":["../../../../src/packlets/deprecated/system.ts"],"names":[],"mappings":";AAAA,EAAE;AACF,0BAA0B;AAC1B,EAAE;;;AAOF;;GAEG;AACH,MAAa,iBAAiB;IAC5B,YAA6B,OAAe,EAAmB,eAA+B;QAAjE,YAAO,GAAP,OAAO,CAAQ;QAAmB,oBAAe,GAAf,eAAe,CAAgB;IAAG,CAAC;IAElG,wBAAwB;IACxB,KAAK,CAAC,WAAW;QACf,MAAM;IACR,CAAC;IAED,KAAK,CAAC,SAAS,CAAC,OAAa;QAC3B,OAAO,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC;IAC7B,CAAC;IAED,KAAK,CAAC,KAAK,CAAC,OAAY;QACtB,MAAM,IAAI,CAAC,eAAe,CAAC,KAAK,EAAE,CAAC;IACrC,CAAC;CACF;AAfD,8CAeC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"feeds.d.ts","sourceRoot":"","sources":["../../../../src/packlets/devtools/feeds.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;AAC9C,OAAO,EAAgB,SAAS,EAAe,MAAM,kBAAkB,CAAC;AAExE,OAAO,EACL,uBAAuB,EACvB,wBAAwB,EACxB,4BAA4B,EAC5B,6BAA6B,EAC9B,MAAM,0CAA0C,CAAC;AAClD,OAAO,EAAE,WAAW,EAAE,MAAM,sCAAsC,CAAC;AAGnE,eAAO,MAAM,gBAAgB;eACC,UAAU,WAAW,CAAC;iBACpC,uBAAuB,qCAgCnC,CAAC;AAEL,eAAO,MAAM,qBAAqB;eACJ,UAAU,WAAW,CAAC;2BACrB,4BAA4B,
|
|
1
|
+
{"version":3,"file":"feeds.d.ts","sourceRoot":"","sources":["../../../../src/packlets/devtools/feeds.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;AAC9C,OAAO,EAAgB,SAAS,EAAe,MAAM,kBAAkB,CAAC;AAExE,OAAO,EACL,uBAAuB,EACvB,wBAAwB,EACxB,4BAA4B,EAC5B,6BAA6B,EAC9B,MAAM,0CAA0C,CAAC;AAClD,OAAO,EAAE,WAAW,EAAE,MAAM,sCAAsC,CAAC;AAGnE,eAAO,MAAM,gBAAgB;eACC,UAAU,WAAW,CAAC;iBACpC,uBAAuB,qCAgCnC,CAAC;AAEL,eAAO,MAAM,qBAAqB;eACJ,UAAU,WAAW,CAAC;2BACrB,4BAA4B,0CA0CvD,CAAC"}
|
|
@@ -42,7 +42,7 @@ const subscribeToFeedBlocks = ({ feedStore }, { feedKey, maxBlocks = 10 }) => ne
|
|
|
42
42
|
return;
|
|
43
43
|
}
|
|
44
44
|
const subscriptions = new async_1.EventSubscriptions();
|
|
45
|
-
|
|
45
|
+
const timeout = setTimeout(async () => {
|
|
46
46
|
const feed = feedStore.getFeed(feedKey);
|
|
47
47
|
if (!feed) {
|
|
48
48
|
return;
|
|
@@ -70,6 +70,7 @@ const subscribeToFeedBlocks = ({ feedStore }, { feedKey, maxBlocks = 10 }) => ne
|
|
|
70
70
|
});
|
|
71
71
|
return () => {
|
|
72
72
|
subscriptions.clear();
|
|
73
|
+
clearTimeout(timeout);
|
|
73
74
|
};
|
|
74
75
|
});
|
|
75
76
|
exports.subscribeToFeedBlocks = subscribeToFeedBlocks;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"feeds.js","sourceRoot":"","sources":["../../../../src/packlets/devtools/feeds.ts"],"names":[],"mappings":";AAAA,EAAE;AACF,0BAA0B;AAC1B,EAAE;;;AAEF,uCAAiD;AACjD,yDAA8C;AAC9C,iDAAwE;AACxE,qCAAuC;AAQvC,qCAAwC;AAEjC,MAAM,gBAAgB,GAAG,CAC9B,EAAE,SAAS,EAAyC,EACpD,EAAE,QAAQ,EAA2B,EACrC,EAAE,CACF,IAAI,uBAAM,CAA2B,CAAC,EAAE,IAAI,EAAE,EAAE,EAAE;IAChD,IAAI,CAAA,QAAQ,aAAR,QAAQ,uBAAR,QAAQ,CAAE,MAAM,MAAK,CAAC,EAAE;QAC1B,OAAO;KACR;IAED,MAAM,OAAO,GAAG,IAAI,iBAAU,CAAsC,gBAAS,CAAC,IAAI,CAAC,CAAC;IACpF,MAAM,aAAa,GAAG,IAAI,0BAAkB,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,"file":"spaces.d.ts","sourceRoot":"","sources":["../../../../src/packlets/devtools/spaces.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;AAE9C,OAAO,EAAE,wBAAwB,EAAE,yBAAyB,EAAE,MAAM,0CAA0C,CAAC;AAG/G,OAAO,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAE7C,eAAO,MAAM,iBAAiB,YAAa,cAAc,iBAAsB,wBAAwB,
|
|
1
|
+
{"version":3,"file":"spaces.d.ts","sourceRoot":"","sources":["../../../../src/packlets/devtools/spaces.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;AAE9C,OAAO,EAAE,wBAAwB,EAAE,yBAAyB,EAAE,MAAM,0CAA0C,CAAC;AAG/G,OAAO,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAE7C,eAAO,MAAM,iBAAiB,YAAa,cAAc,iBAAsB,wBAAwB,sCAwCnG,CAAC"}
|
|
@@ -24,7 +24,7 @@ const subscribeToSpaces = (context, { spaceKeys = [] }) => new codec_protobuf_1.
|
|
|
24
24
|
})
|
|
25
25
|
});
|
|
26
26
|
};
|
|
27
|
-
|
|
27
|
+
const timeout = setTimeout(async () => {
|
|
28
28
|
await context.initialized.wait();
|
|
29
29
|
unsubscribe = context.spaceManager.updated.on(() => update());
|
|
30
30
|
// Send initial spaces.
|
|
@@ -32,6 +32,7 @@ const subscribeToSpaces = (context, { spaceKeys = [] }) => new codec_protobuf_1.
|
|
|
32
32
|
});
|
|
33
33
|
return () => {
|
|
34
34
|
unsubscribe === null || unsubscribe === void 0 ? void 0 : unsubscribe();
|
|
35
|
+
clearTimeout(timeout);
|
|
35
36
|
};
|
|
36
37
|
});
|
|
37
38
|
exports.subscribeToSpaces = subscribeToSpaces;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"spaces.js","sourceRoot":"","sources":["../../../../src/packlets/devtools/spaces.ts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,CAAC;YACJ,CAAC,CAAC;SACH,CAAC,CAAC;IACL,CAAC,CAAC;IAEF,MAAM,OAAO,GAAG,UAAU,CAAC,KAAK,IAAI,EAAE;QACpC,MAAM,OAAO,CAAC,WAAW,CAAC,IAAI,EAAE,CAAC;QACjC,WAAW,GAAG,OAAO,CAAC,YAAa,CAAC,OAAO,CAAC,EAAE,CAAC,GAAG,EAAE,CAAC,MAAM,EAAE,CAAC,CAAC;QAE/D,uBAAuB;QACvB,MAAM,MAAM,EAAE,CAAC;IACjB,CAAC,CAAC,CAAC;IAEH,OAAO,GAAG,EAAE;QACV,WAAW,aAAX,WAAW,uBAAX,WAAW,EAAI,CAAC;QAChB,YAAY,CAAC,OAAO,CAAC,CAAC;IACxB,CAAC,CAAC;AACJ,CAAC,CAAC,CAAC;AAxCQ,QAAA,iBAAiB,qBAwCzB"}
|
|
@@ -23,15 +23,15 @@ const createHaloAuthVerifier = (getDeviceSet) => async (nonce, auth) => {
|
|
|
23
23
|
const deviceSet = getDeviceSet();
|
|
24
24
|
const result = await (0, credentials_1.verifyCredential)(credential);
|
|
25
25
|
if (result.kind === 'fail') {
|
|
26
|
-
(0, log_1.log)('Invalid credential', { result }, { file: "packages/sdk/client-services/src/packlets/identity/authenticator.ts", line: 34, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation." });
|
|
26
|
+
(0, log_1.log)('Invalid credential', { result }, { file: "packages/sdk/client-services/src/packlets/identity/authenticator.ts", line: 34, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation.", callSite: (fn, args) => fn(...args) });
|
|
27
27
|
return false;
|
|
28
28
|
}
|
|
29
29
|
if (!credential.proof.nonce || !Buffer.from(nonce).equals(credential.proof.nonce)) {
|
|
30
|
-
(0, log_1.log)('Invalid nonce', { nonce, credential }, { file: "packages/sdk/client-services/src/packlets/identity/authenticator.ts", line: 39, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation." });
|
|
30
|
+
(0, log_1.log)('Invalid nonce', { nonce, credential }, { file: "packages/sdk/client-services/src/packlets/identity/authenticator.ts", line: 39, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation.", callSite: (fn, args) => fn(...args) });
|
|
31
31
|
return false;
|
|
32
32
|
}
|
|
33
33
|
if (!deviceSet.has(credential.issuer)) {
|
|
34
|
-
(0, log_1.log)('Device not in allowed set', {}, { file: "packages/sdk/client-services/src/packlets/identity/authenticator.ts", line: 44, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation." });
|
|
34
|
+
(0, log_1.log)('Device not in allowed set', {}, { file: "packages/sdk/client-services/src/packlets/identity/authenticator.ts", line: 44, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation.", callSite: (fn, args) => fn(...args) });
|
|
35
35
|
return false;
|
|
36
36
|
}
|
|
37
37
|
return true;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"authenticator.js","sourceRoot":"","sources":["../../../../src/packlets/identity/authenticator.ts"],"names":[],"mappings":";AAAA,EAAE;AACF,0BAA0B;AAC1B,EAAE;;;AAEF,mDAAuE;AAGvE,mCAAgC;AAChC,+CAAyC;AAGlC,MAAM,sBAAsB,GACjC,CAAC,MAAwB,EAAgB,EAAE,CAC3C,KAAK,EAAE,KAAK,EAAE,EAAE;IACd,MAAM,UAAU,GAAG,MAAM,MAAM,CAAC,gBAAgB,CAAC;QAC/C,SAAS,EAAE;YACT,OAAO,EAAE,4BAA4B;SACtC;QACD,OAAO,EAAE,MAAM,CAAC,SAAS,EAAE;QAC3B,KAAK;KACN,CAAC,CAAC;IAEH,OAAO,kBAAM,CAAC,eAAe,CAAC,kCA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eAAe,CAAC,kCAAkC,CAAC,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC;IAC3F,MAAM,SAAS,GAAG,YAAY,EAAE,CAAC;IAEjC,MAAM,MAAM,GAAG,MAAM,IAAA,8BAAgB,EAAC,UAAU,CAAC,CAAC;IAClD,IAAI,MAAM,CAAC,IAAI,KAAK,MAAM,EAAE;QAC1B,IAAA,SAAG,EAAC,oBAAoB,EAAE,EAAE,MAAM,EAAE,sUAAC,CAAC;QACtC,OAAO,KAAK,CAAC;KACd;IAED,IAAI,CAAC,UAAU,CAAC,KAAK,CAAC,KAAK,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,MAAM,CAAC,UAAU,CAAC,KAAK,CAAC,KAAK,CAAC,EAAE;QACjF,IAAA,SAAG,EAAC,eAAe,EAAE,EAAE,KAAK,EAAE,UAAU,EAAE,sUAAC,CAAC;QAC5C,OAAO,KAAK,CAAC;KACd;IAED,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC,UAAU,CAAC,MAAM,CAAC,EAAE;QACrC,IAAA,SAAG,EAAC,2BAA2B,0UAAC,CAAC;QACjC,OAAO,KAAK,CAAC;KACd;IAED,OAAO,IAAI,CAAC;AACd,CAAC,CAAC;AAvBS,QAAA,sBAAsB,0BAuB/B"}
|
|
@@ -45,7 +45,7 @@ class IdentityManager {
|
|
|
45
45
|
}
|
|
46
46
|
async createIdentity({ displayName } = {}) {
|
|
47
47
|
(0, assert_1.default)(!this._identity, 'Identity already exists.');
|
|
48
|
-
(0, log_1.log)('creating identity...', {}, { file: "packages/sdk/client-services/src/packlets/identity/identity-manager.ts", line: 83, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation." });
|
|
48
|
+
(0, log_1.log)('creating identity...', {}, { file: "packages/sdk/client-services/src/packlets/identity/identity-manager.ts", line: 83, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation.", callSite: (fn, args) => fn(...args) });
|
|
49
49
|
const controlFeedKey = await this._keyring.createKey();
|
|
50
50
|
const identityRecord = {
|
|
51
51
|
identityKey: await this._keyring.createKey(),
|
|
@@ -87,14 +87,14 @@ class IdentityManager {
|
|
|
87
87
|
this._identity = identity;
|
|
88
88
|
await this._identity.ready();
|
|
89
89
|
this.stateUpdate.emit();
|
|
90
|
-
(0, log_1.log)('created identity', { identityKey: identity.identityKey, deviceKey: identity.deviceKey }, { file: "packages/sdk/client-services/src/packlets/identity/identity-manager.ts", line: 142, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation." });
|
|
90
|
+
(0, log_1.log)('created identity', { identityKey: identity.identityKey, deviceKey: identity.deviceKey }, { file: "packages/sdk/client-services/src/packlets/identity/identity-manager.ts", line: 142, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation.", callSite: (fn, args) => fn(...args) });
|
|
91
91
|
return identity;
|
|
92
92
|
}
|
|
93
93
|
/**
|
|
94
94
|
* Accept an existing identity. Expects it's device key to be authorized.
|
|
95
95
|
*/
|
|
96
96
|
async acceptIdentity(params) {
|
|
97
|
-
(0, log_1.log)('accepting identity', { params }, { file: "packages/sdk/client-services/src/packlets/identity/identity-manager.ts", line: 150, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation." });
|
|
97
|
+
(0, log_1.log)('accepting identity', { params }, { file: "packages/sdk/client-services/src/packlets/identity/identity-manager.ts", line: 150, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation.", callSite: (fn, args) => fn(...args) });
|
|
98
98
|
(0, assert_1.default)(!this._identity, 'Identity already exists.');
|
|
99
99
|
const identity = await this._constructIdentity({
|
|
100
100
|
identityKey: params.identityKey,
|
|
@@ -113,7 +113,7 @@ class IdentityManager {
|
|
|
113
113
|
}
|
|
114
114
|
async _constructIdentity(identityRecord) {
|
|
115
115
|
(0, assert_1.default)(!this._identity);
|
|
116
|
-
(0, log_1.log)('constructing identity', { identityRecord }, { file: "packages/sdk/client-services/src/packlets/identity/identity-manager.ts", line: 172, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation." });
|
|
116
|
+
(0, log_1.log)('constructing identity', { identityRecord }, { file: "packages/sdk/client-services/src/packlets/identity/identity-manager.ts", line: 172, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation.", callSite: (fn, args) => fn(...args) });
|
|
117
117
|
const space = await this._constructSpace({
|
|
118
118
|
spaceRecord: identityRecord.haloSpace,
|
|
119
119
|
swarmIdentity: {
|
|
@@ -122,7 +122,7 @@ class IdentityManager {
|
|
|
122
122
|
credentialAuthenticator: echo_db_1.MOCK_AUTH_VERIFIER
|
|
123
123
|
}
|
|
124
124
|
});
|
|
125
|
-
(0, log_1.log)('done', { identityKey: identityRecord.identityKey }, { file: "packages/sdk/client-services/src/packlets/identity/identity-manager.ts", line: 183, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation." });
|
|
125
|
+
(0, log_1.log)('done', { identityKey: identityRecord.identityKey }, { file: "packages/sdk/client-services/src/packlets/identity/identity-manager.ts", line: 183, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation.", callSite: (fn, args) => fn(...args) });
|
|
126
126
|
return new identity_1.Identity({
|
|
127
127
|
space,
|
|
128
128
|
signer: this._keyring,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"identity-manager.js","sourceRoot":"","sources":["../../../../src/packlets/identity/identity-manager.ts"],"names":[],"mappings":";AAA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AC,mBAAmB,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC;QACxG,MAAM,QAAQ,GAAG,MAAM,IAAI,CAAC,UAAU,CAAC,QAAQ,CAAC,WAAW,CAAC,gBAAgB,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC;QAElG,qGAAqG;QACrG,oFAAoF;QACpF,MAAM,WAAW,GAAG,MAAM,IAAI,CAAC,UAAU,CAAC,QAAQ,CAAC,WAAW,CAAC,cAAc,CAAC,CAAC;QAE/E,MAAM,QAAQ,GAAG,IAAI,uBAAa,CAAC;YACjC,KAAK,EAAE,WAAW,CAAC,QAAQ;YAC3B,QAAQ,EAAE,aAAa;YACvB,cAAc,EAAE,IAAI,CAAC,eAAe;SACrC,CAAC,CAAC;QAEH,OAAO,IAAI,eAAK,CAAC;YACf,QAAQ,EAAE,WAAW,CAAC,QAAQ;YAC9B,QAAQ;YACR,WAAW;YACX,WAAW;YACX,QAAQ;YACR,YAAY,EAAE,CAAC,OAAO,EAAE,EAAE,CAAC,IAAI,CAAC,UAAU,CAAC,QAAQ,CAAC,OAAO,CAAC;YAC5D,eAAe,EAAE,KAAK,EAAE,EAAE,eAAe,EAAE,EAAE,EAAE,CAC7C,IAAI,kBAAQ,CAAC,IAAI,CAAC,aAAa,EAAE,eAAe,EAAE,aAAa,CAAC,OAAO,CAAC;SAC3E,CAAC,CAAC;IACL,CAAC;CACF;AA3KD,0CA2KC"}
|
|
@@ -95,7 +95,7 @@ class Identity {
|
|
|
95
95
|
deviceKey,
|
|
96
96
|
controlFeedKey,
|
|
97
97
|
dataFeedKey
|
|
98
|
-
}, { file: "packages/sdk/client-services/src/packlets/identity/identity.ts", line: 137, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation." });
|
|
98
|
+
}, { file: "packages/sdk/client-services/src/packlets/identity/identity.ts", line: 137, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation.", callSite: (fn, args) => fn(...args) });
|
|
99
99
|
const signer = this.getIdentityCredentialSigner();
|
|
100
100
|
await (0, feed_store_1.writeMessages)(this.controlPipeline.writer, [
|
|
101
101
|
await signer.createCredential({
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"identity.js","sourceRoot":"","sources":["../../../../src/packlets/identity/identity.ts"],"names":[],"mappings":";AAAA,EAAE;AACF,0BAA0B;AAC1B,EAAE;;;;;;AAEF,oDAA4B;AAE5B,uCAAoC;AACpC,mDAM2B;AAE3B,uCAA4C;AAE5C,iDAAiD;AAEjD,mCAAgC;AAEhC,6EAA4F;AAW5F;;GAEG;AACH,MAAa,QAAQ;IAWnB,YAAY,EAAE,KAAK,EAAE,MAAM,EAAE,WAAW,EAAE,SAAS,EAAkB;QAFrD,gBAAW,GAAG,IAAI,aAAK,EAAE,CAAC;QAGxC,IAAI,CAAC,MAAM,GAAG,KAAK,CAAC;QACpB,IAAI,CAAC,OAAO,GAAG,MAAM,CAAC;QAEtB,IAAI,CAAC,WAAW,GAAG,WAAW,CAAC;QAC/B,IAAI,CAAC,SAAS,GAAG,SAAS,CAAC;QAE3B,IAAI,CAAC,mBAAmB,GAAG,IAAI,gCAAkB,CAAC,IAAI,CAAC,WAAW,EAAE,IAAI,CAAC,SAAS,CAAC,CAAC;QACpF,IAAI,CAAC,oBAAoB,GAAG,IAAI,iCAAmB,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC;QAEtE,qCAAqC;QACrC,IAAI,CAAC,MAAM,CAAC,qBAAqB,CAAC,GAAG,CAAC,KAAK,EAAE,UAAU,EAAE,EAAE;YACzD,6EAA6E;YAC7E,MAAM,IAAI,CAAC,mBAAmB,CAAC,OAAO,CAAC,UAAU,CAAC,CAAC;YACnD,MAAM,IAAI,CAAC,oBAAoB,CAAC,OAAO,CAAC,UAAU,CAAC,CAAC;YACpD,IAAI,CAAC,WAAW,CAAC,IAAI,E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;iBAC9C;aACF,CAAC;YACF,MAAM,MAAM,CAAC,gBAAgB,CAAC;gBAC5B,OAAO,EAAE,WAAW;gBACpB,SAAS,EAAE;oBACT,OAAO,EAAE,oCAAoC;oBAC7C,QAAQ,EAAE,IAAI,CAAC,YAAY;oBAC3B,SAAS;oBACT,WAAW,EAAE,IAAI,CAAC,WAAW;oBAC7B,WAAW,EAAE,0BAAY,CAAC,WAAW,CAAC,IAAI;iBAC3C;aACF,CAAC;SACH,CAAC,GAAG,CAAC,CAAC,UAAU,EAAgB,EAAE,CAAC,CAAC,EAAE,OAAO,EAAE,mCAAmC,EAAE,UAAU,EAAE,CAAC,CAAC,CACpG,CAAC;IACJ,CAAC;CACF;AA/ID,4BA+IC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { NetworkManager } from '@dxos/network-manager';
|
|
2
2
|
import { Invitation } from '@dxos/protocols/proto/dxos/client/services';
|
|
3
3
|
import { IdentityManager } from '../identity';
|
|
4
|
-
import { AuthenticatingInvitationProvider,
|
|
4
|
+
import { AuthenticatingInvitationProvider, CancellableInvitationObservable } from './invitations';
|
|
5
5
|
import { AbstractInvitationsHandler, InvitationsOptions } from './invitations-handler';
|
|
6
6
|
/**
|
|
7
7
|
* Handles the life-cycle of Halo invitations between peers.
|
|
@@ -12,7 +12,7 @@ export declare class HaloInvitationsHandler extends AbstractInvitationsHandler {
|
|
|
12
12
|
/**
|
|
13
13
|
* Creates an invitation and listens for a join request from the invited (guest) peer.
|
|
14
14
|
*/
|
|
15
|
-
createInvitation(context: void, options?: InvitationsOptions):
|
|
15
|
+
createInvitation(context: void, options?: InvitationsOptions): CancellableInvitationObservable;
|
|
16
16
|
/**
|
|
17
17
|
* Waits for the host peer (inviter) to accept our join request.
|
|
18
18
|
* The local guest peer (invitee) then sends the local halo invitation to the host,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"halo-invitations-handler.d.ts","sourceRoot":"","sources":["../../../../src/packlets/invitations/halo-invitations-handler.ts"],"names":[],"mappings":"AAWA,OAAO,EAAyB,cAAc,EAAiC,MAAM,uBAAuB,CAAC;AAG7G,OAAO,EAAE,UAAU,EAAE,MAAM,4CAA4C,CAAC;AAGxE,OAAO,EAAE,eAAe,EAAE,MAAM,aAAa,CAAC;AAC9C,OAAO,EACL,gCAAgC,EAChC,
|
|
1
|
+
{"version":3,"file":"halo-invitations-handler.d.ts","sourceRoot":"","sources":["../../../../src/packlets/invitations/halo-invitations-handler.ts"],"names":[],"mappings":"AAWA,OAAO,EAAyB,cAAc,EAAiC,MAAM,uBAAuB,CAAC;AAG7G,OAAO,EAAE,UAAU,EAAE,MAAM,4CAA4C,CAAC;AAGxE,OAAO,EAAE,eAAe,EAAE,MAAM,aAAa,CAAC;AAC9C,OAAO,EACL,gCAAgC,EAChC,+BAA+B,EAKhC,MAAM,eAAe,CAAC;AACvB,OAAO,EAAE,0BAA0B,EAAE,kBAAkB,EAAE,MAAM,uBAAuB,CAAC;AAEvF;;GAEG;AAEH,qBAAa,sBAAuB,SAAQ,0BAA0B;IAIlE,OAAO,CAAC,QAAQ,CAAC,gBAAgB;gBADjC,cAAc,EAAE,cAAc,EACb,gBAAgB,EAAE,eAAe;IAKpD;;OAEG;IACH,gBAAgB,CAAC,OAAO,EAAE,IAAI,EAAE,OAAO,CAAC,EAAE,kBAAkB,GAAG,+BAA+B;IA+G9F;;;;OAIG;IACH,gBAAgB,CAAC,UAAU,EAAE,UAAU,EAAE,OAAO,CAAC,EAAE,kBAAkB,GAAG,gCAAgC;CA8FzG"}
|
|
@@ -63,7 +63,7 @@ class HaloInvitationsHandler extends invitations_handler_1.AbstractInvitationsHa
|
|
|
63
63
|
var _a, _b;
|
|
64
64
|
(0, log_1.log)('responding with admission offer', {
|
|
65
65
|
host: identity.deviceKey
|
|
66
|
-
}, { file: "packages/sdk/client-services/src/packlets/invitations/halo-invitations-handler.ts", line: 73, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation." });
|
|
66
|
+
}, { file: "packages/sdk/client-services/src/packlets/invitations/halo-invitations-handler.ts", line: 73, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation.", callSite: (fn, args) => fn(...args) });
|
|
67
67
|
// TODO(burdon): Is this the right place to set this state?
|
|
68
68
|
(_b = (_a = observable.callback).onAuthenticating) === null || _b === void 0 ? void 0 : _b.call(_a, invitation);
|
|
69
69
|
return {
|
|
@@ -73,7 +73,7 @@ class HaloInvitationsHandler extends invitations_handler_1.AbstractInvitationsHa
|
|
|
73
73
|
};
|
|
74
74
|
},
|
|
75
75
|
authenticate: async ({ authenticationCode: code }) => {
|
|
76
|
-
(0, log_1.log)('received authentication request', { authenticationCode: code }, { file: "packages/sdk/client-services/src/packlets/invitations/halo-invitations-handler.ts", line: 87, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation." });
|
|
76
|
+
(0, log_1.log)('received authentication request', { authenticationCode: code }, { file: "packages/sdk/client-services/src/packlets/invitations/halo-invitations-handler.ts", line: 87, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation.", callSite: (fn, args) => fn(...args) });
|
|
77
77
|
authenticationCode = code;
|
|
78
78
|
},
|
|
79
79
|
// TODO(burdon): Not used: controlFeedKey, dataFeedKey.
|
|
@@ -86,7 +86,7 @@ class HaloInvitationsHandler extends invitations_handler_1.AbstractInvitationsHa
|
|
|
86
86
|
throw new Error('authentication code not set');
|
|
87
87
|
}
|
|
88
88
|
}
|
|
89
|
-
(0, log_1.log)('writing guest credentials', { host: identity.deviceKey, guest: credentials.deviceKey }, { file: "packages/sdk/client-services/src/packlets/invitations/halo-invitations-handler.ts", line: 104, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation." });
|
|
89
|
+
(0, log_1.log)('writing guest credentials', { host: identity.deviceKey, guest: credentials.deviceKey }, { file: "packages/sdk/client-services/src/packlets/invitations/halo-invitations-handler.ts", line: 104, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation.", callSite: (fn, args) => fn(...args) });
|
|
90
90
|
// TODO(burdon): Check if already admitted.
|
|
91
91
|
await identity.admitDevice(credentials);
|
|
92
92
|
// Updating credentials complete.
|
|
@@ -104,15 +104,15 @@ class HaloInvitationsHandler extends invitations_handler_1.AbstractInvitationsHa
|
|
|
104
104
|
});
|
|
105
105
|
try {
|
|
106
106
|
await peer.open();
|
|
107
|
-
(0, log_1.log)('connected', { host: identity.deviceKey }, { file: "packages/sdk/client-services/src/packlets/invitations/halo-invitations-handler.ts", line: 123, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation." });
|
|
107
|
+
(0, log_1.log)('connected', { host: identity.deviceKey }, { file: "packages/sdk/client-services/src/packlets/invitations/halo-invitations-handler.ts", line: 123, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation.", callSite: (fn, args) => fn(...args) });
|
|
108
108
|
(_b = (_a = observable.callback).onConnected) === null || _b === void 0 ? void 0 : _b.call(_a, invitation);
|
|
109
109
|
const deviceKey = await complete.wait({ timeout });
|
|
110
|
-
(0, log_1.log)('admitted guest', { host: identity.deviceKey, guest: deviceKey }, { file: "packages/sdk/client-services/src/packlets/invitations/halo-invitations-handler.ts", line: 126, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation." });
|
|
110
|
+
(0, log_1.log)('admitted guest', { host: identity.deviceKey, guest: deviceKey }, { file: "packages/sdk/client-services/src/packlets/invitations/halo-invitations-handler.ts", line: 126, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation.", callSite: (fn, args) => fn(...args) });
|
|
111
111
|
observable.callback.onSuccess(invitation);
|
|
112
112
|
}
|
|
113
113
|
catch (err) {
|
|
114
114
|
if (!observable.cancelled) {
|
|
115
|
-
log_1.log.error('failed', err, { file: "packages/sdk/client-services/src/packlets/invitations/halo-invitations-handler.ts", line: 130, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation." });
|
|
115
|
+
log_1.log.error('failed', err, { file: "packages/sdk/client-services/src/packlets/invitations/halo-invitations-handler.ts", line: 130, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation.", callSite: (fn, args) => fn(...args) });
|
|
116
116
|
observable.callback.onError(err);
|
|
117
117
|
}
|
|
118
118
|
}
|
|
@@ -170,18 +170,18 @@ class HaloInvitationsHandler extends invitations_handler_1.AbstractInvitationsHa
|
|
|
170
170
|
if (++connectionCount > 1) {
|
|
171
171
|
throw new Error(`multiple connections detected: ${connectionCount}`);
|
|
172
172
|
}
|
|
173
|
-
(0, log_1.log)('connected', {}, { file: "packages/sdk/client-services/src/packlets/invitations/halo-invitations-handler.ts", line: 194, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation." });
|
|
173
|
+
(0, log_1.log)('connected', {}, { file: "packages/sdk/client-services/src/packlets/invitations/halo-invitations-handler.ts", line: 194, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation.", callSite: (fn, args) => fn(...args) });
|
|
174
174
|
(_b = (_a = observable.callback).onConnected) === null || _b === void 0 ? void 0 : _b.call(_a, invitation);
|
|
175
175
|
// 1. Send request.
|
|
176
|
-
(0, log_1.log)('sending admission request', {}, { file: "packages/sdk/client-services/src/packlets/invitations/halo-invitations-handler.ts", line: 198, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation." });
|
|
176
|
+
(0, log_1.log)('sending admission request', {}, { file: "packages/sdk/client-services/src/packlets/invitations/halo-invitations-handler.ts", line: 198, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation.", callSite: (fn, args) => fn(...args) });
|
|
177
177
|
const { identityKey, haloSpaceKey, genesisFeedKey } = await peer.rpc.HaloHostService.requestAdmission();
|
|
178
178
|
// 2. Get authentication code.
|
|
179
179
|
// TODO(burdon): Test timeout (options for timeouts at different steps).
|
|
180
180
|
if (invitation.type === undefined || invitation.type === services_1.Invitation.Type.INTERACTIVE) {
|
|
181
|
-
(0, log_1.log)('guest waiting for authentication code...', {}, { file: "packages/sdk/client-services/src/packlets/invitations/halo-invitations-handler.ts", line: 204, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation." });
|
|
181
|
+
(0, log_1.log)('guest waiting for authentication code...', {}, { file: "packages/sdk/client-services/src/packlets/invitations/halo-invitations-handler.ts", line: 204, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation.", callSite: (fn, args) => fn(...args) });
|
|
182
182
|
(_d = (_c = observable.callback).onAuthenticating) === null || _d === void 0 ? void 0 : _d.call(_c, invitation);
|
|
183
183
|
const authenticationCode = await authenticated.wait({ timeout });
|
|
184
|
-
(0, log_1.log)('sending authentication request', {}, { file: "packages/sdk/client-services/src/packlets/invitations/halo-invitations-handler.ts", line: 207, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation." });
|
|
184
|
+
(0, log_1.log)('sending authentication request', {}, { file: "packages/sdk/client-services/src/packlets/invitations/halo-invitations-handler.ts", line: 207, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation.", callSite: (fn, args) => fn(...args) });
|
|
185
185
|
await peer.rpc.HaloHostService.authenticate({ authenticationCode });
|
|
186
186
|
}
|
|
187
187
|
// 3. Create local identity.
|
|
@@ -192,15 +192,15 @@ class HaloInvitationsHandler extends invitations_handler_1.AbstractInvitationsHa
|
|
|
192
192
|
haloGenesisFeedKey: genesisFeedKey
|
|
193
193
|
});
|
|
194
194
|
// 4. Send admission credentials to host (with local identity keys).
|
|
195
|
-
(0, log_1.log)('presenting admission credentials', { guest: identity.deviceKey, identityKey }, { file: "packages/sdk/client-services/src/packlets/invitations/halo-invitations-handler.ts", line: 220, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation." });
|
|
195
|
+
(0, log_1.log)('presenting admission credentials', { guest: identity.deviceKey, identityKey }, { file: "packages/sdk/client-services/src/packlets/invitations/halo-invitations-handler.ts", line: 220, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation.", callSite: (fn, args) => fn(...args) });
|
|
196
196
|
await peer.rpc.HaloHostService.presentAdmissionCredentials(identity.getAdmissionCredentials());
|
|
197
197
|
// 5. Success.
|
|
198
|
-
(0, log_1.log)('admitted by host', { guest: identity.deviceKey, identityKey }, { file: "packages/sdk/client-services/src/packlets/invitations/halo-invitations-handler.ts", line: 224, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation." });
|
|
198
|
+
(0, log_1.log)('admitted by host', { guest: identity.deviceKey, identityKey }, { file: "packages/sdk/client-services/src/packlets/invitations/halo-invitations-handler.ts", line: 224, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation.", callSite: (fn, args) => fn(...args) });
|
|
199
199
|
complete.wake(identityKey);
|
|
200
200
|
}
|
|
201
201
|
catch (err) {
|
|
202
202
|
if (!observable.cancelled) {
|
|
203
|
-
log_1.log.warn('failed', err, { file: "packages/sdk/client-services/src/packlets/invitations/halo-invitations-handler.ts", line: 228, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation." });
|
|
203
|
+
log_1.log.warn('failed', err, { file: "packages/sdk/client-services/src/packlets/invitations/halo-invitations-handler.ts", line: 228, scope: this, bugcheck: "If you see this message then it means that the source code preprocessor for @dxos/log is broken. It probably has misinterpreted an unrelated call for a logger invocation.", callSite: (fn, args) => fn(...args) });
|
|
204
204
|
observable.callback.onError(err);
|
|
205
205
|
}
|
|
206
206
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"halo-invitations-handler.js","sourceRoot":"","sources":["../../../../src/packlets/invitations/halo-invitations-handler.ts"],"names":[],"mappings":";AAAA,EAAE;AACF,0BAA0B;AAC1B,EAAE;;;;;;AAEF,oDAA4B;AAE5B,uCAA6C;AAC7C,mDAAqD;AACrD,uCAA4C;AAC5C,qCAAuC;AACvC,mCAAgC;AAChC,2DAA6G;AAC7G,mEAAuE;AACvE,+CAAyC;AACzC,yEAAwE;AACxE,mCAA+C;AAG/C,+CAOuB;AACvB,+DAAuF;AAEvF;;GAEG;AACH,qDAAqD;AACrD,MAAa,sBAAuB,SAAQ,gDAA0B;IACpE,kBAAkB;IAClB,YACE,cAA8B,EACb,gBAAiC;QAElD,KAAK,CAAC,cAAc,CAAC,CAAC;QAFL,qBAAgB,GAAhB,gBAAgB,CAAiB;IAGpD,CAAC;IAED;;OAEG;IACH,gBAAgB,CAAC,OAAa,EAAE,OAA4B;;QAC1D,IAAI,eAA4C,CAAC;QACjD,MAAM,EAAE,IAAI,EAAE,OAAO,GAAG,gCAAkB,EAAE,QAAQ,EAAE,GAAG,OAAO,aAAP,OAAO,cAAP,OAAO,GAAI,EAAE,CAAC;QACvE,I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;gBACL,MAAM,EAAE,gBAAS,CAAC,MAAM,EAAE;gBAC1B,QAAQ,EAAE,IAAA,uCAAqB,EAAC,KAAK,EAAE,MAAM,EAAE,CAAC,MAAM,CAAC,CAAC;gBACxD,QAAQ,EAAE,IAAI,8BAAY,CAAC,KAAK,CAAC;aAClC,CAAC,CAAC;YAEH,MAAA,MAAA,UAAU,CAAC,QAAQ,EAAC,YAAY,mDAAG,UAAU,CAAC,CAAC;YAC/C,UAAU,CAAC,WAAW,GAAG,MAAM,QAAQ,CAAC,IAAI,EAAE,CAAC;YAC/C,UAAU,CAAC,QAAQ,CAAC,SAAS,CAAC,UAAU,CAAC,CAAC;YAC1C,MAAM,eAAe,CAAC,KAAK,EAAE,CAAC;QAChC,CAAC,CAAC,CAAC;QAEH,OAAO,UAAU,CAAC;IACpB,CAAC;CACF;AA9ND,wDA8NC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { PublicKey } from '@dxos/keys';
|
|
2
2
|
import { NetworkManager } from '@dxos/network-manager';
|
|
3
3
|
import { Invitation } from '@dxos/protocols/proto/dxos/client/services';
|
|
4
|
-
import { AuthenticatingInvitationObservable,
|
|
4
|
+
import { AuthenticatingInvitationObservable, CancellableInvitationObservable } from './invitations';
|
|
5
5
|
export type InvitationsOptions = {
|
|
6
6
|
type?: Invitation.Type;
|
|
7
7
|
timeout?: number;
|
|
@@ -35,7 +35,7 @@ export type InvitationsOptions = {
|
|
|
35
35
|
* ```
|
|
36
36
|
*/
|
|
37
37
|
export interface InvitationsHandler<T = void> {
|
|
38
|
-
createInvitation(context: T, options?: InvitationsOptions):
|
|
38
|
+
createInvitation(context: T, options?: InvitationsOptions): CancellableInvitationObservable;
|
|
39
39
|
acceptInvitation(invitation: Invitation, options?: InvitationsOptions): AuthenticatingInvitationObservable;
|
|
40
40
|
}
|
|
41
41
|
/**
|
|
@@ -44,7 +44,7 @@ export interface InvitationsHandler<T = void> {
|
|
|
44
44
|
export declare abstract class AbstractInvitationsHandler<T = void> implements InvitationsHandler<T> {
|
|
45
45
|
protected readonly _networkManager: NetworkManager;
|
|
46
46
|
protected constructor(_networkManager: NetworkManager);
|
|
47
|
-
abstract createInvitation(context: T, options?: InvitationsOptions):
|
|
47
|
+
abstract createInvitation(context: T, options?: InvitationsOptions): CancellableInvitationObservable;
|
|
48
48
|
abstract acceptInvitation(invitation: Invitation, options?: InvitationsOptions): AuthenticatingInvitationObservable;
|
|
49
49
|
}
|
|
50
50
|
//# sourceMappingURL=invitations-handler.d.ts.map
|