@c4roa0/agentpay-user 0.3.5 → 0.3.7

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/doc/README.md CHANGED
@@ -1,5 +1,7 @@
1
1
  # User documentation
2
2
 
3
+ - [Existing-installation update acceptance](records/npm-update-participant-2026-11-11.md): participant update to User 0.3.6 / Wallet 0.3.3 and retained records.
4
+
3
5
  - [Directory npm update verification](records/local-npm-update-2026-11-08.md): real package update and preflight boundary.
4
6
 
5
7
  ## Start by role
package/doc/TODO.md CHANGED
@@ -1,23 +1,39 @@
1
1
  # User TODO
2
2
 
3
+ - [x] Participant directory-local update to User 0.3.6 / Wallet 0.3.3: running versions, original Orders in CLI/Market and available result cache verified (2026-11-11).
4
+ - [ ] Fresh-install and interrupted-update acceptance remain separate; discuss scope before execution.
5
+
6
+
7
+ - [x] Clarify full Cache IDs and missing details argument; support bounded, unique read-only short-ID lookup (2026-11-11).
8
+ - [ ] Publish cache-details guidance with the next reviewed User release.
9
+
10
+
11
+ - [x] Clarify npm update preview with actual installed Wallet versus target, unchanged and unknown states (2026-11-11).
12
+ - [ ] Include update-preview wording in the next reviewed User release; no new release was made for this edit.
13
+
14
+
15
+ - [x] Preserve maintenance error guidance and original request identity; controlled HTTP/IPC verification (2026-11-10).
16
+ - [x] Publish User 0.3.6 with exact Wallet 0.3.3 dependency; registry identity/integrity verified (2026-11-10).
17
+
3
18
  ## Existing Market address update
4
19
 
5
20
  - [x] Allow source-to-npm reconnect without an onboarding draft; verify Policy contracts and preserve missing files.
6
- - [ ] Publish 0.3.5 and retry the participant address update.
21
+ - [x] Publish 0.3.5 and independently verify registry integrity.
22
+ - [x] Retry the participant address update without old onboarding files. Observed User 0.3.5 / Wallet 0.3.2 on 2026-11-09.
7
23
 
8
24
  - [x] Reauthenticate and verify original account, Wallet tuple and Policy connection before replacing an address.
9
25
  - [x] Verify unchanged deployment; preserve RPC, key, Policy, history/cache and original cancellation IDs.
10
26
  - [x] Apply under installer lock, restart managed Runtime, retain retry marker and show incomplete update in status.
11
27
  - [x] Full regression (387 checks), followed by targeted reconnect-boundary/transaction checks.
12
28
  - [x] Publish User 0.3.4 through v0.3.4; workflow and independent registry integrity verification passed.
13
- - [ ] Verify the existing participant installation and explicit address update against HTTPS.
29
+ - [x] Verify the existing participant installation and explicit address update against HTTPS. Observed User 0.3.5 / Wallet 0.3.2 on 2026-11-09.
14
30
 
15
31
  ## Directory npm update, then HTTPS
16
32
 
17
33
  - [x] Support directory-local npm update without replacing source/link installs.
18
34
  - [x] Verify real npm directory upgrade and isolated preflight; nine regression checks passed.
19
35
  - [x] Publish 0.3.3 via v0.3.3 and independently verify registry archive/dependency pins.
20
- - [ ] Verify participant directory install/update.
36
+ - [x] Verify participant directory install/update. Observed User 0.3.5 / Wallet 0.3.2 on 2026-11-09.
21
37
 
22
38
  ## Tag-triggered publication
23
39
 
@@ -33,14 +49,15 @@
33
49
  - [x] Verify website visibility and independently reconcile Settlement/chain outcome; prepare User 0.3.2 candidate.
34
50
  - [x] Pin the verified public Wallet 0.3.2; align package/lockfile/update-pair.
35
51
  - [x] Publish User 0.3.2 through tag-triggered OIDC; verify public registry archive.
36
- - [ ] Accept a real participant npm update/restart.
52
+ - [x] Accept a real participant npm update/restart. Observed User 0.3.5 / Wallet 0.3.2 on 2026-11-09.
37
53
 
38
54
 
39
55
  ## Fixed Skill download loop — 2026-11-08
40
56
 
41
57
  - [x] Request the official ZIP by the built-in SHA-256; reject unavailable/substituted versions without fallback.
42
58
  - [x] Complete fixed-download regression/type checks and publication/deletion review; the separate Market schema-fixture issue was resolved in its later regression.
