@stryke/capnp 0.6.2 → 0.6.3

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.
@@ -5,7 +5,7 @@ var __export = (target, all) => {
5
5
  __defProp(target, name, { get: all[name], enumerable: true });
6
6
  };
7
7
 
8
- // ../../node_modules/.pnpm/capnp-es@0.0.11_patch_hash=80802686e11e663486f933dfdd5c01c5f57e003c1be30d468e18dd25b995f95b_typescript@5.8.3/node_modules/capnp-es/dist/shared/capnp-es.0-_cOx6D.mjs
8
+ // ../../node_modules/.pnpm/capnp-es@0.0.11_patch_hash=8f737a83e1b5be10396ff9b257b56b8b8e7a3dbd2754765e9b1e2019839e9c31_typescript@5.8.3/node_modules/capnp-es/dist/shared/capnp-es.0-_cOx6D.mjs
9
9
  var ListElementSize = /* @__PURE__ */ ((ListElementSize2) => {
10
10
  ListElementSize2[ListElementSize2["VOID"] = 0] = "VOID";
11
11
  ListElementSize2[ListElementSize2["BIT"] = 1] = "BIT";
@@ -2092,7 +2092,7 @@ function checkDataBounds(byteOffset, byteLength, s) {
2092
2092
  }
2093
2093
  __name(checkDataBounds, "checkDataBounds");
2094
2094
 
2095
- // ../../node_modules/.pnpm/capnp-es@0.0.11_patch_hash=80802686e11e663486f933dfdd5c01c5f57e003c1be30d468e18dd25b995f95b_typescript@5.8.3/node_modules/capnp-es/dist/shared/capnp-es.GpvEvMIK.mjs
2095
+ // ../../node_modules/.pnpm/capnp-es@0.0.11_patch_hash=8f737a83e1b5be10396ff9b257b56b8b8e7a3dbd2754765e9b1e2019839e9c31_typescript@5.8.3/node_modules/capnp-es/dist/shared/capnp-es.GpvEvMIK.mjs
2096
2096
  var ArenaKind = /* @__PURE__ */ ((ArenaKind2) => {
2097
2097
  ArenaKind2[ArenaKind2["SINGLE_SEGMENT"] = 0] = "SINGLE_SEGMENT";
2098
2098
  ArenaKind2[ArenaKind2["MULTI_SEGMENT"] = 1] = "MULTI_SEGMENT";
@@ -3089,7 +3089,7 @@ function copy(m) {
3089
3089
  }
3090
3090
  __name(copy, "copy");
3091
3091
 
3092
- // ../../node_modules/.pnpm/capnp-es@0.0.11_patch_hash=80802686e11e663486f933dfdd5c01c5f57e003c1be30d468e18dd25b995f95b_typescript@5.8.3/node_modules/capnp-es/dist/shared/capnp-es.BvfUH5E6.mjs
3092
+ // ../../node_modules/.pnpm/capnp-es@0.0.11_patch_hash=8f737a83e1b5be10396ff9b257b56b8b8e7a3dbd2754765e9b1e2019839e9c31_typescript@5.8.3/node_modules/capnp-es/dist/shared/capnp-es.BvfUH5E6.mjs
3093
3093
  function CompositeList(CompositeClass) {
3094
3094
  return class extends List {
3095
3095
  static _capnp = {
@@ -44,7 +44,7 @@ import {
44
44
  setUint64,
45
45
  setUint8,
46
46
  testWhich
47
- } from "./chunk-7QZRCXNX.js";
47
+ } from "./chunk-N5AOPRAP.js";
48
48
 
49
49
  // ../path/src/exists.ts
50
50
  import { existsSync as existsSyncFs } from "node:fs";
@@ -925,10 +925,10 @@ var writeFile = /* @__PURE__ */ __name(async (filePath, content = "", options =
925
925
  return writeFileFs(filePath, content || "", options);
926
926
  }, "writeFile");
927
927
 
928
- // ../../node_modules/.pnpm/capnp-es@0.0.11_patch_hash=80802686e11e663486f933dfdd5c01c5f57e003c1be30d468e18dd25b995f95b_typescript@5.8.3/node_modules/capnp-es/dist/shared/capnp-es.CbTQkT9D.mjs
928
+ // ../../node_modules/.pnpm/capnp-es@0.0.11_patch_hash=8f737a83e1b5be10396ff9b257b56b8b8e7a3dbd2754765e9b1e2019839e9c31_typescript@5.8.3/node_modules/capnp-es/dist/shared/capnp-es.CbTQkT9D.mjs
929
929
  import ts from "typescript";
930
930
 
931
- // ../../node_modules/.pnpm/capnp-es@0.0.11_patch_hash=80802686e11e663486f933dfdd5c01c5f57e003c1be30d468e18dd25b995f95b_typescript@5.8.3/node_modules/capnp-es/dist/capnp/schema.mjs
931
+ // ../../node_modules/.pnpm/capnp-es@0.0.11_patch_hash=8f737a83e1b5be10396ff9b257b56b8b8e7a3dbd2754765e9b1e2019839e9c31_typescript@5.8.3/node_modules/capnp-es/dist/capnp/schema.mjs
932
932
  var _capnpFileId = BigInt("0xa93fc509624c72d9");
933
933
  var Node_Parameter = class extends Struct {
934
934
  static {
@@ -3588,7 +3588,7 @@ CodeGeneratorRequest._Nodes = CompositeList(Node);
3588
3588
  CodeGeneratorRequest._SourceInfo = CompositeList(Node_SourceInfo);
3589
3589
  CodeGeneratorRequest._RequestedFiles = CompositeList(CodeGeneratorRequest_RequestedFile);
3590
3590
 
3591
- // ../../node_modules/.pnpm/capnp-es@0.0.11_patch_hash=80802686e11e663486f933dfdd5c01c5f57e003c1be30d468e18dd25b995f95b_typescript@5.8.3/node_modules/capnp-es/dist/shared/capnp-es.CbTQkT9D.mjs
3591
+ // ../../node_modules/.pnpm/capnp-es@0.0.11_patch_hash=8f737a83e1b5be10396ff9b257b56b8b8e7a3dbd2754765e9b1e2019839e9c31_typescript@5.8.3/node_modules/capnp-es/dist/shared/capnp-es.CbTQkT9D.mjs
3592
3592
  var GEN_EXPLICIT_DEFAULT_NON_PRIMITIVE = "CAPNP-ES000 Don't know how to generate a %s field with an explicit default value.";
3593
3593
  var GEN_FIELD_NON_INLINE_STRUCT_LIST = "CAPNP-ES001 Don't know how to generate non-inline struct lists.";
3594
3594
  var GEN_NODE_LOOKUP_FAIL = "CAPNP-ES002 Failed to look up node id %s.";
@@ -4737,7 +4737,7 @@ function generateCapnpImport(ctx) {
4737
4737
  (n) => n.name === "importPath"
4738
4738
  );
4739
4739
  const importAnnotation = tsImportPathAnnotation && fileNode.annotations.find((a) => a.id === tsImportPathAnnotation.id);
4740
- const importPath = importAnnotation === void 0 ? "capnp-es" : importAnnotation.value.text;
4740
+ const importPath = importAnnotation === void 0 ? "storm-capnp" : importAnnotation.value.text;
4741
4741
  ctx.codeParts.push(`import * as $ from '${importPath}';`);
4742
4742
  }
4743
4743
  __name(generateCapnpImport, "generateCapnpImport");
@@ -4746,7 +4746,7 @@ function generateNestedImports(ctx) {
4746
4746
  const { name } = imp;
4747
4747
  let importPath;
4748
4748
  if (name.startsWith("/capnp/")) {
4749
- importPath = `capnp-es/capnp/${name.slice(7).replace(/\.capnp$/, "")}`;
4749
+ importPath = `storm-capnp/capnp/${name.slice(7).replace(/\.capnp$/, "")}`;
4750
4750
  } else {
4751
4751
  importPath = name.replace(/\.capnp$/, ".js");
4752
4752
  if (importPath[0] !== ".") {
@@ -4831,6 +4831,7 @@ function tsCompile(files, dts, js, tsconfig) {
4831
4831
  const compileOptions = {
4832
4832
  moduleResolution: ts.ModuleResolutionKind.Bundler,
4833
4833
  target: ts.ScriptTarget.ESNext,
4834
+ strict: true,
4834
4835
  ...tsconfig,
4835
4836
  noEmitOnError: false,
4836
4837
  noFallthroughCasesInSwitch: true,
@@ -4841,7 +4842,6 @@ function tsCompile(files, dts, js, tsconfig) {
4841
4842
  removeComments: false,
4842
4843
  skipLibCheck: true,
4843
4844
  sourceMap: false,
4844
- strict: true,
4845
4845
  emitDeclarationOnly: dts && !js,
4846
4846
  declaration: dts
4847
4847
  };
@@ -4886,7 +4886,7 @@ function tsCompile(files, dts, js, tsconfig) {
4886
4886
  }
4887
4887
  __name(tsCompile, "tsCompile");
4888
4888
 
4889
- // ../../node_modules/.pnpm/capnp-es@0.0.11_patch_hash=80802686e11e663486f933dfdd5c01c5f57e003c1be30d468e18dd25b995f95b_typescript@5.8.3/node_modules/capnp-es/dist/compiler/index.mjs
4889
+ // ../../node_modules/.pnpm/capnp-es@0.0.11_patch_hash=8f737a83e1b5be10396ff9b257b56b8b8e7a3dbd2754765e9b1e2019839e9c31_typescript@5.8.3/node_modules/capnp-es/dist/compiler/index.mjs
4890
4890
  import "typescript";
4891
4891
 
4892
4892
  // src/compile.ts
package/dist/compile.cjs CHANGED
@@ -1,7 +1,7 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
2
 
3
- var _chunk34UFVQ2Xcjs = require('./chunk-34UFVQ2X.cjs');
4
- require('./chunk-IJMQEVSJ.cjs');
3
+ var _chunkM5QB7J6Hcjs = require('./chunk-M5QB7J6H.cjs');
4
+ require('./chunk-5MK6PQWW.cjs');
5
5
 
6
6
 
7
- exports.capnpc = _chunk34UFVQ2Xcjs.capnpc;
7
+ exports.capnpc = _chunkM5QB7J6Hcjs.capnpc;
package/dist/compile.js CHANGED
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  capnpc
3
- } from "./chunk-FGRQLKDC.js";
4
- import "./chunk-7QZRCXNX.js";
3
+ } from "./chunk-QHIE4YNG.js";
4
+ import "./chunk-N5AOPRAP.js";
5
5
  export {
6
6
  capnpc
7
7
  };
package/dist/index.cjs CHANGED
@@ -1,13 +1,13 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true});require('./chunk-AHJJINE5.cjs');
2
2
 
3
3
 
4
- var _chunk34UFVQ2Xcjs = require('./chunk-34UFVQ2X.cjs');
4
+ var _chunkM5QB7J6Hcjs = require('./chunk-M5QB7J6H.cjs');
5
5
 
6
6
 
7
- var _chunkXNXRTQEOcjs = require('./chunk-XNXRTQEO.cjs');
8
- require('./chunk-IJMQEVSJ.cjs');
7
+ var _chunkCFDWCYSUcjs = require('./chunk-CFDWCYSU.cjs');
8
+ require('./chunk-5MK6PQWW.cjs');
9
9
  require('./chunk-ORA4UQMU.cjs');
10
10
 
11
11
 
12
12
 
13
- exports.capnp = _chunkXNXRTQEOcjs.dist_exports; exports.capnpc = _chunk34UFVQ2Xcjs.capnpc;
13
+ exports.capnp = _chunkCFDWCYSUcjs.dist_exports; exports.capnpc = _chunkM5QB7J6Hcjs.capnpc;
package/dist/index.js CHANGED
@@ -1,11 +1,11 @@
1
1
  import "./chunk-TZHOQHWF.js";
2
2
  import {
3
3
  capnpc
4
- } from "./chunk-FGRQLKDC.js";
4
+ } from "./chunk-QHIE4YNG.js";
5
5
  import {
6
6
  dist_exports
7
- } from "./chunk-QVMMUK6E.js";
8
- import "./chunk-7QZRCXNX.js";
7
+ } from "./chunk-COUAFT7O.js";
8
+ import "./chunk-N5AOPRAP.js";
9
9
  import "./chunk-OULCUN6I.js";
10
10
  export {
11
11
  dist_exports as capnp,
package/dist/rpc.cjs CHANGED
@@ -2,17 +2,17 @@
2
2
 
3
3
 
4
4
 
5
- var _chunkXNXRTQEOcjs = require('./chunk-XNXRTQEO.cjs');
5
+ var _chunkCFDWCYSUcjs = require('./chunk-CFDWCYSU.cjs');
6
6
 
7
7
 
8
8
 
9
- var _chunkIJMQEVSJcjs = require('./chunk-IJMQEVSJ.cjs');
9
+ var _chunk5MK6PQWWcjs = require('./chunk-5MK6PQWW.cjs');
10
10
 
11
11
  // src/rpc.ts
12
12
  var _worker_threads = require('worker_threads');
13
13
  var CapnpRPC = (_class = class {constructor() { _class.prototype.__init.call(this);_class.prototype.__init2.call(this);_class.prototype.__init3.call(this); }
14
14
  static {
15
- _chunkIJMQEVSJcjs.__name.call(void 0, this, "CapnpRPC");
15
+ _chunk5MK6PQWWcjs.__name.call(void 0, this, "CapnpRPC");
16
16
  }
17
17
  __init() {this.acceptQueue = new Array()}
18
18
  __init2() {this.connections = {}}
@@ -26,13 +26,13 @@ var CapnpRPC = (_class = class {constructor() { _class.prototype.__init.call(thi
26
26
  connect(id = 0) {
27
27
  if (this.connections[id] !== void 0) return this.connections[id];
28
28
  const ch = new (0, _worker_threads.MessageChannel)();
29
- const conn = new (0, _chunkXNXRTQEOcjs.Conn)(new MessageChannelTransport(ch.port1));
29
+ const conn = new (0, _chunkCFDWCYSUcjs.Conn)(new MessageChannelTransport(ch.port1));
30
30
  const accept = this.acceptQueue.pop();
31
31
  this.connections[id] = conn;
32
32
  if (accept === void 0) {
33
33
  this.connectQueue.push(ch.port2);
34
34
  } else {
35
- accept.resolve(new (0, _chunkXNXRTQEOcjs.Conn)(new MessageChannelTransport(ch.port2)));
35
+ accept.resolve(new (0, _chunkCFDWCYSUcjs.Conn)(new MessageChannelTransport(ch.port2)));
36
36
  }
37
37
  return conn;
38
38
  }
@@ -45,9 +45,9 @@ var CapnpRPC = (_class = class {constructor() { _class.prototype.__init.call(thi
45
45
  async accept() {
46
46
  const port2 = this.connectQueue.pop();
47
47
  if (port2 !== void 0) {
48
- return Promise.resolve(new (0, _chunkXNXRTQEOcjs.Conn)(new MessageChannelTransport(port2)));
48
+ return Promise.resolve(new (0, _chunkCFDWCYSUcjs.Conn)(new MessageChannelTransport(port2)));
49
49
  }
50
- const deferred = new (0, _chunkXNXRTQEOcjs.Deferred)();
50
+ const deferred = new (0, _chunkCFDWCYSUcjs.Deferred)();
51
51
  this.acceptQueue.push(deferred);
52
52
  return deferred.promise;
53
53
  }
@@ -75,9 +75,9 @@ var CapnpRPC = (_class = class {constructor() { _class.prototype.__init.call(thi
75
75
  this.connections = {};
76
76
  }
77
77
  }, _class);
78
- var MessageChannelTransport = class extends _chunkXNXRTQEOcjs.DeferredTransport {
78
+ var MessageChannelTransport = class extends _chunkCFDWCYSUcjs.DeferredTransport {
79
79
  static {
80
- _chunkIJMQEVSJcjs.__name.call(void 0, this, "MessageChannelTransport");
80
+ _chunk5MK6PQWWcjs.__name.call(void 0, this, "MessageChannelTransport");
81
81
  }
82
82
 
83
83
  constructor(port) {
@@ -94,7 +94,7 @@ var MessageChannelTransport = class extends _chunkXNXRTQEOcjs.DeferredTransport
94
94
  }
95
95
 
96
96
  sendMessage(msg) {
97
- const m = new (0, _chunkIJMQEVSJcjs.Message)();
97
+ const m = new (0, _chunk5MK6PQWWcjs.Message)();
98
98
  m.setRoot(msg);
99
99
  const buf = m.toArrayBuffer();
100
100
  this.port.postMessage(buf, [
package/dist/rpc.js CHANGED
@@ -2,11 +2,11 @@ import {
2
2
  Conn,
3
3
  Deferred,
4
4
  DeferredTransport
5
- } from "./chunk-QVMMUK6E.js";
5
+ } from "./chunk-COUAFT7O.js";
6
6
  import {
7
7
  Message,
8
8
  __name
9
- } from "./chunk-7QZRCXNX.js";
9
+ } from "./chunk-N5AOPRAP.js";
10
10
 
11
11
  // src/rpc.ts
12
12
  import { MessageChannel } from "node:worker_threads";
package/dist/types.d.cts CHANGED
@@ -25,6 +25,7 @@ interface CapnpcCLIOptions {
25
25
  tsconfig: string;
26
26
  generateId?: boolean;
27
27
  standardImport?: boolean;
28
+ workspaceRoot: string;
28
29
  }
29
30
  type CapnpcOptions = Omit<CapnpcCLIOptions, "tsconfig"> & {
30
31
  tsconfig: ts.ParsedCommandLine;
package/dist/types.d.ts CHANGED
@@ -25,6 +25,7 @@ interface CapnpcCLIOptions {
25
25
  tsconfig: string;
26
26
  generateId?: boolean;
27
27
  standardImport?: boolean;
28
+ workspaceRoot: string;
28
29
  }
29
30
  type CapnpcOptions = Omit<CapnpcCLIOptions, "tsconfig"> & {
30
31
  tsconfig: ts.ParsedCommandLine;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@stryke/capnp",
3
- "version": "0.6.2",
3
+ "version": "0.6.3",
4
4
  "type": "module",
5
5
  "description": "A package to assist in running the Cap'n Proto compiler and creating Cap'n Proto serialization protocol schemas.",
6
6
  "repository": {