@dxos/client-services 0.9.0 → 0.9.1-staging.ee54ba693a

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.
Files changed (49) hide show
  1. package/dist/lib/browser/{chunk-37BKOM5O.mjs → chunk-SRTDXIDQ.mjs} +60 -54
  2. package/dist/lib/browser/chunk-SRTDXIDQ.mjs.map +7 -0
  3. package/dist/lib/browser/index.mjs +1 -1
  4. package/dist/lib/browser/meta.json +1 -1
  5. package/dist/lib/browser/testing/index.mjs +3 -3
  6. package/dist/lib/browser/testing/index.mjs.map +3 -3
  7. package/dist/lib/node-esm/{chunk-2ONS4DLO.mjs → chunk-NEJCHFZ3.mjs} +60 -54
  8. package/dist/lib/node-esm/chunk-NEJCHFZ3.mjs.map +7 -0
  9. package/dist/lib/node-esm/index.mjs +1 -1
  10. package/dist/lib/node-esm/meta.json +1 -1
  11. package/dist/lib/node-esm/testing/index.mjs +3 -3
  12. package/dist/lib/node-esm/testing/index.mjs.map +3 -3
  13. package/dist/types/src/packlets/invitations/invitations-manager.d.ts.map +1 -1
  14. package/dist/types/src/packlets/services/service-context.d.ts +1 -1
  15. package/dist/types/src/packlets/services/service-context.d.ts.map +1 -1
  16. package/dist/types/src/packlets/services/sqlite-storage.d.ts +1 -1
  17. package/dist/types/src/packlets/services/sqlite-storage.d.ts.map +1 -1
  18. package/dist/types/src/packlets/space-export/serialized-space-writer.d.ts.map +1 -1
  19. package/dist/types/src/packlets/spaces/data-space-manager.d.ts +1 -1
  20. package/dist/types/src/packlets/spaces/data-space-manager.d.ts.map +1 -1
  21. package/dist/types/src/packlets/spaces/spaces-service.d.ts +1 -1
  22. package/dist/types/src/packlets/spaces/spaces-service.d.ts.map +1 -1
  23. package/dist/types/src/version.d.ts +1 -1
  24. package/dist/types/src/version.d.ts.map +1 -1
  25. package/dist/types/tsconfig.tsbuildinfo +1 -1
  26. package/package.json +42 -42
  27. package/src/packlets/agents/edge-agent-manager.ts +2 -2
  28. package/src/packlets/identity/identity-manager.test.ts +1 -1
  29. package/src/packlets/identity/identity.test.ts +4 -4
  30. package/src/packlets/identity/identity.ts +7 -7
  31. package/src/packlets/invitations/invitations-manager.ts +1 -1
  32. package/src/packlets/services/feed-syncer.test.ts +1 -1
  33. package/src/packlets/services/feed-syncer.ts +2 -2
  34. package/src/packlets/services/service-context.ts +3 -3
  35. package/src/packlets/services/service-host.ts +1 -1
  36. package/src/packlets/services/sqlite-storage.ts +18 -8
  37. package/src/packlets/space-export/serialized-space-writer.ts +1 -1
  38. package/src/packlets/space-export/space-archive.test.ts +8 -8
  39. package/src/packlets/spaces/data-space-manager.test.ts +1 -1
  40. package/src/packlets/spaces/data-space-manager.ts +2 -2
  41. package/src/packlets/spaces/data-space.ts +8 -8
  42. package/src/packlets/spaces/edge-feed-replicator.ts +1 -1
  43. package/src/packlets/spaces/genesis.ts +20 -20
  44. package/src/packlets/spaces/spaces-service.ts +3 -3
  45. package/src/packlets/storage/profile-archive-sqlite.test.ts +1 -1
  46. package/src/packlets/testing/credential-utils.ts +2 -2
  47. package/src/version.ts +1 -5
  48. package/dist/lib/browser/chunk-37BKOM5O.mjs.map +0 -7
  49. package/dist/lib/node-esm/chunk-2ONS4DLO.mjs.map +0 -7
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dxos/client-services",
3
- "version": "0.9.0",
3
+ "version": "0.9.1-staging.ee54ba693a",
4
4
  "description": "DXOS client services implementation",
