@filoz/repair-cli 0.1.0 → 0.1.2
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.
- package/dist/package.json +4 -3
- package/dist/src/commands/datasets.d.ts +15 -1
- package/dist/src/commands/datasets.d.ts.map +1 -1
- package/dist/src/commands/datasets.js +94 -1
- package/dist/src/commands/datasets.js.map +1 -1
- package/dist/src/commands/providers.d.ts +15 -1
- package/dist/src/commands/providers.d.ts.map +1 -1
- package/dist/src/commands/repair.d.ts +15 -1
- package/dist/src/commands/repair.d.ts.map +1 -1
- package/dist/src/commands/wallet.d.ts +15 -1
- package/dist/src/commands/wallet.d.ts.map +1 -1
- package/dist/src/db/get-repair-dataset.d.ts.map +1 -1
- package/dist/src/db/get-repair-dataset.js +5 -2
- package/dist/src/db/get-repair-dataset.js.map +1 -1
- package/dist/src/middleware.d.ts +30 -2
- package/dist/src/middleware.d.ts.map +1 -1
- package/dist/src/middleware.js +7 -0
- package/dist/src/middleware.js.map +1 -1
- package/dist/src/pipeline/create-datasets.d.ts +1 -1
- package/dist/src/pipeline/create-datasets.d.ts.map +1 -1
- package/dist/src/pipeline/create-datasets.js +1 -1
- package/dist/src/pipeline/create-datasets.js.map +1 -1
- package/dist/src/utils.d.ts +134 -118
- package/dist/src/utils.d.ts.map +1 -1
- package/dist/src/utils.js +10 -18
- package/dist/src/utils.js.map +1 -1
- package/package.json +4 -3
- package/readme.md +1 -1
- package/src/commands/datasets.ts +96 -1
- package/src/db/get-repair-dataset.ts +6 -2
- package/src/middleware.ts +9 -0
- package/src/pipeline/create-datasets.ts +1 -7
- package/src/utils.ts +15 -22
package/dist/src/utils.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../src/utils.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAA;AACzD,OAAO,EAAE,KAAK,KAA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M,aAAa;;iBAExB,CAAA;AAEF,wBAAsB,mBAAmB,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,aAAa,CAAC,CAQhF;AAED,wBAAsB,oBAAoB,CAAC,EAAE,EAAE,aAAa,iBAgC3D;AASD,wBAAgB,QAAQ,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,KAAK,UAGlD;AAGD,wBAAgB,wBAAwB,IAAI,cAAc,CAKzD;AAKD,wBAAsB,QAAQ,CAAC,EAAE,QAAQ,EAAE,UAAU,EAAE,EAAE;IAAE,QAAQ,EAAE,MAAM,CAAC;IAAC,UAAU,EAAE,MAAM,CAAA;CAAE,mBAehG;AASD,wBAAsB,oBAAoB,CAAC,SAAS,EAAE,MAAM,EAAE,EAAE,QAAQ,EAAE,MAAM,+BAe/E;AAED,eAAO,MAAM,0BAA0B,GAAI,CAAC,SAAS,OAAO,GAAG,WAAW,EAAE,CAAC,SAAS,MAAM,CAAC,CAAC,GAAG,CAAC,CAAC,SAAS,CAAC,EAC3G,OAAO,CAAC,EACR,UAAU,CAAC,EAAE,4BAed,CAAA"}
|
package/dist/src/utils.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { getChain } from '@filoz/synapse-core/chains';
|
|
2
|
-
import Conf from 'conf';
|
|
3
2
|
import { getTableColumns, sql } from 'drizzle-orm';
|
|
4
3
|
import { drizzle } from 'drizzle-orm/libsql';
|
|
5
4
|
import { z } from 'incur';
|
|
5
|
+
import { Conf } from 'iso-conf';
|
|
6
6
|
import { request } from 'iso-web/http';
|
|
7
7
|
import pLocate from 'p-locate';
|
|
8
8
|
import terminalLink from 'terminal-link';
|
|
@@ -11,26 +11,18 @@ import { privateKeyToAccount } from 'viem/accounts';
|
|
|
11
11
|
import packageJson from '../package.json' with { type: 'json' };
|
|
12
12
|
import * as schema from "./local-schema.js";
|
|
13
13
|
export const EARLY_REPAIR_SOURCE = 'early-repair6';
|
|
14
|
+
export const configSchema = z.object({
|
|
15
|
+
privateKey: z.string().optional(),
|
|
16
|
+
indexerMainnetUrl: z.url().optional(),
|
|
17
|
+
indexerCalibrationUrl: z.url().optional(),
|
|
18
|
+
chainId: z.number().optional(),
|
|
19
|
+
dbPath: z.string().optional(),
|
|
20
|
+
source: z.string().optional(),
|
|
21
|
+
});
|
|
14
22
|
export const config = new Conf({
|
|
15
23
|
projectName: packageJson.name,
|
|
16
24
|
projectSuffix: '',
|
|
17
|
-
schema:
|
|
18
|
-
privateKey: {
|
|
19
|
-
type: 'string',
|
|
20
|
-
},
|
|
21
|
-
dbPath: {
|
|
22
|
-
type: 'string',
|
|
23
|
-
},
|
|
24
|
-
indexerMainnetUrl: {
|
|
25
|
-
type: 'string',
|
|
26
|
-
},
|
|
27
|
-
indexerCalibrationUrl: {
|
|
28
|
-
type: 'string',
|
|
29
|
-
},
|
|
30
|
-
chainId: {
|
|
31
|
-
type: 'number',
|
|
32
|
-
},
|
|
33
|
-
},
|
|
25
|
+
schema: configSchema,
|
|
34
26
|
});
|
|
35
27
|
export const name = packageJson.name;
|
|
36
28
|
export const version = packageJson.version;
|
package/dist/src/utils.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"utils.js","sourceRoot":"","sources":["../../src/utils.ts"],"names":[],"mappings":"AACA,OAAO,EAAc,QAAQ,EAAE,MAAM,4BAA4B,CAAA;AACjE,OAAO,
|
|
1
|
+
{"version":3,"file":"utils.js","sourceRoot":"","sources":["../../src/utils.ts"],"names":[],"mappings":"AACA,OAAO,EAAc,QAAQ,EAAE,MAAM,4BAA4B,CAAA;AACjE,OAAO,EAAE,eAAe,EAAY,GAAG,EAAE,MAAM,aAAa,CAAA;AAC5D,OAAO,EAAE,OAAO,EAAE,MAAM,oBAAoB,CAAA;AAG5C,OAAO,EAAE,CAAC,EAAE,MAAM,OAAO,CAAA;AACzB,OAAO,EAAE,IAAI,EAAE,MAAM,UAAU,CAAA;AAC/B,OAAO,EAAE,OAAO,EAAE,MAAM,c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AAC,KAAK,CAAC,CAAA;IAClC,MAAM,IAAI,GAAG,OAAO,IAAK,MAAM,CAAC,IAAI,CAAC,GAAG,CAAS,CAAA;IACjD,MAAM,CAAC,GAAG,IAAI,CAAC,MAAM,CACnB,CAAC,GAAG,EAAE,MAAM,EAAE,EAAE;QACd,MAAM,OAAO,GAAG,GAAG,CAAC,MAAM,CAAC,CAAC,IAAI,CAAA;QAEhC,GAAG,CAAC,MAAM,CAAC,GAAG,GAAG,CAAC,GAAG,CAAC,YAAY,OAAO,EAAE,CAAC,CAAA;QAC5C,OAAO,GAAG,CAAA;IACZ,CAAC,EACD,EAAoB,CACrB,CAAA;IAED,OAAO,CAAC,CAAA;AACV,CAAC,CAAA"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@filoz/repair-cli",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.2",
|
|
4
4
|
"description": "Early repair for faulty service providers and datasets",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
"module": "dist/src/cli.js",
|
|
26
26
|
"types": "dist/src/cli.d.ts",
|
|
27
27
|
"bin": {
|
|
28
|
-
"repair
|
|
28
|
+
"repair": "./dist/src/cli.js"
|
|
29
29
|
},
|
|
30
30
|
"sideEffects": false,
|
|
31
31
|
"exports": {
|
|
@@ -96,12 +96,13 @@
|
|
|
96
96
|
},
|
|
97
97
|
"dependencies": {
|
|
98
98
|
"@clack/prompts": "^1.5.1",
|
|
99
|
-
"@filoz/synapse-core": "^0.
|
|
99
|
+
"@filoz/synapse-core": "^0.7.0",
|
|
100
100
|
"@libsql/client": "^0.17.3",
|
|
101
101
|
"conf": "^15.1.0",
|
|
102
102
|
"drizzle-orm": "^0.45.2",
|
|
103
103
|
"incur": "^0.4.6",
|
|
104
104
|
"iso-base": "^4.4.0",
|
|
105
|
+
"iso-conf": "^0.4.0",
|
|
105
106
|
"iso-web": "^3.1.2",
|
|
106
107
|
"p-all": "^5.0.1",
|
|
107
108
|
"p-locate": "^7.0.0",
|
package/readme.md
CHANGED
package/src/commands/datasets.ts
CHANGED
|
@@ -1,7 +1,10 @@
|
|
|
1
|
+
import * as p from '@clack/prompts'
|
|
2
|
+
import * as SP from '@filoz/synapse-core/sp'
|
|
3
|
+
import { getPdpDataSet } from '@filoz/synapse-core/warm-storage'
|
|
1
4
|
import { and, eq } from 'drizzle-orm'
|
|
2
5
|
import { Cli, z } from 'incur'
|
|
3
6
|
import { contextMiddleware, contextSchema } from '../middleware.ts'
|
|
4
|
-
import { globalOptions } from '../utils.ts'
|
|
7
|
+
import { globalOptions, hashLink } from '../utils.ts'
|
|
5
8
|
export const datasets = Cli.create('datasets', {
|
|
6
9
|
description: 'Dataset commands',
|
|
7
10
|
options: globalOptions,
|
|
@@ -60,3 +63,95 @@ datasets.command('list', {
|
|
|
60
63
|
}
|
|
61
64
|
},
|
|
62
65
|
})
|
|
66
|
+
|
|
67
|
+
datasets.command('terminate', {
|
|
68
|
+
description: 'Terminate a dataset',
|
|
69
|
+
args: z.object({
|
|
70
|
+
id: z.coerce.bigint().describe('Dataset ID to terminate'),
|
|
71
|
+
}),
|
|
72
|
+
options: globalOptions,
|
|
73
|
+
middleware: [contextMiddleware],
|
|
74
|
+
outputPolicy: 'agent-only',
|
|
75
|
+
run: async (c) => {
|
|
76
|
+
const isInteractive = !c.agent && !c.formatExplicit
|
|
77
|
+
const spinner = p.spinner()
|
|
78
|
+
try {
|
|
79
|
+
if (isInteractive) {
|
|
80
|
+
spinner.start('Getting dataset...')
|
|
81
|
+
}
|
|
82
|
+
const dataset = await getPdpDataSet(c.var.client, { dataSetId: c.args.id })
|
|
83
|
+
if (!dataset) {
|
|
84
|
+
return c.error({
|
|
85
|
+
code: 'DATASET_NOT_FOUND',
|
|
86
|
+
message: 'Dataset not found',
|
|
87
|
+
retryable: false,
|
|
88
|
+
})
|
|
89
|
+
}
|
|
90
|
+
if (isInteractive) {
|
|
91
|
+
spinner.message(`Terminating dataset ${dataset?.dataSetId} at ${dataset?.provider.pdp.serviceURL}...`)
|
|
92
|
+
}
|
|
93
|
+
const result = await SP.terminateService(c.var.client, {
|
|
94
|
+
dataSetId: c.args.id,
|
|
95
|
+
serviceURL: dataset?.provider.pdp.serviceURL,
|
|
96
|
+
})
|
|
97
|
+
|
|
98
|
+
const waitForResult = await SP.waitForTerminateService({
|
|
99
|
+
statusUrl: result.statusUrl,
|
|
100
|
+
onHash: (hash) => {
|
|
101
|
+
if (isInteractive) {
|
|
102
|
+
spinner.message(`Waiting for tx ${hashLink(hash, c.var.chain)} to be mined...`)
|
|
103
|
+
}
|
|
104
|
+
},
|
|
105
|
+
})
|
|
106
|
+
if (isInteractive) {
|
|
107
|
+
spinner.stop(`Dataset ${dataset?.dataSetId} terminated successfully.`)
|
|
108
|
+
}
|
|
109
|
+
return c.ok(waitForResult)
|
|
110
|
+
} catch (error) {
|
|
111
|
+
const msg = error instanceof Error ? error.message : 'Failed to terminate the dataset'
|
|
112
|
+
if (isInteractive) {
|
|
113
|
+
spinner.error(msg)
|
|
114
|
+
}
|
|
115
|
+
if (c.options.debug) {
|
|
116
|
+
console.error(error)
|
|
117
|
+
}
|
|
118
|
+
return c.error({
|
|
119
|
+
code: 'DATASETS_FAILED',
|
|
120
|
+
message: msg,
|
|
121
|
+
retryable: true,
|
|
122
|
+
})
|
|
123
|
+
}
|
|
124
|
+
},
|
|
125
|
+
})
|
|
126
|
+
|
|
127
|
+
datasets.command('show', {
|
|
128
|
+
description: 'Show a dataset',
|
|
129
|
+
args: z.object({
|
|
130
|
+
id: z.coerce.bigint().describe('Dataset ID to show'),
|
|
131
|
+
}),
|
|
132
|
+
options: globalOptions,
|
|
133
|
+
middleware: [contextMiddleware],
|
|
134
|
+
run: async (c) => {
|
|
135
|
+
try {
|
|
136
|
+
const dataset = await getPdpDataSet(c.var.client, { dataSetId: c.args.id })
|
|
137
|
+
if (!dataset) {
|
|
138
|
+
return c.error({
|
|
139
|
+
code: 'DATASET_NOT_FOUND',
|
|
140
|
+
message: 'Dataset not found',
|
|
141
|
+
retryable: false,
|
|
142
|
+
})
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
return c.ok(dataset)
|
|
146
|
+
} catch (error) {
|
|
147
|
+
if (c.options.debug) {
|
|
148
|
+
console.error(error)
|
|
149
|
+
}
|
|
150
|
+
return c.error({
|
|
151
|
+
code: 'DATASETS_FAILED',
|
|
152
|
+
message: error instanceof Error ? error.message : 'Failed to terminate the dataset',
|
|
153
|
+
retryable: true,
|
|
154
|
+
})
|
|
155
|
+
}
|
|
156
|
+
},
|
|
157
|
+
})
|
|
@@ -21,7 +21,7 @@ export async function getRepairDataset({
|
|
|
21
21
|
}: GetRepairDatasetOptions): Promise<bigint | null> {
|
|
22
22
|
const schema = indexerDb._.fullSchema
|
|
23
23
|
|
|
24
|
-
const
|
|
24
|
+
const result = await indexerDb
|
|
25
25
|
.select({
|
|
26
26
|
dataSetId: schema.dataSets.dataSetId,
|
|
27
27
|
})
|
|
@@ -40,5 +40,9 @@ export async function getRepairDataset({
|
|
|
40
40
|
.orderBy(asc(schema.dataSets.dataSetId))
|
|
41
41
|
.limit(1)
|
|
42
42
|
|
|
43
|
-
|
|
43
|
+
if (result.length === 0) {
|
|
44
|
+
return null
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
return result[0].dataSetId
|
|
44
48
|
}
|
package/src/middleware.ts
CHANGED
|
@@ -16,6 +16,15 @@ export const contextSchema = z.object({
|
|
|
16
16
|
|
|
17
17
|
export const contextMiddleware = middleware<typeof contextSchema>(async (c, next) => {
|
|
18
18
|
const { dbPath, chainId, indexerMainnetUrl, indexerCalibrationUrl } = config.store
|
|
19
|
+
|
|
20
|
+
if (!dbPath || !chainId || !indexerMainnetUrl || !indexerCalibrationUrl) {
|
|
21
|
+
return c.error({
|
|
22
|
+
code: 'CONFIG_NOT_SET',
|
|
23
|
+
message: 'Config not set. Please run `repair setup` first.',
|
|
24
|
+
retryable: false,
|
|
25
|
+
})
|
|
26
|
+
}
|
|
27
|
+
|
|
19
28
|
const localDb = await createLocalDatabase(dbPath)
|
|
20
29
|
const indexerDb = drizzlePostgres(chainId === 314 ? indexerMainnetUrl : indexerCalibrationUrl, {
|
|
21
30
|
schema: indexerSchema,
|
|
@@ -18,14 +18,8 @@ export type EnsureRepairDatasetOptions = {
|
|
|
18
18
|
* Ensure the repair dataset exists by creating it if it doesn't.
|
|
19
19
|
*
|
|
20
20
|
* @param options - The options for ensuring the repair dataset.
|
|
21
|
-
* @returns {Promise<bigint>} - The ID of the created dataset.
|
|
22
21
|
*/
|
|
23
|
-
export async function ensureRepairDataset({
|
|
24
|
-
localDb,
|
|
25
|
-
indexerDb,
|
|
26
|
-
client,
|
|
27
|
-
repair,
|
|
28
|
-
}: EnsureRepairDatasetOptions): Promise<bigint> {
|
|
22
|
+
export async function ensureRepairDataset({ localDb, indexerDb, client, repair }: EnsureRepairDatasetOptions) {
|
|
29
23
|
const log = p.taskLog({
|
|
30
24
|
title: 'Ensuring repair dataset',
|
|
31
25
|
})
|
package/src/utils.ts
CHANGED
|
@@ -1,42 +1,35 @@
|
|
|
1
1
|
import type { MetadataObject } from '@filoz/synapse-core'
|
|
2
2
|
import { type Chain, getChain } from '@filoz/synapse-core/chains'
|
|
3
|
-
import Conf from 'conf'
|
|
4
3
|
import { getTableColumns, type SQL, sql } from 'drizzle-orm'
|
|
5
4
|
import { drizzle } from 'drizzle-orm/libsql'
|
|
6
5
|
import type { PgTable } from 'drizzle-orm/pg-core'
|
|
7
6
|
import type { SQLiteTable } from 'drizzle-orm/sqlite-core'
|
|
8
7
|
import { z } from 'incur'
|
|
8
|
+
import { Conf } from 'iso-conf'
|
|
9
9
|
import { request } from 'iso-web/http'
|
|
10
10
|
import pLocate from 'p-locate'
|
|
11
11
|
import terminalLink from 'terminal-link'
|
|
12
|
-
import { createWalletClient, http } from 'viem'
|
|
12
|
+
import { createWalletClient, type Hex, http } from 'viem'
|
|
13
13
|
import { privateKeyToAccount } from 'viem/accounts'
|
|
14
14
|
import packageJson from '../package.json' with { type: 'json' }
|
|
15
15
|
import * as schema from './local-schema.ts'
|
|
16
|
-
import type {
|
|
16
|
+
import type { LocalDatabase } from './types.ts'
|
|
17
17
|
|
|
18
18
|
export const EARLY_REPAIR_SOURCE = 'early-repair6'
|
|
19
19
|
|
|
20
|
-
export const
|
|
20
|
+
export const configSchema = z.object({
|
|
21
|
+
privateKey: z.string().optional(),
|
|
22
|
+
indexerMainnetUrl: z.url().optional(),
|
|
23
|
+
indexerCalibrationUrl: z.url().optional(),
|
|
24
|
+
chainId: z.number().optional(),
|
|
25
|
+
dbPath: z.string().optional(),
|
|
26
|
+
source: z.string().optional(),
|
|
27
|
+
})
|
|
28
|
+
|
|
29
|
+
export const config = new Conf({
|
|
21
30
|
projectName: packageJson.name,
|
|
22
31
|
projectSuffix: '',
|
|
23
|
-
schema:
|
|
24
|
-
privateKey: {
|
|
25
|
-
type: 'string',
|
|
26
|
-
},
|
|
27
|
-
dbPath: {
|
|
28
|
-
type: 'string',
|
|
29
|
-
},
|
|
30
|
-
indexerMainnetUrl: {
|
|
31
|
-
type: 'string',
|
|
32
|
-
},
|
|
33
|
-
indexerCalibrationUrl: {
|
|
34
|
-
type: 'string',
|
|
35
|
-
},
|
|
36
|
-
chainId: {
|
|
37
|
-
type: 'number',
|
|
38
|
-
},
|
|
39
|
-
},
|
|
32
|
+
schema: configSchema,
|
|
40
33
|
})
|
|
41
34
|
|
|
42
35
|
export const name = packageJson.name
|
|
@@ -47,7 +40,7 @@ function privateKeyFromConfig() {
|
|
|
47
40
|
if (!privateKey) {
|
|
48
41
|
throw new Error('Private key not found. Please run `repair-cli setup` first.')
|
|
49
42
|
}
|
|
50
|
-
return privateKey
|
|
43
|
+
return privateKey as Hex
|
|
51
44
|
}
|
|
52
45
|
|
|
53
46
|
/**
|