@qvac/core 0.8.0 → 0.9.0

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/CHANGELOG.md CHANGED
@@ -13,6 +13,25 @@ release.
13
13
 
14
14
  ## [Unreleased]
15
15
 
16
+ ## [0.9.0] - 2026-10-15
17
+
18
+ ### Changed
19
+
20
+ - **Breaking:** `meshInvite` mints a member invite as `qvac://workspace/…` and
21
+ a device invite as `qvac://device/…`, instead of `qvac://mesh/…`
22
+ (QVAC-26926). `joinMesh`, `previewMeshInvite` and `decodeMeshInvite` read all
23
+ three, so a link shared before still works, but a release before this one
24
+ refuses the new links with `Invalid mesh invite`: both sides of a join need
25
+ this version. An app that matches the prefix itself has to accept all three
26
+ before it takes this release, as tetherto/qvac-app#2535 does. (#394)
27
+
28
+ ```js
29
+ const { invite } = await engine.meshInvite({ meshId, member: true })
30
+ // 0.8: qvac://mesh/… 0.9: qvac://workspace/…
31
+ const { invite: pairing } = await engine.meshInvite({})
32
+ // 0.8: qvac://mesh/… 0.9: qvac://device/…
33
+ ```
34
+
16
35
  ## [0.8.0] - 2026-10-15
17
36
 
18
37
  ### Added
@@ -1669,7 +1688,8 @@ Published under the `release-0.1` dist-tag.
1669
1688
  await assistant.ready()
1670
1689
  ```
1671
1690
 
1672
- [Unreleased]: https://github.com/tetherto/qvac-core/compare/v0.8.0...HEAD
1691
+ [Unreleased]: https://github.com/tetherto/qvac-core/compare/v0.9.0...HEAD
1692
+ [0.9.0]: https://github.com/tetherto/qvac-core/compare/v0.8.0...v0.9.0
1673
1693
  [0.8.0]: https://github.com/tetherto/qvac-core/compare/v0.7.6...v0.8.0
1674
1694
  [0.7.6]: https://github.com/tetherto/qvac-core/compare/v0.7.5...v0.7.6
1675
1695
  [0.7.5]: https://github.com/tetherto/qvac-core/compare/v0.7.4...v0.7.5
package/README.md CHANGED
@@ -722,7 +722,7 @@ The TUI copies its mesh invite to the clipboard on ctrl+y. On a second machine
722
722
  (or a second terminal), start `duck` and join from inside it:
723
723
 
724
724
  ```
725
- /join qvac://mesh/…
725
+ /join qvac://device/…
726
726
  ```
727
727
 
728
728
  The preview says who you would join as. A device invite (`/invite`) retires the
@@ -1,7 +1,10 @@
1
1
  import * as z32 from 'z32';
2
2
  import { decode as decodeStruct, encode as encodeStruct } from '../../spec/mesh/hyperschema/index.js';
3
3
  const INVITE_STRUCT = '@qvac/mesh-invite';
4
- const INVITE_PREFIX = 'qvac://mesh/';
4
+ const MEMBER_INVITE_PREFIX = 'qvac://workspace/';
5
+ const DEVICE_INVITE_PREFIX = 'qvac://device/';
6
+ const LEGACY_INVITE_PREFIX = 'qvac://mesh/';
7
+ const INVITE_PREFIXES = [MEMBER_INVITE_PREFIX, DEVICE_INVITE_PREFIX, LEGACY_INVITE_PREFIX];
5
8
  export function encodeMeshInvite(invite) {
6
9
  const payload = {
7
10
  meshKey: invite.baseKey,
@@ -17,16 +20,18 @@ export function encodeMeshInvite(invite) {
17
20
  deviceSeed: invite.deviceSeed ?? null,
18
21
  deviceProof: invite.deviceProof ?? null
19
22
  };
20
- return INVITE_PREFIX + z32.encode(encodeStruct(INVITE_STRUCT, payload));
23
+ const prefix = invite.memberInvite ? MEMBER_INVITE_PREFIX : DEVICE_INVITE_PREFIX;
24
+ return prefix + z32.encode(encodeStruct(INVITE_STRUCT, payload));
21
25
  }
22
26
  export function decodeMeshInvite(raw) {
23
27
  const value = raw.trim().toLowerCase();
24
- if (!value.startsWith(INVITE_PREFIX)) {
28
+ const prefix = INVITE_PREFIXES.find((p) => value.startsWith(p));
29
+ if (!prefix) {
25
30
  return null;
26
31
  }
27
32
  let payload;
28
33
  try {
29
- payload = decodeStruct(INVITE_STRUCT, z32.decode(value.slice(INVITE_PREFIX.length)));
34
+ payload = decodeStruct(INVITE_STRUCT, z32.decode(value.slice(prefix.length)));
30
35
  }
31
36
  catch {
32
37
  return null;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@qvac/core",
3
- "version": "0.8.0",
3
+ "version": "0.9.0",
4
4
  "type": "module",
5
5
  "description": "Peer-to-peer AI across your devices",
6
6
  "engines": {
package/tui/README.md CHANGED
@@ -45,7 +45,7 @@ Bare's native TTY; the TUI will not run under node.
45
45
  duck [--storage <dir>] [--temp] [--headless] [--join <invite>] [--device-join <invite>] [--fake-models]
46
46
  ```