43
- - [ ] After Market API/Web/nginx support is live, publish the next User version (not 0.3.1 again) and verify old pinned ZIP download and participant upgrade.
59
+ - [x] Publish later User versions and accept participant update through 0.3.5.
60
+ - [ ] Independently verify retained old pinned ZIP download; current package acceptance alone does not close historical-version availability.
44
61
 
45
62
 
46
63
  ## Running-version release loop — 2026-11-07
@@ -51,7 +68,7 @@
51
68
  - [x] Wallet 0.3.1 published through the configured workflow; public npm version/dependencies verified.
52
69
  - [x] Pin User 0.3.1 to published Wallet 0.3.1; pairing metadata/lockfile and standalone archive verification complete.
53
70
  - [x] Publish User 0.3.1; verify public npm/latest and successful Wallet/User OIDC runs.
54
- - [ ] Verify real published-version update/restart on the participant installation.
71
+ - [x] Verify real published-version update/restart on the participant installation. Observed User 0.3.5 / Wallet 0.3.2 on 2026-11-09.
55
72
 
56
73
 
57
74
  ## npm update follow-up — 2026-11-07
@@ -59,7 +76,7 @@
59
76
  - [x] Implement confirmed `agentpay update [-f]`, exact User target and matching Wallet; invoke new repair and pinned official Skill check.
60
77
  - [x] Fix relocation preparation ordering, matching legacy purge and packaged document links.
61
78
  - [x] Complete update/migration regressions (374 full-suite and 35 final targeted checks) and real npm replacement of local candidate artifacts; controlled service/registry dependencies.
62
- - [ ] After User release, verify a real published-version npm upgrade and participant service recovery.
79
+ - [x] Verify published-version directory npm update and participant service recovery: User 0.3.5 / Wallet 0.3.2, 2026-11-09. Deliberate interruption remains separate.
63
80
 
64
81
  ## npm client distribution — 2026-11-07
65
82
 
@@ -70,7 +87,8 @@
70
87
  - [x] Step 3: migrate User to Wallet npm dependency and `agentpay` entry; remove sibling/build assumptions; isolated tarball/process acceptance passed.
71
88
  - [x] Step 4a: exact installed-package checks, service-path/client relocation, installer lock, recovery-safe preparation and explicit uninstall modes.
72
89
  - [x] Step 4b implementation: installed/running version and interface checks.
73
- - [ ] Step 4b acceptance: participant upgrade/interruption recovery (same gate as the running-version loop above).
90
+ - [x] Step 4b participant existing-installation update/restart and HTTPS original-Order read recovery (2026-11-09).
91
+ - [ ] Step 4b deliberate interrupted-upgrade acceptance; normal restart recovery does not close this case.
74
92
  - [ ] Step 5: publish Wallet then User via OIDC; verify registry installs and update Market guides.
75
93
  - [x] Wallet 0.3.0 first Token publication; registry integrity/latest and fresh public install/CLI/IPC verified.
76
94
  - [x] Owner configured Wallet npm Trusted Publisher; validated by 0.3.1 publication.
