@typeberry/lib 0.3.1-27dfdd9 → 0.4.0-13b653d

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 (4) hide show
  1. package/index.cjs +61 -136
  2. package/index.d.ts +10 -489
  3. package/index.js +61 -136
  4. package/package.json +1 -1
package/index.cjs CHANGED
@@ -78,8 +78,8 @@ class Compatibility {
78
78
  /**
79
79
  * Allows selecting different values for different Gray Paper versions from one record.
80
80
  *
81
- * @param fallback The default value to return if no value is found for the current.
82
- * @param record A record mapping versions to values, checking if the version is greater or equal to the current version.
81
+ * fallback The default value to return if no value is found for the current.
82
+ * versions A record mapping versions to values, checking if the version is greater or equal to the current version.
83
83
  * @returns The value for the current version, or the default value.
84
84
  */
85
85
  static selectIfGreaterOrEqual({ fallback, versions, }) {
@@ -239,7 +239,7 @@ const workspacePathFix = env.NODE_ENV === "development"
239
239
  : () => (p) => p;
240
240
 
241
241
  /**
242
- * @fileoverview `Opaque<Type, Token>` constructs a unique type which is a subset of Type with a
242
+ * `Opaque<Type, Token>` constructs a unique type which is a subset of Type with a
243
243
  * specified unique token Token. It means that base type cannot be assigned to unique type by accident.
244
244
  * Good examples of opaque types include:
245
245
  * - JWTs or other tokens - these are special kinds of string used for authorization purposes.
@@ -6712,6 +6712,8 @@ var index$m = /*#__PURE__*/Object.freeze({
6712
6712
  SEGMENT_BYTES: SEGMENT_BYTES,
6713
6713
  TicketsMarker: TicketsMarker,
6714
6714
  ValidatorKeys: ValidatorKeys,
6715
+ W_E: W_E,
6716
+ W_S: W_S,
6715
6717
  assurances: assurances,
6716
6718
  codecPerEpochBlock: codecPerEpochBlock,
6717
6719
  codecPerValidator: codecPerValidator,
@@ -7100,12 +7102,12 @@ const workRefineLoadFromJson = json.object({
7100
7102
  extrinsic_count: "number",
7101
7103
  extrinsic_size: "number",
7102
7104
  exports: "number",
7103
- }, ({ gas_used, imports, extrinsic_count, extrinsic_size, exports }) => WorkRefineLoad.create({
7105
+ }, ({ gas_used, imports, extrinsic_count, extrinsic_size, exports: exports$1 }) => WorkRefineLoad.create({
7104
7106
  gasUsed: tryAsServiceGas(gas_used),
7105
7107
  importedSegments: tryAsU32(imports),
7106
7108
  extrinsicCount: tryAsU32(extrinsic_count),
7107
7109
  extrinsicSize: tryAsU32(extrinsic_size),
7108
- exportedSegments: tryAsU32(exports),
7110
+ exportedSegments: tryAsU32(exports$1),
7109
7111
  }));
7110
7112
  const workResultFromJson = json.object({
7111
7113
  service_id: "number",
@@ -7267,7 +7269,7 @@ function parseBootnode(v) {
7267
7269
  if (name === "" || ip === "" || port === "") {
7268
7270
  throw new Error(`Invalid bootnode format, expected: <name>@<ip>:<port>, got: "${v}"`);
7269
7271
  }
7270
- const portNumber = Number.parseInt(port);
7272
+ const portNumber = Number.parseInt(port, 10);
7271
7273
  if (!isU16(portNumber)) {
7272
7274
  throw new Error(`Invalid port number: "${port}"`);
7273
7275
  }
@@ -8872,7 +8874,7 @@ class CoreStatistics {
8872
8874
  /** `i` */
8873
8875
  imports,
8874
8876
  /** `e` */
8875
- exports,
8877
+ exports$1,
8876
8878
  /** `z` */
8877
8879
  extrinsicSize,
8878
8880
  /** `x` */
@@ -8884,7 +8886,7 @@ class CoreStatistics {
8884
8886
  this.dataAvailabilityLoad = dataAvailabilityLoad;
8885
8887
  this.popularity = popularity;
8886
8888
  this.imports = imports;
8887
- this.exports = exports;
8889
+ this.exports = exports$1;
8888
8890
  this.extrinsicSize = extrinsicSize;
8889
8891
  this.extrinsicCount = extrinsicCount;
8890
8892
  this.bundleSize = bundleSize;
@@ -8977,7 +8979,7 @@ class ServiceStatistics {
8977
8979
  /** `i` */
8978
8980
  imports,
8979
8981
  /** `e` */
8980
- exports,
8982
+ exports$1,
8981
8983
  /** `z` */
8982
8984
  extrinsicSize,
8983
8985
  /** `x` */
@@ -8995,7 +8997,7 @@ class ServiceStatistics {
8995
8997
  this.refinementCount = refinementCount;
8996
8998
  this.refinementGasUsed = refinementGasUsed;
8997
8999
  this.imports = imports;
8998
- this.exports = exports;
9000
+ this.exports = exports$1;
8999
9001
  this.extrinsicSize = extrinsicSize;
9000
9002
  this.extrinsicCount = extrinsicCount;
9001
9003
  this.accumulateCount = accumulateCount;
@@ -10376,7 +10378,6 @@ class LeafNode {
10376
10378
  /**
10377
10379
  * Get the byte length of embedded value.
10378
10380
  *
10379
- * @remark
10380
10381
  * Note in case this node only contains hash this is going to be 0.
10381
10382
  */
10382
10383
  getValueLength() {
@@ -10387,7 +10388,6 @@ class LeafNode {
10387
10388
  /**
10388
10389
  * Returns the embedded value.
10389
10390
  *
10390
- * @remark
10391
10391
  * Note that this is going to be empty for a regular leaf node (i.e. containing a hash).
10392
10392
  */
10393
10393
  getValue() {
@@ -10397,7 +10397,6 @@ class LeafNode {
10397
10397
  /**
10398
10398
  * Returns contained value hash.
10399
10399
  *
10400
- * @remark
10401
10400
  * Note that for embedded value this is going to be full 0-padded 32 bytes.
10402
10401
  */
10403
10402
  getValueHash() {
@@ -16837,18 +16836,18 @@ async function instantiate$1(module, imports = {}) {
16837
16836
  },
16838
16837
  }, Object.assign(Object.create(globalThis), imports.env || {})),
16839
16838
  };
16840
- const { exports } = await WebAssembly.instantiate(module, adaptedImports);
16841
- const memory = exports.memory || imports.env.memory;
16839
+ const { exports: exports$1 } = await WebAssembly.instantiate(module, adaptedImports);
16840
+ const memory = exports$1.memory || imports.env.memory;
16842
16841
  const adaptedExports = Object.setPrototypeOf({
16843
16842
  getAssembly(p) {
16844
16843
  // assembly/api-internal/getAssembly(assembly/program/Program) => ~lib/string/String
16845
16844
  p = __lowerInternref(p) || __notnull();
16846
- return __liftString(exports.getAssembly(p) >>> 0);
16845
+ return __liftString(exports$1.getAssembly(p) >>> 0);
16847
16846
  },
16848
16847
  wrapAsProgram(bytecode) {
16849
16848
  // assembly/program-build/wrapAsProgram(~lib/typedarray/Uint8Array) => ~lib/typedarray/Uint8Array
16850
16849
  bytecode = __lowerTypedArray(Uint8Array, 10, 0, bytecode) || __notnull();
16851
- return __liftTypedArray(Uint8Array, exports.wrapAsProgram(bytecode) >>> 0);
16850
+ return __liftTypedArray(Uint8Array, exports$1.wrapAsProgram(bytecode) >>> 0);
16852
16851
  },
16853
16852
  resetJAM(program, pc, initialGas, args, hasMetadata) {
16854
16853
  // assembly/api-debugger/resetJAM(~lib/array/Array<u8>, f64, i64, ~lib/array/Array<u8>, bool?) => void
@@ -16857,8 +16856,8 @@ async function instantiate$1(module, imports = {}) {
16857
16856
  args = __lowerArray(__setU8, 6, 0, args) || __notnull();
16858
16857
  hasMetadata = hasMetadata ? 1 : 0;
16859
16858
  try {
16860
- exports.__setArgumentsLength(arguments.length);
16861
- exports.resetJAM(program, pc, initialGas, args, hasMetadata);
16859
+ exports$1.__setArgumentsLength(arguments.length);
16860
+ exports$1.resetJAM(program, pc, initialGas, args, hasMetadata);
16862
16861
  } finally {
16863
16862
  __release(program);
16864
16863
  }
@@ -16870,8 +16869,8 @@ async function instantiate$1(module, imports = {}) {
16870
16869
  initialGas = initialGas || 0n;
16871
16870
  hasMetadata = hasMetadata ? 1 : 0;
16872
16871
  try {
16873
- exports.__setArgumentsLength(arguments.length);
16874
- exports.resetGeneric(program, flatRegisters, initialGas, hasMetadata);
16872
+ exports$1.__setArgumentsLength(arguments.length);
16873
+ exports$1.resetGeneric(program, flatRegisters, initialGas, hasMetadata);
16875
16874
  } finally {
16876
16875
  __release(program);
16877
16876
  }
@@ -16885,8 +16884,8 @@ async function instantiate$1(module, imports = {}) {
16885
16884
  initialGas = initialGas || 0n;
16886
16885
  hasMetadata = hasMetadata ? 1 : 0;
16887
16886
  try {
16888
- exports.__setArgumentsLength(arguments.length);
16889
- exports.resetGenericWithMemory(program, flatRegisters, pageMap, chunks, initialGas, hasMetadata);
16887
+ exports$1.__setArgumentsLength(arguments.length);
16888
+ exports$1.resetGenericWithMemory(program, flatRegisters, pageMap, chunks, initialGas, hasMetadata);
16890
16889
  } finally {
16891
16890
  __release(program);
16892
16891
  __release(flatRegisters);
@@ -16895,68 +16894,68 @@ async function instantiate$1(module, imports = {}) {
16895
16894
  },
16896
16895
  nextStep() {
16897
16896
  // assembly/api-debugger/nextStep() => bool
16898
- return exports.nextStep() != 0;
16897
+ return exports$1.nextStep() != 0;
16899
16898
  },
16900
16899
  nSteps(steps) {
16901
16900
  // assembly/api-debugger/nSteps(u32) => bool
16902
- return exports.nSteps(steps) != 0;
16901
+ return exports$1.nSteps(steps) != 0;
16903
16902
  },
16904
16903
  getProgramCounter() {
16905
16904
  // assembly/api-debugger/getProgramCounter() => u32
16906
- return exports.getProgramCounter() >>> 0;
16905
+ return exports$1.getProgramCounter() >>> 0;
16907
16906
  },
16908
16907
  getExitArg() {
16909
16908
  // assembly/api-debugger/getExitArg() => u32
16910
- return exports.getExitArg() >>> 0;
16909
+ return exports$1.getExitArg() >>> 0;
16911
16910
  },
16912
16911
  setGasLeft(gas) {
16913
16912
  // assembly/api-debugger/setGasLeft(i64) => void
16914
16913
  gas = gas || 0n;
16915
- exports.setGasLeft(gas);
16914
+ exports$1.setGasLeft(gas);
16916
16915
  },
16917
16916
  getRegisters() {
16918
16917
  // assembly/api-debugger/getRegisters() => ~lib/typedarray/Uint8Array
16919
- return __liftTypedArray(Uint8Array, exports.getRegisters() >>> 0);
16918
+ return __liftTypedArray(Uint8Array, exports$1.getRegisters() >>> 0);
16920
16919
  },
16921
16920
  setRegisters(flatRegisters) {
16922
16921
  // assembly/api-debugger/setRegisters(~lib/array/Array<u8>) => void
16923
16922
  flatRegisters = __lowerArray(__setU8, 6, 0, flatRegisters) || __notnull();
16924
- exports.setRegisters(flatRegisters);
16923
+ exports$1.setRegisters(flatRegisters);
16925
16924
  },
16926
16925
  getPageDump(index) {
16927
16926
  // assembly/api-debugger/getPageDump(u32) => ~lib/typedarray/Uint8Array
16928
- return __liftTypedArray(Uint8Array, exports.getPageDump(index) >>> 0);
16927
+ return __liftTypedArray(Uint8Array, exports$1.getPageDump(index) >>> 0);
16929
16928
  },
16930
16929
  getMemory(address, length) {
16931
16930
  // assembly/api-debugger/getMemory(u32, u32) => ~lib/typedarray/Uint8Array | null
16932
- return __liftTypedArray(Uint8Array, exports.getMemory(address, length) >>> 0);
16931
+ return __liftTypedArray(Uint8Array, exports$1.getMemory(address, length) >>> 0);
16933
16932
  },
16934
16933
  setMemory(address, data) {
16935
16934
  // assembly/api-debugger/setMemory(u32, ~lib/typedarray/Uint8Array) => bool
16936
16935
  data = __lowerTypedArray(Uint8Array, 10, 0, data) || __notnull();
16937
- return exports.setMemory(address, data) != 0;
16936
+ return exports$1.setMemory(address, data) != 0;
16938
16937
  },
16939
16938
  InputKind: (values => (
16940
16939
  // assembly/api-utils/InputKind
16941
- values[values.Generic = exports["InputKind.Generic"].valueOf()] = "Generic",
16942
- values[values.SPI = exports["InputKind.SPI"].valueOf()] = "SPI",
16940
+ values[values.Generic = exports$1["InputKind.Generic"].valueOf()] = "Generic",
16941
+ values[values.SPI = exports$1["InputKind.SPI"].valueOf()] = "SPI",
16943
16942
  values
16944
16943
  ))({}),
16945
16944
  HasMetadata: (values => (
16946
16945
  // assembly/api-utils/HasMetadata
16947
- values[values.Yes = exports["HasMetadata.Yes"].valueOf()] = "Yes",
16948
- values[values.No = exports["HasMetadata.No"].valueOf()] = "No",
16946
+ values[values.Yes = exports$1["HasMetadata.Yes"].valueOf()] = "Yes",
16947
+ values[values.No = exports$1["HasMetadata.No"].valueOf()] = "No",
16949
16948
  values
16950
16949
  ))({}),
16951
16950
  getGasCosts(input, kind, withMetadata) {
16952
16951
  // assembly/api-utils/getGasCosts(~lib/array/Array<u8>, i32, i32) => ~lib/array/Array<assembly/gas-costs/BlockGasCost>
16953
16952
  input = __lowerArray(__setU8, 6, 0, input) || __notnull();
16954
- return __liftArray(pointer => __liftRecord50(__getU32(pointer)), 2, exports.getGasCosts(input, kind, withMetadata) >>> 0);
16953
+ return __liftArray(pointer => __liftRecord50(__getU32(pointer)), 2, exports$1.getGasCosts(input, kind, withMetadata) >>> 0);
16955
16954
  },
16956
16955
  disassemble(input, kind, withMetadata) {
16957
16956
  // assembly/api-utils/disassemble(~lib/array/Array<u8>, i32, i32) => ~lib/string/String
16958
16957
  input = __lowerArray(__setU8, 6, 0, input) || __notnull();
16959
- return __liftString(exports.disassemble(input, kind, withMetadata) >>> 0);
16958
+ return __liftString(exports$1.disassemble(input, kind, withMetadata) >>> 0);
16960
16959
  },
16961
16960
  prepareProgram(kind, hasMetadata, program, initialRegisters, initialPageMap, initialMemory, args) {
16962
16961
  // assembly/api-utils/prepareProgram(i32, i32, ~lib/array/Array<u8>, ~lib/array/Array<u64>, ~lib/array/Array<assembly/api-internal/InitialPage>, ~lib/array/Array<assembly/api-internal/InitialChunk>, ~lib/array/Array<u8>) => assembly/spi/StandardProgram
@@ -16966,7 +16965,7 @@ async function instantiate$1(module, imports = {}) {
16966
16965
  initialMemory = __retain(__lowerArray((pointer, value) => { __setU32(pointer, __lowerRecord48(value) || __notnull()); }, 49, 2, initialMemory) || __notnull());
16967
16966
  args = __lowerArray(__setU8, 6, 0, args) || __notnull();
16968
16967
  try {
16969
- return __liftInternref(exports.prepareProgram(kind, hasMetadata, program, initialRegisters, initialPageMap, initialMemory, args) >>> 0);
16968
+ return __liftInternref(exports$1.prepareProgram(kind, hasMetadata, program, initialRegisters, initialPageMap, initialMemory, args) >>> 0);
16970
16969
  } finally {
16971
16970
  __release(program);
16972
16971
  __release(initialRegisters);
@@ -16980,10 +16979,10 @@ async function instantiate$1(module, imports = {}) {
16980
16979
  initialGas = initialGas || 0n;
16981
16980
  logs = logs ? 1 : 0;
16982
16981
  useSbrkGas = useSbrkGas ? 1 : 0;
16983
- exports.__setArgumentsLength(arguments.length);
16984
- return __liftRecord55(exports.runProgram(program, initialGas, programCounter, logs, useSbrkGas) >>> 0);
16982
+ exports$1.__setArgumentsLength(arguments.length);
16983
+ return __liftRecord55(exports$1.runProgram(program, initialGas, programCounter, logs, useSbrkGas) >>> 0);
16985
16984
  },
16986
- }, exports);
16985
+ }, exports$1);
16987
16986
  function __liftRecord50(pointer) {
16988
16987
  // assembly/gas-costs/BlockGasCost
16989
16988
  // Hint: Opt-out from lifting as a record by providing an empty constructor
@@ -16997,21 +16996,21 @@ async function instantiate$1(module, imports = {}) {
16997
16996
  // assembly/api-internal/InitialPage
16998
16997
  // Hint: Opt-out from lowering as a record by providing an empty constructor
16999
16998
  if (value == null) return 0;
17000
- const pointer = exports.__pin(exports.__new(12, 46));
16999
+ const pointer = exports$1.__pin(exports$1.__new(12, 46));
17001
17000
  __setU32(pointer + 0, value.address);
17002
17001
  __setU32(pointer + 4, value.length);
17003
17002
  __setU32(pointer + 8, value.access);
17004
- exports.__unpin(pointer);
17003
+ exports$1.__unpin(pointer);
17005
17004
  return pointer;
17006
17005
  }
17007
17006
  function __lowerRecord48(value) {
17008
17007
  // assembly/api-internal/InitialChunk
17009
17008
  // Hint: Opt-out from lowering as a record by providing an empty constructor
17010
17009
  if (value == null) return 0;
17011
- const pointer = exports.__pin(exports.__new(8, 48));
17010
+ const pointer = exports$1.__pin(exports$1.__new(8, 48));
17012
17011
  __setU32(pointer + 0, value.address);
17013
17012
  __setU32(pointer + 4, __lowerArray(__setU8, 6, 0, value.data) || __notnull());
17014
- exports.__unpin(pointer);
17013
+ exports$1.__unpin(pointer);
17015
17014
  return pointer;
17016
17015
  }
17017
17016
  function __liftRecord48(pointer) {
@@ -17060,15 +17059,15 @@ async function instantiate$1(module, imports = {}) {
17060
17059
  if (values == null) return 0;
17061
17060
  const
17062
17061
  length = values.length,
17063
- buffer = exports.__pin(exports.__new(length << align, 1)) >>> 0,
17064
- header = exports.__pin(exports.__new(16, id)) >>> 0;
17062
+ buffer = exports$1.__pin(exports$1.__new(length << align, 1)) >>> 0,
17063
+ header = exports$1.__pin(exports$1.__new(16, id)) >>> 0;
17065
17064
  __setU32(header + 0, buffer);
17066
17065
  __dataview.setUint32(header + 4, buffer, true);
17067
17066
  __dataview.setUint32(header + 8, length << align, true);
17068
17067
  __dataview.setUint32(header + 12, length, true);
17069
17068
  for (let i = 0; i < length; ++i) lowerElement(buffer + (i << align >>> 0), values[i]);
17070
- exports.__unpin(buffer);
17071
- exports.__unpin(header);
17069
+ exports$1.__unpin(buffer);
17070
+ exports$1.__unpin(header);
17072
17071
  return header;
17073
17072
  }
17074
17073
  function __liftTypedArray(constructor, pointer) {
@@ -17083,13 +17082,13 @@ async function instantiate$1(module, imports = {}) {
17083
17082
  if (values == null) return 0;
17084
17083
  const
17085
17084
  length = values.length,
17086
- buffer = exports.__pin(exports.__new(length << align, 1)) >>> 0,
17087
- header = exports.__new(12, id) >>> 0;
17085
+ buffer = exports$1.__pin(exports$1.__new(length << align, 1)) >>> 0,
17086
+ header = exports$1.__new(12, id) >>> 0;
17088
17087
  __setU32(header + 0, buffer);
17089
17088
  __dataview.setUint32(header + 4, buffer, true);
17090
17089
  __dataview.setUint32(header + 8, length << align, true);
17091
17090
  new constructor(memory.buffer, buffer, length).set(values);
17092
- exports.__unpin(buffer);
17091
+ exports$1.__unpin(buffer);
17093
17092
  return header;
17094
17093
  }
17095
17094
  class Internref extends Number {}
@@ -17110,14 +17109,14 @@ async function instantiate$1(module, imports = {}) {
17110
17109
  if (pointer) {
17111
17110
  const refcount = refcounts.get(pointer);
17112
17111
  if (refcount) refcounts.set(pointer, refcount + 1);
17113
- else refcounts.set(exports.__pin(pointer), 1);
17112
+ else refcounts.set(exports$1.__pin(pointer), 1);
17114
17113
  }
17115
17114
  return pointer;
17116
17115
  }
17117
17116
  function __release(pointer) {
17118
17117
  if (pointer) {
17119
17118
  const refcount = refcounts.get(pointer);
17120
- if (refcount === 1) exports.__unpin(pointer), refcounts.delete(pointer);
17119
+ if (refcount === 1) exports$1.__unpin(pointer), refcounts.delete(pointer);
17121
17120
  else if (refcount) refcounts.set(pointer, refcount - 1);
17122
17121
  else throw Error(`invalid refcount '${refcount}' for reference '${pointer}'`);
17123
17122
  }
@@ -17719,79 +17718,7 @@ class DebuggerAdapter {
17719
17718
 
17720
17719
  var index$4 = /*#__PURE__*/Object.freeze({
17721
17720
  __proto__: null,
17722
- AccumulationStateUpdate: AccumulationStateUpdate,
17723
- ArgsDecoder: ArgsDecoder,
17724
- get ArgumentType () { return ArgumentType; },
17725
- BasicBlocks: BasicBlocks,
17726
- CURRENT_SERVICE_ID: CURRENT_SERVICE_ID,
17727
- get EjectError () { return EjectError; },
17728
- ExtendedWitdthImmediateDecoder: ExtendedWitdthImmediateDecoder,
17729
- get ForgetPreimageError () { return ForgetPreimageError; },
17730
- HostCallMemory: HostCallMemory,
17731
- HostCallRegisters: HostCallRegisters,
17732
- HostCallResult: HostCallResult,
17733
- ImmediateDecoder: ImmediateDecoder,
17734
- InsufficientFundsError: InsufficientFundsError,
17735
- MachineInstance: MachineInstance,
17736
- Mask: Mask,
17737
- get MemoryOperation () { return MemoryOperation; },
17738
- MemorySegment: MemorySegment,
17739
- NO_OF_REGISTERS: NO_OF_REGISTERS$1,
17740
- get NewServiceError () { return NewServiceError; },
17741
- NibblesDecoder: NibblesDecoder,
17742
- NoMachineError: NoMachineError,
17743
- OK: OK,
17744
- get PagesError () { return PagesError; },
17745
- PartiallyUpdatedState: PartiallyUpdatedState,
17746
- get PeekPokeError () { return PeekPokeError; },
17747
- PendingTransfer: PendingTransfer,
17748
- get PreimageStatusKind () { return PreimageStatusKind; },
17749
- Program: Program,
17750
- ProgramDecoder: ProgramDecoder,
17751
- get ProvidePreimageError () { return ProvidePreimageError; },
17752
- Pvm: DebuggerAdapter,
17753
- Registers: Registers,
17754
- get RequestPreimageError () { return RequestPreimageError; },
17755
- Result: Result$1,
17756
- SERVICE_ID_BYTES: SERVICE_ID_BYTES,
17757
- SegmentExportError: SegmentExportError,
17758
- SpiMemory: SpiMemory,
17759
- SpiProgram: SpiProgram,
17760
- TRANSFER_MEMO_BYTES: TRANSFER_MEMO_BYTES,
17761
- get TransferError () { return TransferError; },
17762
- UnprivilegedError: UnprivilegedError,
17763
- get UpdatePrivilegesError () { return UpdatePrivilegesError; },
17764
- WithDebug: WithDebug,
17765
- get ZeroVoidError () { return ZeroVoidError; },
17766
- asOpaqueType: asOpaqueType,
17767
- assertEmpty: assertEmpty,
17768
- assertNever: assertNever,
17769
- block: index$m,
17770
- bytes: index$t,
17771
- check: check,
17772
- clampU64ToU32: clampU64ToU32,
17773
- createResults: createResults,
17774
- decodeStandardProgram: decodeStandardProgram,
17775
- emptyRegistersBuffer: emptyRegistersBuffer,
17776
- extractCodeAndMetadata: extractCodeAndMetadata,
17777
- getServiceId: getServiceId,
17778
- getServiceIdOrCurrent: getServiceIdOrCurrent,
17779
- hash: index$p,
17780
- hostCallInfoAccount: codecServiceAccountInfoWithThresholdBalance,
17781
- inspect: inspect,
17782
- instructionArgumentTypeMap: instructionArgumentTypeMap,
17783
- interpreter: index$8,
17784
- isBrowser: isBrowser,
17785
- lazyInspect: lazyInspect,
17786
- measure: measure,
17787
- numbers: index$s,
17788
- resultToString: resultToString,
17789
- seeThrough: seeThrough,
17790
- slotsToPreimageStatus: slotsToPreimageStatus,
17791
- toMemoryOperation: toMemoryOperation,
17792
- tryAsMachineId: tryAsMachineId,
17793
- tryAsProgramCounter: tryAsProgramCounter,
17794
- writeServiceIdAsLeBytes: writeServiceIdAsLeBytes
17721
+ Pvm: DebuggerAdapter
17795
17722
  });
17796
17723
 
17797
17724
  const ENTROPY_BYTES = 32;
@@ -18065,12 +17992,12 @@ class JsonCoreStatistics {
18065
17992
  extrinsic_count: "number",
18066
17993
  bundle_size: "number",
18067
17994
  gas_used: json.fromBigInt(tryAsServiceGas),
18068
- }, ({ da_load, popularity, imports, exports, extrinsic_size, extrinsic_count, bundle_size, gas_used }) => {
17995
+ }, ({ da_load, popularity, imports, exports: exports$1, extrinsic_size, extrinsic_count, bundle_size, gas_used }) => {
18069
17996
  return CoreStatistics.create({
18070
17997
  dataAvailabilityLoad: da_load,
18071
17998
  popularity,
18072
17999
  imports,
18073
- exports,
18000
+ exports: exports$1,
18074
18001
  extrinsicSize: extrinsic_size,
18075
18002
  extrinsicCount: extrinsic_count,
18076
18003
  bundleSize: bundle_size,
@@ -18104,14 +18031,14 @@ class JsonServiceStatistics {
18104
18031
  on_transfers_gas_used: json.fromBigInt(tryAsServiceGas),
18105
18032
  }
18106
18033
  : {}),
18107
- }, ({ provided_count, provided_size, refinement_count, refinement_gas_used, imports, exports, extrinsic_size, extrinsic_count, accumulate_count, accumulate_gas_used, on_transfers_count, on_transfers_gas_used, }) => {
18034
+ }, ({ provided_count, provided_size, refinement_count, refinement_gas_used, imports, exports: exports$1, extrinsic_size, extrinsic_count, accumulate_count, accumulate_gas_used, on_transfers_count, on_transfers_gas_used, }) => {
18108
18035
  return ServiceStatistics.create({
18109
18036
  providedCount: provided_count,
18110
18037
  providedSize: provided_size,
18111
18038
  refinementCount: refinement_count,
18112
18039
  refinementGasUsed: refinement_gas_used,
18113
18040
  imports,
18114
- exports,
18041
+ exports: exports$1,
18115
18042
  extrinsicSize: extrinsic_size,
18116
18043
  extrinsicCount: extrinsic_count,
18117
18044
  accumulateCount: accumulate_count,
@@ -18319,11 +18246,9 @@ var index$1 = /*#__PURE__*/Object.freeze({
18319
18246
 
18320
18247
  /** Helper function to create most used hashes in the block */
18321
18248
  class TransitionHasher {
18322
- context;
18323
18249
  keccakHasher;
18324
18250
  blake2b;
18325
- constructor(context, keccakHasher, blake2b) {
18326
- this.context = context;
18251
+ constructor(keccakHasher, blake2b) {
18327
18252
  this.keccakHasher = keccakHasher;
18328
18253
  this.blake2b = blake2b;
18329
18254
  }