47
47
 
48
- Flags may appear in any order. Inside the app, `/join qvac://mesh/…` moves a
48
+ Flags may appear in any order. Inside the app, `/join qvac://device/…` moves a
49
49
  running instance to another mesh.
50
50
 
51
51
  - `--storage <dir>` — a self-contained root (its own corestore and SDK home
@@ -82,7 +82,7 @@ those too.
82
82
  The TUI copies its mesh invite to the clipboard on ctrl+y. With no clipboard
83
83
  command (a container, ssh) it asks your terminal to set the clipboard with
84
84
  OSC 52, which the terminal has to allow. A running TUI moves
85
- mesh with `/join qvac://mesh/…`. See [../docs/tui-commands.md](../docs/tui-commands.md)
85
+ mesh with `/join qvac://device/…`. See [../docs/tui-commands.md](../docs/tui-commands.md)
86
86
  for the full command set.
87
87
 
88
88
  ## Environment
package/tui/app.mjs CHANGED
@@ -2469,7 +2469,7 @@ export class ChatApp {
2469
2469
  'Advanced',
2470
2470
  ' /cred <key> <value> — set a credential by hand for this agent (e.g. /cred github_access_token ghp_…); /skills, enter on the skill, fills this in for you',
2471
2471
  ' /scope skills all|selected — switch scope',
2472
- ' /join <qvac://mesh/…> — preview who you would join as (ctrl+y copies this mesh’s invite) · /join yes — confirm it (a device invite retires this device’s mesh, a member invite adds one beside it) · /join cancel — abort a join in progress',
2472
+ ' /join <qvac://device/… or qvac://workspace/…> — preview who you would join as (ctrl+y copies this mesh’s invite) · /join yes — confirm it (a device invite retires this device’s mesh, a member invite adds one beside it) · /join cancel — abort a join in progress',
2473
2473
  ' /leave — leave the active mesh; the device lands on another mesh it can write to, or mints a fresh account',
2474
2474
  ' /invite - show this mesh device invite · /invite member - open your shared mesh and invite someone into it (your account is never shared)',
2475
2475
  ' /mesh new - open another shared mesh · /mesh new compute - lend this device · /mesh label <n|id> <name> - name a mesh, privately to you',
@@ -3571,7 +3571,7 @@ export class ChatApp {
3571
3571
  if (cmd === 'join') {
3572
3572
  const arg = rawArgs.trim()
3573
3573
  if (!arg) {
3574
- return notice('usage: /join <qvac://mesh/…> · /join cancel')
3574
+ return notice('usage: /join <qvac://device/… or qvac://workspace/…> · /join cancel')
3575
3575
  }
3576
3576
 
3577
3577
  if (rest[0] === 'cancel') {
@@ -3585,7 +3585,9 @@ export class ChatApp {
3585
3585
  if (rest[0] === 'yes') {
3586
3586
  const pending = this._pendingJoinInvite
3587
3587
  if (!pending) {
3588
- return notice('usage: /join <qvac://mesh/…> to preview an invite first')
3588
+ return notice(
3589
+ 'usage: /join <qvac://device/… or qvac://workspace/…> to preview an invite first'
3590
+ )
3589
3591
  }
3590
3592
 
3591
3593
  this._pendingJoinInvite = null
@@ -5164,7 +5166,11 @@ export class ChatApp {
5164
5166
  entries: [
5165
5167
  { label: 'Meshes', hint: 'the meshes this device belongs to', command: '/meshes' },
5166
5168
  { label: 'Switch mesh…', hint: '/mesh use <n|id>', prefill: '/mesh use ' },
5167
- { label: 'Join mesh…', hint: '/join <qvac://mesh/…>', prefill: '/join ' },
5169
+ {
5170
+ label: 'Join mesh…',
5171
+ hint: '/join <qvac://device/… or qvac://workspace/…>',
5172
+ prefill: '/join '
5173
+ },
5168
5174
  { label: 'Leave mesh', hint: 'leave the active mesh', command: '/leave' },
5169
5175
  { label: 'Cancel join', hint: 'abort a join in progress', command: '/join cancel' }
5170
5176
  ]
package/tui/boot.mjs CHANGED
@@ -54,7 +54,7 @@ function bootInvite({ join, deviceJoin }) {
54
54
 
55
55
  const invite = decodeMeshInvite(raw)
56
56
  if (!invite) {
57
- throw new Error('not a mesh invite: expected qvac://mesh/…')
57
+ throw new Error('not a mesh invite: expected qvac://device/… or qvac://workspace/…')
58
58
  }
59
59
 
60
60
  if (join && !invite.memberInvite) {