@polkadot/types-known 8.9.2-2 → 8.9.2-22-x

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.
@@ -11,6 +11,6 @@ const packageInfo = {
11
11
  name: '@polkadot/types-known',
12
12
  path: typeof __dirname === 'string' ? __dirname : 'auto',
13
13
  type: 'cjs',
14
- version: '8.9.2-2'
14
+ version: '8.9.2-22-x'
15
15
  };
16
16
  exports.packageInfo = packageInfo;
@@ -37,7 +37,11 @@ function checkOrder(network, versions) {
37
37
  const prev = versions[index - 1];
38
38
  return index === 0 ? false : curr[0] <= prev[0] || curr[1] <= prev[1];
39
39
  });
40
- (0, _util.assert)(!ooo.length, () => `${network}: Mismatched upgrade ordering: ${(0, _util.stringify)(ooo)}`);
40
+
41
+ if (ooo.length) {
42
+ throw new Error(`${network}: Mismatched upgrade ordering: ${(0, _util.stringify)(ooo)}`);
43
+ }
44
+
41
45
  return versions;
42
46
  }
43
47
  /** @internal */
@@ -46,7 +50,11 @@ function checkOrder(network, versions) {
46
50
  function mapRaw(_ref) {
47
51
  let [network, versions] = _ref;
48
52
  const chain = _networks.selectableNetworks.find(n => n.network === network) || NET_EXTRA[network];
49
- (0, _util.assert)(chain, () => `Unable to find info for chain ${network}`);
53
+
54
+ if (!chain) {
55
+ throw new Error(`Unable to find info for chain ${network}`);
56
+ }
57
+
50
58
  return {
51
59
  genesisHash: (0, _util.hexToU8a)(chain.genesisHash[0]),
52
60
  network,
@@ -6,6 +6,6 @@ Object.defineProperty(exports, "__esModule", {
6
6
  exports.default = void 0;
7
7
  // Copyright 2017-2022 @polkadot/types-known authors & contributors
8
8
  // SPDX-License-Identifier: Apache-2.0
9
- const upgrades = [[214356, 4], [392764, 7], [409740, 8], [809976, 20], [877581, 24], [879238, 25], [889472, 26], [902937, 27], [932751, 28], [991142, 29], [1030162, 31], [1119657, 32], [1199282, 33], [1342534, 34], [1392263, 35], [1431703, 36], [1433369, 37], [1490972, 41], [2087397, 43], [2316688, 44], [2549864, 45], [3925782, 46], [3925843, 47], [4207800, 48], [4627944, 49], [5124076, 50], [5478664, 900], [5482450, 9000], [5584305, 9010], [5784566, 9030], [5879822, 9031], [5896856, 9032], [5897316, 9033], [6117927, 9050], [6210274, 9070], [6379314, 9080], [6979141, 9090], [7568453, 9100], [7766394, 9111], [7911691, 9120], [7968866, 9121], [7982889, 9122], [8514322, 9130], [9091726, 9140], [9091774, 9150], [9406726, 9160], [9921066, 9170], [10007115, 9180], [10480973, 9190], [10578091, 9200], [10678509, 9210], [10811001, 9220], [11096116, 9230]];
9
+ const upgrades = [[214356, 4], [392764, 7], [409740, 8], [809976, 20], [877581, 24], [879238, 25], [889472, 26], [902937, 27], [932751, 28], [991142, 29], [1030162, 31], [1119657, 32], [1199282, 33], [1342534, 34], [1392263, 35], [1431703, 36], [1433369, 37], [1490972, 41], [2087397, 43], [2316688, 44], [2549864, 45], [3925782, 46], [3925843, 47], [4207800, 48], [4627944, 49], [5124076, 50], [5478664, 900], [5482450, 9000], [5584305, 9010], [5784566, 9030], [5879822, 9031], [5896856, 9032], [5897316, 9033], [6117927, 9050], [6210274, 9070], [6379314, 9080], [6979141, 9090], [7568453, 9100], [7766394, 9111], [7911691, 9120], [7968866, 9121], [7982889, 9122], [8514322, 9130], [9091726, 9140], [9091774, 9150], [9406726, 9160], [9921066, 9170], [10007115, 9180], [10480973, 9190], [10578091, 9200], [10678509, 9210], [10811001, 9220], [11096116, 9230], [11409279, 9250]];
10
10
  var _default = upgrades;
11
11
  exports.default = _default;
package/mod.d.ts ADDED
@@ -0,0 +1 @@
1
+ export * from './index';
package/mod.ts ADDED
@@ -0,0 +1,4 @@
1
+ // Copyright 2017-2022 @polkadot/types-known authors & contributors
2
+ // SPDX-License-Identifier: Apache-2.0
3
+
4
+ export * from './index';
package/package.json CHANGED
@@ -20,7 +20,7 @@
20
20
  "./cjs/detectPackage.js"
21
21
  ],
22
22
  "type": "module",
23
- "version": "8.9.2-2",
23
+ "version": "8.9.2-22-x",
24
24
  "main": "./cjs/index.js",
25
25
  "module": "./index.js",
26
26
  "types": "./index.d.ts",
@@ -52,6 +52,8 @@
52
52
  "require": "./cjs/detectPackage.js",
53
53
  "default": "./detectPackage.js"
54
54
  },
55
+ "./mod.d.ts": "./mod.d.ts",
56
+ "./mod.ts": "./mod.ts",
55
57
  "./package.json": "./package.json",
56
58
  "./packageInfo.js": {
57
59
  "types": "./packageInfo.d.ts",
@@ -146,10 +148,10 @@
146
148
  },
147
149
  "dependencies": {
148
150
  "@babel/runtime": "^7.18.3",
149
- "@polkadot/networks": "^9.5.1",
150
- "@polkadot/types": "8.9.2-2",
151
- "@polkadot/types-codec": "8.9.2-2",
152
- "@polkadot/types-create": "8.9.2-2",
153
- "@polkadot/util": "^9.5.1"
151
+ "@polkadot/networks": "^9.6.2",
152
+ "@polkadot/types": "8.9.2-22-x",
153
+ "@polkadot/types-codec": "8.9.2-22-x",
154
+ "@polkadot/types-create": "8.9.2-22-x",
155
+ "@polkadot/util": "^9.6.2"
154
156
  }
155
157
  }
package/packageInfo.js CHANGED
@@ -5,5 +5,5 @@ export const packageInfo = {
5
5
  name: '@polkadot/types-known',
6
6
  path: (import.meta && import.meta.url) ? new URL(import.meta.url).pathname.substring(0, new URL(import.meta.url).pathname.lastIndexOf('/') + 1) : 'auto',
7
7
  type: 'esm',
8
- version: '8.9.2-2'
8
+ version: '8.9.2-22-x'
9
9
  };
package/upgrades/index.js CHANGED
@@ -1,7 +1,7 @@
1
1
  // Copyright 2017-2022 @polkadot/types-known authors & contributors
2
2
  // SPDX-License-Identifier: Apache-2.0
3
3
  import { selectableNetworks } from '@polkadot/networks';
4
- import { assert, BN, hexToU8a, stringify } from '@polkadot/util';
4
+ import { BN, hexToU8a, stringify } from '@polkadot/util';
5
5
  import kusama from "./kusama.js";
6
6
  import polkadot from "./polkadot.js";
7
7
  import westend from "./westend.js";
@@ -23,7 +23,11 @@ function checkOrder(network, versions) {
23
23
  const prev = versions[index - 1];
24
24
  return index === 0 ? false : curr[0] <= prev[0] || curr[1] <= prev[1];
25
25
  });
26
- assert(!ooo.length, () => `${network}: Mismatched upgrade ordering: ${stringify(ooo)}`);
26
+
27
+ if (ooo.length) {
28
+ throw new Error(`${network}: Mismatched upgrade ordering: ${stringify(ooo)}`);
29
+ }
30
+
27
31
  return versions;
28
32
  }