5
5
  "homepage": "https://dxos.org",
6
6
  "bugs": "https://github.com/dxos/dxos/issues",
@@ -52,57 +52,57 @@
52
52
  "src"
53
53
  ],
54
54
  "dependencies": {
55
- "@automerge/automerge": "3.3.0-fragments.1",
56
- "@automerge/automerge-repo": "2.6.0-subduction.23",
55
+ "@automerge/automerge": "3.3.0-fragments.2",
56
+ "@automerge/automerge-repo": "2.6.0-subduction.37",
57
57
  "@effect/experimental": "0.60.0",
58
58
  "@effect/sql": "0.51.1",
59
59
  "@obsidize/tar-browserify": "^5.2.0",
60
60
  "cbor-x": "^1.5.4",
61
- "effect": "3.21.3",
61
+ "effect": "3.21.4",
62
62
  "platform": "^1.3.6",
63
- "@dxos/async": "0.9.0",
64
- "@dxos/codec-protobuf": "0.9.0",
65
- "@dxos/client-protocol": "0.9.0",
66
- "@dxos/credentials": "0.9.0",
67
- "@dxos/config": "0.9.0",
68
- "@dxos/crypto": "0.9.0",
69
- "@dxos/context": "0.9.0",
70
- "@dxos/echo": "0.9.0",
71
- "@dxos/debug": "0.9.0",
72
- "@dxos/echo-client": "0.9.0",
73
- "@dxos/edge-client": "0.9.0",
74
- "@dxos/echo-protocol": "0.9.0",
75
- "@dxos/feed": "0.9.0",
76
- "@dxos/feed-store": "0.9.0",
77
- "@dxos/invariant": "0.9.0",
78
- "@dxos/keyring": "0.9.0",
79
- "@dxos/kv-store": "0.9.0",
80
- "@dxos/keys": "0.9.0",
81
- "@dxos/lock-file": "0.9.0",
82
- "@dxos/effect": "0.9.0",
83
- "@dxos/log": "0.9.0",
84
- "@dxos/messaging": "0.9.0",
85
- "@dxos/echo-host": "0.9.0",
86
- "@dxos/protocols": "0.9.0",
87
- "@dxos/network-manager": "0.9.0",
88
- "@dxos/random-access-storage": "0.9.0",
89
- "@dxos/node-std": "0.9.0",
90
- "@dxos/rpc": "0.9.0",
91
- "@dxos/sql-sqlite": "0.9.0",
92
- "@dxos/teleport-extension-gossip": "0.9.0",
93
- "@dxos/teleport": "0.9.0",
94
- "@dxos/timeframe": "0.9.0",
95
- "@dxos/tracing": "0.9.0",
96
- "@dxos/websocket-rpc": "0.9.0",
97
- "@dxos/teleport-extension-object-sync": "0.9.0",
98
- "@dxos/util": "0.9.0"
63
+ "@dxos/async": "0.9.1-staging.ee54ba693a",
64
+ "@dxos/codec-protobuf": "0.9.1-staging.ee54ba693a",
65
+ "@dxos/config": "0.9.1-staging.ee54ba693a",
66
+ "@dxos/client-protocol": "0.9.1-staging.ee54ba693a",
67
+ "@dxos/credentials": "0.9.1-staging.ee54ba693a",
68
+ "@dxos/context": "0.9.1-staging.ee54ba693a",
69
+ "@dxos/debug": "0.9.1-staging.ee54ba693a",
70
+ "@dxos/echo": "0.9.1-staging.ee54ba693a",
71
+ "@dxos/crypto": "0.9.1-staging.ee54ba693a",
72
+ "@dxos/echo-client": "0.9.1-staging.ee54ba693a",
73
+ "@dxos/echo-host": "0.9.1-staging.ee54ba693a",
74
+ "@dxos/echo-protocol": "0.9.1-staging.ee54ba693a",
75
+ "@dxos/edge-client": "0.9.1-staging.ee54ba693a",
76
+ "@dxos/feed-store": "0.9.1-staging.ee54ba693a",
77
+ "@dxos/invariant": "0.9.1-staging.ee54ba693a",
78
+ "@dxos/effect": "0.9.1-staging.ee54ba693a",
79
+ "@dxos/keyring": "0.9.1-staging.ee54ba693a",
80
+ "@dxos/keys": "0.9.1-staging.ee54ba693a",
81
+ "@dxos/kv-store": "0.9.1-staging.ee54ba693a",
82
+ "@dxos/lock-file": "0.9.1-staging.ee54ba693a",
83
+ "@dxos/log": "0.9.1-staging.ee54ba693a",
84
+ "@dxos/messaging": "0.9.1-staging.ee54ba693a",
85
+ "@dxos/network-manager": "0.9.1-staging.ee54ba693a",
86
+ "@dxos/node-std": "0.9.1-staging.ee54ba693a",
87
+ "@dxos/protocols": "0.9.1-staging.ee54ba693a",
88
+ "@dxos/feed": "0.9.1-staging.ee54ba693a",
89
+ "@dxos/random-access-storage": "0.9.1-staging.ee54ba693a",
90
+ "@dxos/rpc": "0.9.1-staging.ee54ba693a",
91
+ "@dxos/sql-sqlite": "0.9.1-staging.ee54ba693a",
92
+ "@dxos/teleport": "0.9.1-staging.ee54ba693a",
93
+ "@dxos/teleport-extension-gossip": "0.9.1-staging.ee54ba693a",
94
+ "@dxos/teleport-extension-object-sync": "0.9.1-staging.ee54ba693a",
95
+ "@dxos/timeframe": "0.9.1-staging.ee54ba693a",
96
+ "@dxos/tracing": "0.9.1-staging.ee54ba693a",
97
+ "@dxos/websocket-rpc": "0.9.1-staging.ee54ba693a",
98
+ "@dxos/util": "0.9.1-staging.ee54ba693a"
99
99
  },
