@storacha/clawracha 0.1.4 → 0.1.6

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.
@@ -1 +1 @@
1
- {"version":3,"file":"apply.d.ts","sourceRoot":"","sources":["../../src/handlers/apply.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAIH,OAAO,KAAK,EACV,eAAe,EACf,QAAQ,EACR,SAAS,EACV,MAAM,wBAAwB,CAAC;AAChC,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,cAAc,CAAC;AAG1C,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAChD,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,wBAAwB,CAAC;AAElE,MAAM,WAAW,WAAW;IAC1B,OAAO,EAAE,SAAS,GAAG,IAAI,CAAC;IAC1B,cAAc,EAAE,KAAK,EAAE,CAAC;CACzB;AAED,wBAAsB,eAAe,CACnC,MAAM,EAAE,mBAAmB,EAC3B,IAAI,EAAE,QAAQ,EACd,OAAO,EAAE,SAAS,GAAG,IAAI,EACzB,UAAU,EAAE,MAAM,EAAE,EACpB,OAAO,CAAC,EAAE;IAAE,OAAO,CAAC,EAAE,eAAe,EAAE,CAAA;CAAE,GACxC,OAAO,CAAC,WAAW,CAAC,CA+CtB"}
1
+ {"version":3,"file":"apply.d.ts","sourceRoot":"","sources":["../../src/handlers/apply.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAIH,OAAO,KAAK,EACV,eAAe,EACf,QAAQ,EACR,SAAS,EACV,MAAM,wBAAwB,CAAC;AAChC,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,cAAc,CAAC;AAG1C,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAChD,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,wBAAwB,CAAC;AAElE,MAAM,WAAW,WAAW;IAC1B,OAAO,EAAE,SAAS,GAAG,IAAI,CAAC;IAC1B,cAAc,EAAE,KAAK,EAAE,CAAC;CACzB;AAED,wBAAsB,eAAe,CACnC,MAAM,EAAE,mBAAmB,EAC3B,IAAI,EAAE,QAAQ,EACd,OAAO,EAAE,SAAS,GAAG,IAAI,EACzB,UAAU,EAAE,MAAM,EAAE,EACpB,OAAO,CAAC,EAAE;IAAE,OAAO,CAAC,EAAE,eAAe,EAAE,CAAA;CAAE,GACxC,OAAO,CAAC,WAAW,CAAC,CAoEtB"}
@@ -24,7 +24,12 @@ export async function applyPendingOps(blocks, name, current, pendingOps, options
24
24
  if (firstPut?.value) {
25
25
  const result = await Revision.v0Put(fetcher, firstPut.key, firstPut.value);
26
26
  accumulate(result.additions);
27
- const pubResult = await Revision.publish(fetcher, name, result.revision, { remotes: options?.remotes });
27
+ console.debug("publishing v0Put revision", JSON.stringify(result.revision, null, 2));
28
+ console.debug("v0Put additions:", result.additions.map((b) => b.cid.toString()));
29
+ const pubResult = await Revision.publish(fetcher, name, result.revision, {
30
+ remotes: options?.remotes,
31
+ });
32
+ console.debug("published v0Put revision", JSON.stringify(pubResult, null, 2));
28
33
  accumulate(pubResult.additions);
29
34
  current = pubResult.value;
30
35
  ops = ops.filter((op) => op !== firstPut);
@@ -42,7 +47,9 @@ export async function applyPendingOps(blocks, name, current, pendingOps, options
42
47
  }
43
48
  const result = await batcher.commit();
44
49
  accumulate(result.additions);
45
- const pubResult = await Revision.publish(fetcher, name, result.revision, { remotes: options?.remotes });
50
+ const pubResult = await Revision.publish(fetcher, name, result.revision, {
51
+ remotes: options?.remotes,
52
+ });
46
53
  accumulate(pubResult.additions);
47
54
  current = pubResult.value;
48
55
  }
@@ -1 +1 @@
1
- {"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../src/plugin.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAIH,OAAO,KAAK,EACV,iBAAiB,EAGlB,MAAM,qBAAqB,CAAC;AAgH7B,MAAM,CAAC,OAAO,UAAU,MAAM,CAAC,GAAG,EAAE,iBAAiB,QA6jBpD"}
1
+ {"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../src/plugin.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAIH,OAAO,KAAK,EACV,iBAAiB,EAGlB,MAAM,qBAAqB,CAAC;AAgH7B,MAAM,CAAC,OAAO,UAAU,MAAM,CAAC,GAAG,EAAE,iBAAiB,QAmkBpD"}
package/dist/plugin.js CHANGED
@@ -231,6 +231,8 @@ export default function plugin(api) {
231
231
  }
232
232
  catch (err) {
233
233
  console.error(`Error: ${err.message}`);
234
+ if (err.stack)
235
+ console.error(err.stack);
234
236
  process.exit(1);
235
237
  }
236
238
  });
@@ -306,6 +308,8 @@ export default function plugin(api) {
306
308
  catch { }
307
309
  }
308
310
  console.error(`Error: ${err.message}`);
311
+ if (err.stack)
312
+ console.error(err.stack);
309
313
  process.exit(1);
310
314
  }
311
315
  });
@@ -368,6 +372,8 @@ export default function plugin(api) {
368
372
  catch { }
369
373
  }
370
374
  console.error(`Error: ${err.message}`);
375
+ if (err.stack)
376
+ console.error(err.stack);
371
377
  process.exit(1);
372
378
  }
373
379
  });
@@ -447,6 +453,8 @@ export default function plugin(api) {
447
453
  }
448
454
  catch (err) {
449
455
  console.error(`Error: ${err.message}`);
456
+ if (err.stack)
457
+ console.error(err.stack);
450
458
  process.exit(1);
451
459
  }
452
460
  });
@@ -484,6 +492,8 @@ export default function plugin(api) {
484
492
  }
485
493
  catch (err) {
486
494
  console.error(`Error: ${err.message}`);
495
+ if (err.stack)
496
+ console.error(err.stack);
487
497
  process.exit(1);
488
498
  }
489
499
  });
@@ -530,6 +540,8 @@ export default function plugin(api) {
530
540
  }
531
541
  catch (err) {
532
542
  console.error(`Error: ${err.message}`);
543
+ if (err.stack)
544
+ console.error(err.stack);
533
545
  process.exit(1);
534
546
  }
535
547
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@storacha/clawracha",
3
- "version": "0.1.4",
3
+ "version": "0.1.6",
4
4
  "description": "OpenClaw plugin for Storacha workspace sync via UCN Pail",
5
5
  "type": "module",
6
6
  "files": [