@acala-network/chopsticks 0.12.2 → 0.13.0-1

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.
@@ -7,9 +7,9 @@ export declare const setupContext: (argv: Config, overrideParent?: boolean) => P
7
7
  fetchStorageWorker: {
8
8
  worker: import("comlink").Remote<{
9
9
  startFetch: (options: {
10
- block?: string | number | null | undefined;
11
- endpoint?: string | string[] | undefined;
12
- dbPath?: string | undefined;
10
+ block?: number | string | null;
11
+ endpoint?: string | string[];
12
+ dbPath?: string;
13
13
  config: import("./utils/fetch-storages.js").FetchStorageConfig;
14
14
  }) => Promise<void>;
15
15
  }>;
@@ -1,4 +1,4 @@
1
1
  import _ from 'lodash';
2
2
  export { defaultLogger, truncate } from '@acala-network/chopsticks-core';
3
3
  export declare const spinnerFrames: string[];
4
- export declare const apiFetching: _.DebouncedFunc<() => void>;
4
+ export declare const apiFetching: _.DebouncedFuncLeading<() => void>;
@@ -1 +1 @@
1
- {"type": "commonjs"}
1
+ { "type": "commonjs" }
@@ -1,4 +1,3 @@
1
- /// <reference types="node" resolution-mode="require"/>
2
1
  import { Block, Blockchain, RuntimeVersion } from '@acala-network/chopsticks-core';
3
2
  import { HexString } from '@polkadot/util/types';
4
3
  import { Step } from './types.js';
@@ -1,4 +1,5 @@
1
1
  import { BuildBlockMode } from '@acala-network/chopsticks-core';
2
+ import { Options } from 'yargs';
2
3
  import { ZodNativeEnum, ZodRawShape, ZodTypeAny, z } from 'zod';
3
4
  export declare const zHex: z.ZodType<`0x${string}`, z.ZodTypeDef, `0x${string}`>;
4
5
  export declare const zHash: z.ZodIntersection<z.ZodString, z.ZodType<`0x${string}`, z.ZodTypeDef, `0x${string}`>>;
@@ -147,11 +148,6 @@ export declare const configSchema: z.ZodObject<{
147
148
  }>;
148
149
  export type Config = z.infer<typeof configSchema>;
149
150
  export declare const getYargsOptions: (zodShape: ZodRawShape) => {
150
- [x: string]: {
151
- demandOption: boolean;
152
- description: any;
153
- type: any;
154
- choices: any;
155
- };
151
+ [x: string]: Options;
156
152
  };
157
153
  export declare const fetchConfig: (path: string) => Promise<Config>;
@@ -6,9 +6,9 @@ export declare const setupWithServer: (argv: Config) => Promise<{
6
6
  fetchStorageWorker: {
7
7
  worker: import("comlink").Remote<{
8
8
  startFetch: (options: {
9
- block?: string | number | null | undefined;
10
- endpoint?: string | string[] | undefined;
11
- dbPath?: string | undefined;
9
+ block?: number | string | null;
10
+ endpoint?: string | string[];
11
+ dbPath?: string;
12
12
  config: import("./utils/fetch-storages.js").FetchStorageConfig;
13
13
  }) => Promise<void>;
14
14
  }>;
@@ -7,9 +7,9 @@ export declare const setupContext: (argv: Config, overrideParent?: boolean) => P
7
7
  fetchStorageWorker: {
8
8
  worker: import("comlink").Remote<{
9
9
  startFetch: (options: {
10
- block?: string | number | null | undefined;
11
- endpoint?: string | string[] | undefined;
12
- dbPath?: string | undefined;
10
+ block?: number | string | null;
11
+ endpoint?: string | string[];
12
+ dbPath?: string;
13
13
  config: import("./utils/fetch-storages.js").FetchStorageConfig;
14
14
  }) => Promise<void>;
15
15
  }>;
@@ -1,4 +1,4 @@
1
1
  import _ from 'lodash';
2
2
  export { defaultLogger, truncate } from '@acala-network/chopsticks-core';
3
3
  export declare const spinnerFrames: string[];
4
- export declare const apiFetching: _.DebouncedFunc<() => void>;
4
+ export declare const apiFetching: _.DebouncedFuncLeading<() => void>;
@@ -1,4 +1,3 @@
1
- /// <reference types="node" resolution-mode="require"/>
2
1
  import { Block, Blockchain, RuntimeVersion } from '@acala-network/chopsticks-core';
3
2
  import { HexString } from '@polkadot/util/types';
4
3
  import { Step } from './types.js';
@@ -1,4 +1,5 @@
1
1
  import { BuildBlockMode } from '@acala-network/chopsticks-core';
2
+ import { Options } from 'yargs';
2
3
  import { ZodNativeEnum, ZodRawShape, ZodTypeAny, z } from 'zod';
3
4
  export declare const zHex: z.ZodType<`0x${string}`, z.ZodTypeDef, `0x${string}`>;
4
5
  export declare const zHash: z.ZodIntersection<z.ZodString, z.ZodType<`0x${string}`, z.ZodTypeDef, `0x${string}`>>;
@@ -147,11 +148,6 @@ export declare const configSchema: z.ZodObject<{
147
148
  }>;
148
149
  export type Config = z.infer<typeof configSchema>;
149
150
  export declare const getYargsOptions: (zodShape: ZodRawShape) => {
150
- [x: string]: {
151
- demandOption: boolean;
152
- description: any;
153
- type: any;
154
- choices: any;
155
- };
151
+ [x: string]: Options;
156
152
  };
157
153
  export declare const fetchConfig: (path: string) => Promise<Config>;
@@ -6,9 +6,9 @@ export declare const setupWithServer: (argv: Config) => Promise<{
6
6
  fetchStorageWorker: {
7
7
  worker: import("comlink").Remote<{
8
8
  startFetch: (options: {
9
- block?: string | number | null | undefined;
10
- endpoint?: string | string[] | undefined;
11
- dbPath?: string | undefined;
9
+ block?: number | string | null;
10
+ endpoint?: string | string[];
11
+ dbPath?: string;
12
12
  config: import("./utils/fetch-storages.js").FetchStorageConfig;
13
13
  }) => Promise<void>;
14
14
  }>;
package/package.json CHANGED
@@ -1,26 +1,24 @@
1
1
  {
2
2
  "name": "@acala-network/chopsticks",
3
- "version": "0.12.2",
3
+ "version": "0.13.0-1",
4
4
  "author": "Acala Developers <hello@acala.network>",
5
5
  "license": "Apache-2.0",
6
6
  "bin": "./chopsticks.cjs",
7
7
  "type": "module",
8
8
  "scripts": {
9
9
  "clean": "rm -rf dist tsconfig.tsbuildinfo",
10
- "build": "yarn clean && yarn build:cjs && yarn build:esm",
11
- "build:cjs": "swc ./src --config-file ../../.cjsswcrc -d dist/cjs --copy-files && tsc -p tsconfig.json --declarationDir dist/cjs && echo '{\"type\": \"commonjs\"}' > dist/cjs/package.json",
12
- "build:esm": "swc ./src --config-file ../../.esmswcrc -d dist/esm --copy-files && tsc -p tsconfig.json --declarationDir dist/esm",
10
+ "build": "yarn clean && ../../package-build.sh",
13
11
  "docs:prep": "typedoc",
14
12
  "depcheck": "npx depcheck --ignore-patterns='*.test.ts'"
15
13
  },
16
14
  "dependencies": {
17
- "@acala-network/chopsticks-core": "0.12.2",
18
- "@acala-network/chopsticks-db": "0.12.2",
15
+ "@acala-network/chopsticks-core": "0.13.0-1",
16
+ "@acala-network/chopsticks-db": "0.13.0-1",
19
17
  "@pnpm/npm-conf": "^2.2.2",
20
- "@polkadot/api": "^11.2.1",
21
- "@polkadot/api-augment": "^11.2.1",
22
- "@polkadot/rpc-provider": "^11.2.1",
23
- "@polkadot/types": "^11.2.1",
18
+ "@polkadot/api": "^12.1.1",
19
+ "@polkadot/api-augment": "^12.1.1",
20
+ "@polkadot/rpc-provider": "^12.1.1",
21
+ "@polkadot/types": "^12.1.1",
24
22
  "@polkadot/util": "^12.6.2",
25
23
  "@polkadot/util-crypto": "^12.6.2",
26
24
  "axios": "^1.6.8",
@@ -30,20 +28,20 @@
30
28
  "js-yaml": "^4.1.0",
31
29
  "jsondiffpatch": "^0.5.0",
32
30
  "lodash": "^4.17.21",
33
- "ws": "^8.16.0",
31
+ "ws": "^8.17.1",
34
32
  "yargs": "^17.7.2",
35
33
  "zod": "^3.22.4"
36
34
  },
37
35
  "devDependencies": {
38
- "@swc/cli": "0.1.65",
39
- "@swc/core": "^1.4.8",
36
+ "@swc/cli": "0.4.0",
37
+ "@swc/core": "^1.6.7",
40
38
  "@types/global-agent": "^2.1.3",
41
39
  "@types/js-yaml": "^4.0.9",
42
- "@types/lodash": "^4.17.0",
43
- "@types/node": "^20.11.5",
40
+ "@types/lodash": "^4.17.6",
41
+ "@types/node": "^20.14.9",
44
42
  "@types/ws": "^8.5.10",
45
43
  "@types/yargs": "^17.0.32",
46
- "typescript": "^5.3.3"
44
+ "typescript": "^5.5.3"
47
45
  },
48
46
  "files": [
49
47
  "dist/esm/**",