@@ -0,0 +1,25 @@
1
+ # Existing npm installation update acceptance
2
+
3
+ Date: 2026-11-11. Evidence: participant terminal output and website confirmation.
4
+
5
+ The participant updated a directory-local npm installation through `agentpay update`:
6
+ User 0.3.5 to 0.3.6, with matching Wallet 0.3.3. The update repaired service paths,
7
+ restarted Wallet and Runtime, and verified official test Skill 1.2.1 against the
8
+ built-in SHA-256 without starting a purchase. After deliberate unlock, status
9
+ reported Wallet 0.3.3 and Runtime 0.3.6 running, with local history checks complete.
10
+
11
+ Both saved Orders remained settled. Policy validity, login startup and the locally
12
+ saved Market connection remained present. The participant confirmed both Orders
13
+ were still visible on the website. The retained result cache listed its original
14
+ timestamp and Order association, and details reported the JSON result available
15
+ (28-byte content, approximately 3.4 KiB retained storage). No export or independent
16
+ byte-by-byte backup comparison was performed. The older Order's missing local
17
+ result was already present before updating and was not resolved by this update.
18
+
19
+ Two usability findings were corrected in source: show installed and target Wallet
20
+ versions separately, and clarify full Cache IDs with bounded unique short-ID lookup
21
+ for read-only details. Controlled tests passed; these fixes are not in npm 0.3.6.
22
+
23
+ This accepts the observed existing-installation update and retained records. It
24
+ is not fresh-install, interrupted-update recovery, financial reconciliation or
25
+ real-network acceptance. No new payment or authorization was required.
package/package.json CHANGED
@@ -1,10 +1,10 @@
1
1
  {
2
2
  "name": "@c4roa0/agentpay-user",
3
- "version": "0.3.5",
3
+ "version": "0.3.7",
4
4
  "type": "module",
5
5
  "dependencies": {
6
6
  "@c4roa0/agentpay-protocol": "0.14.3",
7
- "@c4roa0/agentpay-wallet": "0.3.2",
7
+ "@c4roa0/agentpay-wallet": "0.3.3",
8
8
  "ethers": "^6.17.0",
9
9
  "fs-native-extensions": "1.5.3"
10
10
  },
package/progress.md CHANGED
@@ -1,5 +1,86 @@
1
1
  # AgentPay User progress
2
2
 
3
+ ## User 0.3.7 release preparation — 2026-11-11
4
+
5
+ Patch release includes installed/target Wallet version preview and clearer Cache ID
6
+ help with unique short-ID lookup for read-only details. Wallet remains pinned to
7
+ 0.3.3 and Protocol to 0.14.3. Manifest, lockfile and update-pair versions are aligned.
8
+ Publication and registry verification are pending; no local participant service or
9
+ private data is changed by preparing the release.
10
+
11
+
12
+ ## Existing client update accepted — 2026-11-11
13
+
14
+ Participant directory-local npm update to User 0.3.6 / Wallet 0.3.3 completed.
15
+ Running versions, unlocked Wallet, two settled Orders, unchanged saved validity,
16
+ startup/Market connection and retained available result cache were observed.
17
+ Participant confirmed both original Orders remain visible on Market. The older
18
+ missing result predates this update. No new payment or Policy was created.
19
+ [Evidence and limits](doc/records/npm-update-participant-2026-11-11.md). Update-preview and Cache ID guidance fixes are
20
+ verified in source, not yet published. Fresh installation and interrupted-update
21
+ acceptance remain next for discussion; neither has started in this loop.
22
+
23
+
24
+ ## Cache details guidance — 2026-11-11
25
+
26
+ Missing details IDs now show a short example before accessing local storage.
27
+ List guidance explains that the namespace is part of the ID. Read-only details
28
+ accept a unique prefix with at least eight hexadecimal characters; ambiguous,
29
+ missing or incomplete bounded lookups require a full ID. Export and cleanup keep
30
+ their existing exact-identity rules. All 19 targeted cache/CLI regressions passed
31
+ with isolated process tests outside the restricted sandbox; no live cache changed.
32
+ Source only, pending publication. There is no input: ID namespace: inputs use the
33
+ attachment ID shown by list, while results can use result: or runtime-result:0x.
34
+
35
+
36
+ ## Update preview clarity — 2026-11-11
37
+
38
+ The confirmation screen now lists installed User and Wallet versions separately
39
+ from update targets. Wallet is read from the installed dependency, not inferred
40
+ from User's requested dependency. Unchanged versions are explicit; unreadable or
41
+ missing Wallet metadata shows “not confirmed” without blocking the normal repair
42
+ through npm. Controlled update tests cover all three cases and cancellation without
43
+ service/install mutation. This source change is not yet published; running-process
44
+ versions remain the responsibility of status after update/restart.
45
+
46
+
47
+ ## User 0.3.6 published — 2026-11-10
48
+
49
+ Pins published Wallet 0.3.3, retaining Protocol 0.14.3. Maintenance errors provide
50
+ same-request guidance without automatic write retries. Package manifest, lockfile
51
+ and update-pair metadata agree. Published through matching tag v0.3.6 after 391 behavior tests and independent
52
+ installation/lifecycle checks. Public npm metadata and SHA-512 match the verified
53
+ archive. No local data, Policy or service changes occur on publication.
54
+
55
+
56
+ ## Maintenance guidance — 2026-11-10
57
+
58
+ Added explicit maintenance guidance without automatic write retries or replacement
59
+ purchases. Controlled HTTP/IPC tests verify that retry retains original request
60
+ identifiers. This is source verification, not live financial acceptance. These changes were subsequently published in 0.3.6; see the release record above.
61
+
62
+
63
+ ## Acceptance bookkeeping — 2026-11-10
64
+
65
+ Existing-installation npm update/restart and HTTPS original-Order read recovery
66
+ are closed by the 2026-11-09 participant evidence below. Older pending publication
67
+ and migration paragraphs are historical checkpoints, not instructions to repeat
68
+ the accepted update. Deliberate upgrade interruption, clean installation/uninstall
69
+ and historical pinned-download availability remain separate acceptance items.
70
+ No runtime code or package version changed in this documentation closeout.
71
+
72
+
73
+ ## Participant HTTPS address update accepted — 2026-11-09
74
+
75
+ Participant directory-npm installation reports User 0.3.5 / Wallet 0.3.2.
76
+ Market reconnect completed with the existing Wallet and Policy. With Anvil 8547
77
+ forwarded, explicit Settlement Order read succeeded over HTTPS; subsequent Runtime
78
+ status recovered to 2 saved / 2 settled / 0 waiting. The one older missing result
79
+ predates this update and is retained. Initial unavailable checks cleared on retry.
80
+ No new paid Order, Policy replacement or result recovery was performed. This closes
81
+ the observed existing-installation update/address/read-recovery loop, not fresh
82
+ installation, a new HTTPS paid journey or real-network acceptance.
83
+
3
84
  ## Missing onboarding draft during npm address update — 2026-11-09
4
85
 
5
86
  Participant 0.3.4 reconnect stopped before address writes because an old onboarding
@@ -9,7 +90,8 @@ present. No RPC, Policy, test configuration or private history is synthesized.
9
90
  389 full regressions passed, followed by targeted error-guidance checks. Missing
10
91
  drafts still reject contract drift; preflight errors explain the stage, preserved
11
92
  state and retry action, while interrupted writes warn about partial updates.
12
- User 0.3.5 publication is pending;
93
+ User 0.3.5 published from tag v0.3.5 (6c57c12). GitHub run 42575980847
94
+ and independent registry archive verification passed;
13
95
  participant migration remains unverified.
14
96
 
15
97
  ## User 0.3.4 published — 2026-11-09
@@ -399,9 +481,11 @@ approval. Detailed operational records are not distributed in this repository.
399
481
 
400
482
  ## Next work
401
483
 
402
- Public source preparation is complete within the recorded review scope. Next is the approved
403
- [distribution plan](doc/plans/user-wallet-distribution.md): a supported public Wallet
404
- client/version boundary and combined release archive. No automatic source updater.
484
+ Public npm distribution and the existing-participant update/HTTPS loop are verified
485
+ within the recorded scope. User pins Wallet and Protocol packages; npm update is
486
+ available. Combined release archives remain optional, not the next installation
487
+ prerequisite. Remaining compatibility and fresh-install checks follow the
488
+ [distribution plan](doc/plans/user-wallet-distribution.md).
405
489
 
406
490
  Official test network mapping, deployment/artifact handoff, complete interrupted owner
407
491
  signing and real-network acceptance remain open. macOS and graphical unlock remain
@@ -128,6 +128,11 @@ export async function runCacheManagement(
128
128
  }
129
129
  const usage =
130
130
  "Usage: agentpay cache [info | list [PAGE] [input|output] [--state STATE] [--request ID | --order ID] | details ID | export ID PATH | clean | settings [KEY VALUE]]\nAdd --offline only when managing stopped Runtime storage. Wallet unlock is not required.";
131
+ if(action === "details" && rest.length === 0){
132
+ write("Choose a Cache ID from agentpay cache list. Copy the whole ID, including any prefix such as result:.");
133
+ write("Example: agentpay cache details result:5aa18b50\nA unique short ID needs at least 8 hexadecimal characters.");
134
+ return 2;
135
+ }
131
136
  if (
132
137
  invalidFilter ||
133
138
  !["summary", "list", "details", "export", "clean", "settings"].includes(
@@ -192,7 +197,7 @@ export async function runCacheManagement(
192
197
  ...(rest[1] ? { purpose: rest[1] } : {}),
193
198
  });
194
199
  write(
195
- `\n${r.total} entries · page ${page}\nDetails: agentpay cache details <Cache ID>`,
200
+ `\n${r.total} entries · page ${page}\nDetails: agentpay cache details <Cache ID>\nCopy the full ID including its prefix, or use a unique short ID (8+ hex characters).`,
196
201
  );
197
202
  if (!r.items.length)
198
203
  write("No saved results or attachments match this view.");
@@ -222,7 +227,32 @@ export async function runCacheManagement(
222
227
  .join("")}`,
223
228
  );
224
229
  } else if (action === "details") {
225
- const r = await operate({ action, id: rest[0] });
230
+ let id=rest[0];
231
+ if(!/^(?:result:|runtime-result:0x)?[0-9a-f]{64}$/.test(id)){
232
+ if(!/^(?:result:|runtime-result:0x)?[0-9a-f]{8,63}$/.test(id)){
233
+ write('Use the Cache ID from agentpay cache list, or its first 8 or more hexadecimal characters.');
234
+ return 2;
235
+ }
236
+ // Resolve only read-only details. Bound enumeration; never guess from an
237
+ // incomplete list or turn a short display identifier into a cleanup key.
238
+ const matches=new Set();let offset=0,total;
239
+ do {
240
+ const page=await operate({action:'list',offset,limit:100});
241
+ if(page.total>1000 || total!==undefined&&page.total!==total || !page.items.length&&offset<page.total){
242
+ write('Use the full Cache ID; the cache is too large or changed during lookup.');return 2;
243
+ }
244
+ total=page.total;
245
+ for(const row of page.items){
246
+ const key=id.includes(':')?row.id:row.id.replace(/^(?:result:|runtime-result:0x)/,'');
247
+ if(key.startsWith(id))matches.add(row.id);
248
+ }
249
+ if(matches.size>1){write('More than one cache entry matches. Copy a longer or full Cache ID from agentpay cache list.');return 2;}
250
+ offset+=page.items.length;
251
+ }while(offset<total);
252
+ if(!matches.size){write('No cache entry matches. Run agentpay cache list and copy its Cache ID.');return 2;}
253
+ id=[...matches][0];
254
+ }
255
+ const r = await operate({ action, id });
226
256
  write(
227
257
  `${safe(r.filename)}\n ${contentSize(r)} · ${r.state}\n ${r.requestId ? "Request" : "Order"}: ${safe(r.requestId || r.orderId)}\n File key: ${safe(r.fileKey)}\n SHA-256: ${r.sha256 || "Not available"}\n Updated: ${new Date(r.updatedAtMs).toLocaleString()}`,
228
258
  );
@@ -7,6 +7,7 @@ import { access, appendFile, copyFile, chmod, lstat, mkdir, mkdtemp, open, readF
7
7
  import { constants } from 'node:fs';
8
8
  import { basename, dirname, isAbsolute, join, resolve } from 'node:path';
9
9
  import { randomUUID } from 'node:crypto';
10
+ import { createRequire } from 'node:module';
10
11
  import { createInterface } from 'node:readline/promises';
11
12
  import { installedUserDir, resolveUserDataDir, rememberUserDataDir } from './local-data-directory.mjs';
12
13
  import { installationDirectory } from './installation-paths.mjs';
@@ -91,7 +92,18 @@ export async function updateFromNpm({
91
92
  await officialTest({userDir,dataDir,write});
92
93
  return 0;
93
94
  }
94
- write(`User ${current.version} → ${metadata.version} · Wallet ${metadata.dependencies['@c4roa0/agentpay-wallet']}`);
95
+ // Read the installed dependency, not the version requested by User's manifest.
96
+ // Missing/broken packages must not prevent npm from repairing the installation.
97
+ let walletVersion;
98
+ try {
99
+ const file = createRequire(join(userDir,'package.json')).resolve('@c4roa0/agentpay-wallet/package.json');
100
+ const wallet = JSON.parse(await readFile(file,'utf8'));
101
+ if(wallet.name === '@c4roa0/agentpay-wallet' && stable(wallet.version)) walletVersion = wallet.version;
102
+ } catch {}
103
+ const targetWallet = metadata.dependencies['@c4roa0/agentpay-wallet'];
104
+ write('Installed packages → update target');
105
+ write(`User ${current.version} → ${metadata.version}`);
106
+ write(`Wallet ${walletVersion === targetWallet ? `${walletVersion} (unchanged)` : `${walletVersion || 'not confirmed'} → ${targetWallet}`}`);
95
107
  write(`Installation folder: ${target.prefix}`);
96
108
  write('Background services will pause. Keys, permissions, Orders and cache are kept.');
97
109
  if (!force && (await ask("Type 'confirm' to update, or 'q' to cancel")).trim().toLowerCase() !== 'confirm') {
@@ -676,7 +676,7 @@ async function invokeSaved(
676
676
  WALLET_LOCKED:
677
677
  "From the User repository, run agentpay wallet unlock, then resume this request.",
678
678
  SERVICE_MAINTENANCE:
679
- "Service is under maintenance. Resume this request later.",
679
+ "The service is under maintenance. Try this same request later; do not create a replacement purchase.",
680
680
  SERVICE_NOT_READY:
681
681
  "Service is not ready. Check its status, then resume this request.",
682
682
  };
package/update-pair.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "format": "agentpay.local-update-pair.v1",
3
- "userVersion": "0.3.5",
4
- "walletVersion": "0.3.2",
3
+ "userVersion": "0.3.7",
4
+ "walletVersion": "0.3.3",
5
5
  "typesDependency": "0.14.3"
6
6
  }