100
100
  "devDependencies": {
101
101
  "@types/platform": "^1.3.4",
102
102
  "@types/readable-stream": "^2.3.9",
103
103
  "get-port-please": "^3.1.1",
104
- "@dxos/signal": "0.9.0",
105
- "@dxos/test-utils": "0.9.0"
104
+ "@dxos/signal": "0.9.1-staging.ee54ba693a",
105
+ "@dxos/test-utils": "0.9.1-staging.ee54ba693a"
106
106
  },
107
107
  "publishConfig": {
108
108
  "access": "public"
@@ -57,7 +57,7 @@ export class EdgeAgentManager extends Resource {
57
57
  invariant(this._edgeFeatures?.agents);
58
58
 
59
59
  const response = await this._edgeHttpClient.createAgent(ctx, {
60
- identityKey: this._identity.identityKey.toHex(),
60
+ identityDid: this._identity.did,
61
61
  haloSpaceId: this._identity.haloSpaceId,
62
62
  haloSpaceKey: this._identity.haloSpaceKey.toHex(),
63
63
  });
@@ -123,7 +123,7 @@ export class EdgeAgentManager extends Resource {
123
123
  try {
124
124
  log('fetching agent status');
125
125
  const { agent } = await this._edgeHttpClient.getAgentStatus(ctx, {
126
- ownerIdentityKey: this._identity.identityKey,
126
+ ownerIdentityDid: this._identity.did,
127
127
  });
128
128
  const wasAgentCreatedDuringQuery = this._agentStatus === EdgeAgentStatus.ACTIVE;
129
129
  if (!wasAgentCreatedDuringQuery) {
@@ -124,7 +124,7 @@ describe('identity/identity-manager', () => {
124
124
  subject: deviceKey,
125
125
  assertion: {
126
126
  '@type': 'dxos.halo.credentials.AuthorizedDevice',
127
- identityKey: identity1.identityKey,
127
+ 'identityKey': identity1.identityKey,
128
128
  deviceKey,
129
129
  },
130
130
  });
@@ -8,9 +8,9 @@ import { Event } from '@dxos/async';
8
8
  import { Context } from '@dxos/context';
9
9
  import { CredentialGenerator, createDidFromIdentityKey, verifyCredential } from '@dxos/credentials';
10
10
  import {
11
+ MetadataStore,
11
12
  MOCK_AUTH_PROVIDER,
12
13
  MOCK_AUTH_VERIFIER,
13
- MetadataStore,
14
14
  Space,
15
15
  SpaceProtocol,
16
16
  createIdFromSpaceKey,
@@ -56,7 +56,7 @@ describe('identity/identity', () => {
56
56
  subject: setup.identityKey,
57
57
  assertion: {
58
58
  '@type': 'dxos.halo.credentials.IdentityProfile',
59
- profile: {
59
+ 'profile': {
60
60
  displayName: 'Alice',
61
61
  },
62
62
  },
@@ -93,8 +93,8 @@ describe('identity/identity', () => {
93
93
  subject: secondDevice.deviceKey,
94
94
  assertion: {
95
95
  '@type': 'dxos.halo.credentials.AuthorizedDevice',
96
- identityKey: owner.identityKey,
97
- deviceKey: secondDevice.deviceKey,
96
+ 'identityKey': owner.identityKey,
97
+ 'deviceKey': secondDevice.deviceKey,
98
98
  },
99
99
  }),
100
100
  },
@@ -210,7 +210,7 @@ export class Identity {
210
210
  subject: deviceKey,
211
211
  assertion: {
212
212
  '@type': 'dxos.halo.credentials.AuthorizedDevice',
213
- identityKey: this.identityKey,
213
+ 'identityKey': this.identityKey,
214
214
  deviceKey,
215
215
  },
216
216
  });
@@ -222,20 +222,20 @@ export class Identity {
222
222
  subject: controlFeedKey,
223
223
  assertion: {
224
224
  '@type': 'dxos.halo.credentials.AdmittedFeed',
225
- spaceKey: this.haloSpaceKey,
225
+ 'spaceKey': this.haloSpaceKey,
226
226
  deviceKey,
227
- identityKey: this.identityKey,
228
- designation: AdmittedFeed.Designation.CONTROL,
227
+ 'identityKey': this.identityKey,
228
+ 'designation': AdmittedFeed.Designation.CONTROL,
229
229
  },
230
230
  }),
231
231
  await signer.createCredential({
232
232
  subject: dataFeedKey,
233
233
  assertion: {
234
234
  '@type': 'dxos.halo.credentials.AdmittedFeed',
235
- spaceKey: this.haloSpaceKey,
235
+ 'spaceKey': this.haloSpaceKey,
236
236
  deviceKey,
237
- identityKey: this.identityKey,
238
- designation: AdmittedFeed.Designation.DATA,
237
+ 'identityKey': this.identityKey,
238
+ 'designation': AdmittedFeed.Designation.DATA,
239
239
  },
240
240
  }),
241
241
  ].map((credential): FeedMessage.Payload => ({ credential: { credential } })),
@@ -4,8 +4,8 @@
4
4
 
5
5
  import { Event, PushStream, TimeoutError, Trigger } from '@dxos/async';
6
6
  import {
7
- AUTHENTICATION_CODE_LENGTH,
8
7
  AuthenticatingInvitation,
8
+ AUTHENTICATION_CODE_LENGTH,
9
9
  CancellableInvitation,
10
10
  INVITATION_TIMEOUT,
11
11
  } from '@dxos/client-protocol';
@@ -54,7 +54,7 @@ const createEdgeConnection = ({
54
54
  return {
55
55
  statusChanged: new Event<any>(),
56
56
  info: {},
57
- identityKey: 'client-identity',
57
+ identityDid: 'did:halo:client-identity',
58
58
  peerKey: 'client-peer',
59
59
  isOpen: true,
60
60
  status: {
@@ -182,7 +182,7 @@ export class FeedSyncer extends Resource {
182
182
  this.#edgeClient.onReconnected(async () => {
183
183
  log('feed sync edge reconnected', {
184
184
  peerKey: this.#edgeClient.peerKey,
185
- identityKey: this.#edgeClient.identityKey,
185
+ identityDid: this.#edgeClient.identityDid,
186
186
  });
187
187
  if (this.#backgroundSync) {
188
188
  this.#resetSpacesToPoll();
@@ -401,7 +401,7 @@ export class FeedSyncer extends Resource {
401
401
  ctx,
402
402
  createBuf(MessageSchema, {
403
403
  source: {
404
- identityKey: this.#edgeClient.identityKey,
404
+ identityDid: this.#edgeClient.identityDid,
405
405
  peerKey: this.#edgeClient.peerKey,
406
406
  },
407
407
  serviceId,
@@ -15,9 +15,9 @@ import {
15
15
  EchoHost,
16
16
  type EdgeAutomergeReplicator,
17
17
  MeshEchoReplicator,
18
- runSqliteHealthCheck,
19
- SqliteMetadataStore,
20
18
  SpaceManager,
19
+ SqliteMetadataStore,
20
+ runSqliteHealthCheck,
21
21
  valueEncoding,
22
22
  } from '@dxos/echo-host';
23
23
  import { createChainEdgeIdentity, createEphemeralEdgeIdentity } from '@dxos/edge-client';
@@ -558,7 +558,7 @@ export class ServiceContext extends Resource {
558
558
  this._edgeConnection?.setIdentity(edgeIdentity);
559
559
  this._edgeHttpClient?.setIdentity(edgeIdentity);
560
560
  this.networkManager.setPeerInfo({
561
- identityKey: edgeIdentity.identityKey,
561
+ identityDid: edgeIdentity.identityDid,
562
562
  peerKey: edgeIdentity.peerKey,
563
563
  });
564
564
  log('_setNetworkIdentity: done');
@@ -264,7 +264,7 @@ export class ClientServicesHost {
264
264
  signalManager,
265
265
  peerInfo: this._edgeConnection
266
266
  ? {
267
- identityKey: this._edgeConnection.identityKey,
267
+ identityDid: this._edgeConnection.identityDid,
268
268
  peerKey: this._edgeConnection.peerKey,
269
269
  }
270
270
  : undefined,
@@ -9,7 +9,7 @@ import type { Callback, FileStat, RandomAccessStorage } from 'random-access-stor
9
9
 
10
10
  import { RuntimeProvider } from '@dxos/effect';
11
11
  import { log } from '@dxos/log';
12
- import { Directory, type File, StorageType, type Storage, wrapFile } from '@dxos/random-access-storage';
12
+ import { Directory, type File, type Storage, StorageType, wrapFile } from '@dxos/random-access-storage';
13
13
  import { SqlTransaction } from '@dxos/sql-sqlite';
14
14
 
15
15
  // SqlTransaction.SqlTransaction is the Tag class exported from the SqlTransaction namespace.
@@ -167,13 +167,23 @@ class SqliteRandomAccessFile extends BaseEventEmitter implements RandomAccessSto
167
167
 
168
168
  private async _loadFromDb(): Promise<void> {
169
169
  const filePath = this.filePath;
170
- const rows = await RuntimeProvider.runPromise(this.runtime)(
171
- Effect.gen(function* () {
172
- const sql = yield* SqlClient.SqlClient;
173
- return yield* sql<{ data: Uint8Array }>`SELECT data FROM hypercore_files WHERE path = ${filePath}`;
174
- }),
175
- );
176
- this.#buffer = rows.length > 0 ? Buffer.from(rows[0].data) : Buffer.alloc(0);
170
+ try {
171
+ const rows = await RuntimeProvider.runPromise(this.runtime)(
172
+ Effect.gen(function* () {
173
+ const sql = yield* SqlClient.SqlClient;
174
+ return yield* sql<{ data: Uint8Array }>`SELECT data FROM hypercore_files WHERE path = ${filePath}`;
175
+ }),
176
+ );
177
+ this.#buffer = rows.length > 0 ? Buffer.from(rows[0].data) : Buffer.alloc(0);
178
+ } catch (err) {
179
+ // The SQL connection may close mid-read during teardown (the `#closed` guard in `_ensureLoaded`
180
+ // only catches reads that have not yet started). A read racing teardown rejects with
181
+ // "database connection is not open"; swallow it once closed and fall back to the empty buffer,
182
+ // otherwise surface the genuine error.
183
+ if (!this.#closed) {
184
+ throw err;
185
+ }
186
+ }
177
187
  this.#loaded = true;
178
188
  }
179
189
 
@@ -10,7 +10,7 @@ import { type SerializedFeed, type SerializedSpace } from '@dxos/echo-client';
10
10
  import { type EchoHost } from '@dxos/echo-host';
11
11
  import { type DatabaseDirectory, type EntityStructure } from '@dxos/echo-protocol';
12
12
  import { assertState, invariant } from '@dxos/invariant';
13
- import { DXN, type IdentityDid, type EntityId, type SpaceId } from '@dxos/keys';
13
+ import { DXN, type EntityId, type IdentityDid, type SpaceId } from '@dxos/keys';
14
14
  import { log } from '@dxos/log';
15
15
  import { FeedProtocol } from '@dxos/protocols';
16
16
  import { SpaceArchive } from '@dxos/protocols/proto/dxos/client/services';
@@ -367,7 +367,7 @@ describe('SpaceArchive', () => {
367
367
  id,
368
368
  '@type': 'dxn:example.Thing',
369
369
  '@meta': { keys: [] },
370
- title: 'hello',
370
+ 'title': 'hello',
371
371
  },
372
372
  ];
373
373
  const directory = buildDatabaseDirectoryFromObjects(objects as any);
@@ -413,8 +413,8 @@ describe('SpaceArchive', () => {
413
413
  test('orderObjJsonFields reorders feed queue messages with id/@type/@meta first', () => {
414
414
  const id = EntityId.random();
415
415
  const message = {
416
- payload: { value: 'x' },
417
- timestamp: 1000,
416
+ 'payload': { value: 'x' },
417
+ 'timestamp': 1000,
418
418
  id,
419
419
  '@meta': { keys: [] },
420
420
  '@type': 'dxn:example.Message',
@@ -428,7 +428,7 @@ describe('SpaceArchive', () => {
428
428
  test('orderObjJsonFields preserves unknown @-prefixed fields between system and data', () => {
429
429
  const id = EntityId.random();
430
430
  const obj = {
431
- data: 1,
431
+ 'data': 1,
432
432
  '@custom': 'extension',
433
433
  '@type': 'dxn:example.Thing',
434
434
  id,
@@ -465,10 +465,10 @@ describe('SpaceArchive', () => {
465
465
  id,
466
466
  '@type': 'dxn:org.dxos.type.schema:0.1.0',
467
467
  '@meta': { keys: [] },
468
- name: 'Custom Type',
469
- typename: 'example.type.custom',
470
- version: '0.1.0',
471
- jsonSchema: { $id: `echo:/${id}`, type: 'object', properties: {} },
468
+ 'name': 'Custom Type',
469
+ 'typename': 'example.type.custom',
470
+ 'version': '0.1.0',
471
+ 'jsonSchema': { $id: `echo:/${id}`, type: 'object', properties: {} },
472
472
  },
473
473
  ];
474
474
  const directory = buildDatabaseDirectoryFromObjects(objects as any);
@@ -147,7 +147,7 @@ describe('DataSpaceManager', () => {
147
147
  inc();
148
148
  });
149
149
 
150
- await space1.postMessage('test', { '@type': 'google.protobuf.Any', test: true });
150
+ await space1.postMessage('test', { '@type': 'google.protobuf.Any', 'test': true });
151
151
  await receivedMessage();
152
152
  });
153
153
 
@@ -22,8 +22,8 @@ import {
22
22
  DatabaseRoot,
23
23
  type EchoHost,
24
24
  type EdgeAutomergeReplicator,
25
- type MeshEchoReplicator,
26
25
  type IMetadataStore,
26
+ type MeshEchoReplicator,
27
27
  type Space,
28
28
  type SpaceManager,
29
29
  type SpaceProtocol,
@@ -429,7 +429,7 @@ export class DataSpaceManager extends Resource {
429
429
  assertion: {
430
430
  '@type': 'dxos.halo.credentials.SpaceDeleted',
431
431
  spaceKey,
432
- deletedAt: new Date(),
432
+ 'deletedAt': new Date(),
433
433
  },
434
434
  });
435
435
  await this._signingContext.recordCredential(credential);
@@ -435,10 +435,10 @@ export class DataSpace {
435
435
  subject: controlFeed.key,
436
436
  assertion: {
437
437
  '@type': 'dxos.halo.credentials.AdmittedFeed',
438
- spaceKey: this.key,
439
- deviceKey: this._signingContext.deviceKey,
440
- identityKey: this._signingContext.identityKey,
441
- designation: AdmittedFeed.Designation.CONTROL,
438
+ 'spaceKey': this.key,
439
+ 'deviceKey': this._signingContext.deviceKey,
440
+ 'identityKey': this._signingContext.identityKey,
441
+ 'designation': AdmittedFeed.Designation.CONTROL,
442
442
  },
443
443
  }),
444
444
  );
@@ -455,10 +455,10 @@ export class DataSpace {
455
455
  subject: dataFeed.key,
456
456
  assertion: {
457
457
  '@type': 'dxos.halo.credentials.AdmittedFeed',
458
- spaceKey: this.key,
459
- deviceKey: this._signingContext.deviceKey,
460
- identityKey: this._signingContext.identityKey,
461
- designation: AdmittedFeed.Designation.DATA,
458
+ 'spaceKey': this.key,
459
+ 'deviceKey': this._signingContext.deviceKey,
460
+ 'identityKey': this._signingContext.identityKey,
461
+ 'designation': AdmittedFeed.Designation.DATA,
462
462
  },
463
463
  }),
464
464
  );
@@ -163,7 +163,7 @@ export class EdgeFeedReplicator extends Resource {
163
163
  ctx,
164
164
  buf.create(RouterMessageSchema, {
165
165
  source: {
166
- identityKey: this._messenger.identityKey,
166
+ identityDid: this._messenger.identityDid,
167
167
  peerKey: this._messenger.peerKey,
168
168
  },
169
169
  serviceId: `${EdgeService.FEED_REPLICATOR}:${this._spaceId}`,
@@ -27,9 +27,9 @@ export const spaceGenesis = async (
27
27
  subject: space.key,
28
28
  assertion: {
29
29
  '@type': 'dxos.halo.credentials.SpaceGenesis',
30
- spaceKey: space.key,
31
- tags: tags ?? [],
32
- membershipPolicy: membershipPolicy ?? MembershipPolicy.INVITE,
30
+ 'spaceKey': space.key,
31
+ 'tags': tags ?? [],
32
+ 'membershipPolicy': membershipPolicy ?? MembershipPolicy.INVITE,
33
33
  },
34
34
  }),
35
35
 
@@ -39,11 +39,11 @@ export const spaceGenesis = async (
39
39
  subject: signingContext.identityKey,
40
40
  assertion: {
41
41
  '@type': 'dxos.halo.credentials.SpaceMember',
42
- spaceKey: space.key,
43
- role: SpaceMember.Role.OWNER,
44
- profile: signingContext.getProfile(),
45
- genesisFeedKey: space.controlFeedKey ?? failUndefined(),
46
- tags: tags ?? [],
42
+ 'spaceKey': space.key,
43
+ 'role': SpaceMember.Role.OWNER,
44
+ 'profile': signingContext.getProfile(),
45
+ 'genesisFeedKey': space.controlFeedKey ?? failUndefined(),
46
+ 'tags': tags ?? [],
47
47
  },
48
48
  }),
49
49
 
@@ -51,10 +51,10 @@ export const spaceGenesis = async (
51
51
  subject: space.controlFeedKey ?? failUndefined(),
52
52
  assertion: {
53
53
  '@type': 'dxos.halo.credentials.AdmittedFeed',
54
- spaceKey: space.key,
55
- identityKey: signingContext.identityKey,
56
- deviceKey: signingContext.deviceKey,
57
- designation: AdmittedFeed.Designation.CONTROL,
54
+ 'spaceKey': space.key,
55
+ 'identityKey': signingContext.identityKey,
56
+ 'deviceKey': signingContext.deviceKey,
57
+ 'designation': AdmittedFeed.Designation.CONTROL,
58
58
  },
59
59
  }),
60
60
 
@@ -62,10 +62,10 @@ export const spaceGenesis = async (
62
62
  subject: space.dataFeedKey ?? failUndefined(),
63
63
  assertion: {
64
64
  '@type': 'dxos.halo.credentials.AdmittedFeed',
65
- spaceKey: space.key,
66
- identityKey: signingContext.identityKey,
67
- deviceKey: signingContext.deviceKey,
68
- designation: AdmittedFeed.Designation.DATA,
65
+ 'spaceKey': space.key,
66
+ 'identityKey': signingContext.identityKey,
67
+ 'deviceKey': signingContext.deviceKey,
68
+ 'designation': AdmittedFeed.Designation.DATA,
69
69
  },
70
70
  }),
71
71
 
@@ -73,10 +73,10 @@ export const spaceGenesis = async (
73
73
  subject: space.key ?? failUndefined(),
74
74
  assertion: {
75
75
  '@type': 'dxos.halo.credentials.Epoch',
76
- number: 0,
77
- previousId: undefined,
78
- timeframe: new Timeframe(),
79
- snapshotCid: undefined,
76
+ 'number': 0,
77
+ 'previousId': undefined,
78
+ 'timeframe': new Timeframe(),
79
+ 'snapshotCid': undefined,
80
80
  automergeRoot,
81
81
  },
82
82
  }),
@@ -34,6 +34,7 @@ import {
34
34
  type ContactAdmission,
35
35
  type CreateEpochRequest,
36
36
  type CreateEpochResponse,
37
+ type CreateSpaceRequest,
37
38
  type ExportSpaceRequest,
38
39
  type ExportSpaceResponse,
39
40
  type ImportSpaceRequest,
@@ -46,11 +47,10 @@ import {
46
47
  type Space,
47
48
  SpaceArchive,
48
49
  SpaceMember,
49
- SpaceState,
50
50
  type SpacesService,
51
+ SpaceState,
51
52
  type SubscribeMessagesRequest,
52
53
  type UpdateMemberRoleRequest,
53
- type CreateSpaceRequest,
54
54
  type UpdateSpaceRequest,
55
55
  type WriteCredentialsRequest,
56
56
  } from '@dxos/protocols/proto/dxos/client/services';
@@ -64,9 +64,9 @@ import {
64
64
  SpaceArchiveWriter,
65
65
  detectSpaceArchiveFormat,
66
66
  extractSpaceArchive,
67
+ objJsonToObjectStructure,
67
68
  readSerializedSpaceArchive,
68
69
  writeSerializedSpaceArchive,
69
- objJsonToObjectStructure,
70
70
  } from '../space-export';
71
71
  import { type DataSpace } from './data-space';
72
72
  import { type DataSpaceManager } from './data-space-manager';
@@ -9,10 +9,10 @@ import { ProfileArchiveEntryType } from '@dxos/protocols';
9
9
 
10
10
  import { decodeProfileArchive, encodeProfileArchive } from './profile-archive';
11
11
  import {
12
+ OPFS_SQLITE_DB_FILENAME,
12
13
  createSqliteProfileArchive,
13
14
  getSqliteProfileEntries,
14
15
  isValidSqliteDatabase,
15
- OPFS_SQLITE_DB_FILENAME,
16
16
  } from './profile-archive-sqlite';
17
17
 
18
18
  const sqliteHeader = (): Uint8Array => {
@@ -20,9 +20,9 @@ export const createMockCredential = async ({
20
20
  subject: new PublicKey(Buffer.from('test')),
21
21
  assertion: {
22
22
  '@type': 'example.testing.rpc.MessageWithAny',
23
- payload: {
23
+ 'payload': {
24
24
  '@type': 'google.protobuf.Any',
25
- value: Buffer.from('test'),
25
+ 'value': Buffer.from('test'),
26
26
  },
27
27
  },
28
28
  });
package/src/version.ts CHANGED
@@ -1,5 +1 @@
1
- //
2
- // Copyright 2023 DXOS.org
3
- //
4
-
5
- export const DXOS_VERSION = '0.9.0'; // {x-release-please-version}
1
+ export const DXOS_VERSION = "0.9.1-staging.ee54ba693a";