@typeberry/lib 0.0.1-be13f8e → 0.0.1-f0ab5f1

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 (3) hide show
  1. package/index.d.ts +6 -0
  2. package/index.js +6 -0
  3. package/package.json +1 -1
package/index.d.ts CHANGED
@@ -4939,6 +4939,8 @@ declare class ChainSpec extends WithDebug {
4939
4939
  readonly maxBlockGas: U64;
4940
4940
  /** `G_R`: The gas allocated to invoke a work-package’s Refine logic. */
4941
4941
  readonly maxRefineGas: U64;
4942
+ /** `L`: The maximum age in timeslots of the lookup anchor. */
4943
+ readonly maxLookupAnchorAge: U32;
4942
4944
 
4943
4945
  constructor(data: Omit<ChainSpec, "validatorsSuperMajority" | "thirdOfValidators" | "erasureCodedPieceSize">) {
4944
4946
  super();
@@ -4958,6 +4960,7 @@ declare class ChainSpec extends WithDebug {
4958
4960
  this.erasureCodedPieceSize = tryAsU32(EC_SEGMENT_SIZE / data.numberECPiecesPerSegment);
4959
4961
  this.maxBlockGas = data.maxBlockGas;
4960
4962
  this.maxRefineGas = data.maxRefineGas;
4963
+ this.maxLookupAnchorAge = data.maxLookupAnchorAge;
4961
4964
  }
4962
4965
  }
4963
4966
 
@@ -4976,6 +4979,8 @@ declare const tinyChainSpec = new ChainSpec({
4976
4979
  preimageExpungePeriod: tryAsU32(32),
4977
4980
  maxBlockGas: tryAsU64(20_000_000),
4978
4981
  maxRefineGas: tryAsU64(1_000_000_000),
4982
+ // https://github.com/davxy/jam-conformance/pull/47/files#diff-27e26142b3a96e407dab40d388b63d553f5d9cdb66dec58cd93e63dd434f9e45R260
4983
+ maxLookupAnchorAge: tryAsU32(24),
4979
4984
  });
4980
4985
 
4981
4986
  /**
@@ -4995,6 +5000,7 @@ declare const fullChainSpec = new ChainSpec({
4995
5000
  preimageExpungePeriod: tryAsU32(19_200),
4996
5001
  maxBlockGas: tryAsU64(3_500_000_000),
4997
5002
  maxRefineGas: tryAsU64(5_000_000_000),
5003
+ maxLookupAnchorAge: tryAsU32(14_400),
4998
5004
  });
4999
5005
 
5000
5006
  /**
package/index.js CHANGED
@@ -5641,6 +5641,8 @@ class ChainSpec extends WithDebug {
5641
5641
  maxBlockGas;
5642
5642
  /** `G_R`: The gas allocated to invoke a work-package’s Refine logic. */
5643
5643
  maxRefineGas;
5644
+ /** `L`: The maximum age in timeslots of the lookup anchor. */
5645
+ maxLookupAnchorAge;
5644
5646
  constructor(data) {
5645
5647
  super();
5646
5648
  this.validatorsCount = data.validatorsCount;
@@ -5658,6 +5660,7 @@ class ChainSpec extends WithDebug {
5658
5660
  this.erasureCodedPieceSize = tryAsU32(EC_SEGMENT_SIZE / data.numberECPiecesPerSegment);
5659
5661
  this.maxBlockGas = data.maxBlockGas;
5660
5662
  this.maxRefineGas = data.maxRefineGas;
5663
+ this.maxLookupAnchorAge = data.maxLookupAnchorAge;
5661
5664
  }
5662
5665
  }
5663
5666
  /** Set of values for "tiny" chain as defined in JAM test vectors. */
@@ -5675,6 +5678,8 @@ const tinyChainSpec = new ChainSpec({
5675
5678
  preimageExpungePeriod: tryAsU32(32),
5676
5679
  maxBlockGas: tryAsU64(20_000_000),
5677
5680
  maxRefineGas: tryAsU64(1_000_000_000),
5681
+ // https://github.com/davxy/jam-conformance/pull/47/files#diff-27e26142b3a96e407dab40d388b63d553f5d9cdb66dec58cd93e63dd434f9e45R260
5682
+ maxLookupAnchorAge: tryAsU32(24),
5678
5683
  });
5679
5684
  /**
5680
5685
  * Set of values for "full" chain as defined in JAM test vectors.
@@ -5693,6 +5698,7 @@ const fullChainSpec = new ChainSpec({
5693
5698
  preimageExpungePeriod: tryAsU32(19_200),
5694
5699
  maxBlockGas: tryAsU64(3_500_000_000),
5695
5700
  maxRefineGas: tryAsU64(5_000_000_000),
5701
+ maxLookupAnchorAge: tryAsU32(14_400),
5696
5702
  });
5697
5703
 
5698
5704
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@typeberry/lib",
3
- "version": "0.0.1-be13f8e",
3
+ "version": "0.0.1-f0ab5f1",
4
4
  "main": "index.js",
5
5
  "author": "Fluffy Labs",
6
6
  "license": "MPL-2.0"