29
33
  /** @internal */
@@ -31,7 +35,11 @@ function checkOrder(network, versions) {
31
35
 
32
36
  function mapRaw([network, versions]) {
33
37
  const chain = selectableNetworks.find(n => n.network === network) || NET_EXTRA[network];
34
- assert(chain, () => `Unable to find info for chain ${network}`);
38
+
39
+ if (!chain) {
40
+ throw new Error(`Unable to find info for chain ${network}`);
41
+ }
42
+
35
43
  return {
36
44
  genesisHash: hexToU8a(chain.genesisHash[0]),
37
45
  network,
@@ -1,4 +1,4 @@
1
1
  // Copyright 2017-2022 @polkadot/types-known authors & contributors
2
2
  // SPDX-License-Identifier: Apache-2.0
3
- const upgrades = [[214356, 4], [392764, 7], [409740, 8], [809976, 20], [877581, 24], [879238, 25], [889472, 26], [902937, 27], [932751, 28], [991142, 29], [1030162, 31], [1119657, 32], [1199282, 33], [1342534, 34], [1392263, 35], [1431703, 36], [1433369, 37], [1490972, 41], [2087397, 43], [2316688, 44], [2549864, 45], [3925782, 46], [3925843, 47], [4207800, 48], [4627944, 49], [5124076, 50], [5478664, 900], [5482450, 9000], [5584305, 9010], [5784566, 9030], [5879822, 9031], [5896856, 9032], [5897316, 9033], [6117927, 9050], [6210274, 9070], [6379314, 9080], [6979141, 9090], [7568453, 9100], [7766394, 9111], [7911691, 9120], [7968866, 9121], [7982889, 9122], [8514322, 9130], [9091726, 9140], [9091774, 9150], [9406726, 9160], [9921066, 9170], [10007115, 9180], [10480973, 9190], [10578091, 9200], [10678509, 9210], [10811001, 9220], [11096116, 9230]];
3
+ const upgrades = [[214356, 4], [392764, 7], [409740, 8], [809976, 20], [877581, 24], [879238, 25], [889472, 26], [902937, 27], [932751, 28], [991142, 29], [1030162, 31], [1119657, 32], [1199282, 33], [1342534, 34], [1392263, 35], [1431703, 36], [1433369, 37], [1490972, 41], [2087397, 43], [2316688, 44], [2549864, 45], [3925782, 46], [3925843, 47], [4207800, 48], [4627944, 49], [5124076, 50], [5478664, 900], [5482450, 9000], [5584305, 9010], [5784566, 9030], [5879822, 9031], [5896856, 9032], [5897316, 9033], [6117927, 9050], [6210274, 9070], [6379314, 9080], [6979141, 9090], [7568453, 9100], [7766394, 9111], [7911691, 9120], [7968866, 9121], [7982889, 9122], [8514322, 9130], [9091726, 9140], [9091774, 9150], [9406726, 9160], [9921066, 9170], [10007115, 9180], [10480973, 9190], [10578091, 9200], [10678509, 9210], [10811001, 9220], [11096116, 9230], [11409279, 9250]];
4
4
  export default upgrades;