windmill-cli 1.740.0 → 1.742.0
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/esm/main.js +97 -35
- package/package.json +1 -1
package/esm/main.js
CHANGED
|
@@ -16784,7 +16784,7 @@ var init_OpenAPI = __esm(() => {
|
|
|
16784
16784
|
PASSWORD: undefined,
|
|
16785
16785
|
TOKEN: getEnv3("WM_TOKEN"),
|
|
16786
16786
|
USERNAME: undefined,
|
|
16787
|
-
VERSION: "1.
|
|
16787
|
+
VERSION: "1.742.0",
|
|
16788
16788
|
WITH_CREDENTIALS: true,
|
|
16789
16789
|
interceptors: {
|
|
16790
16790
|
request: new Interceptors,
|
|
@@ -17183,6 +17183,7 @@ __export(exports_services_gen, {
|
|
|
17183
17183
|
runFlowByPath: () => runFlowByPath,
|
|
17184
17184
|
runDynamicSelect: () => runDynamicSelect,
|
|
17185
17185
|
runCodeWorkflowTask: () => runCodeWorkflowTask,
|
|
17186
|
+
runAuditLogsS3Backfill: () => runAuditLogsS3Backfill,
|
|
17186
17187
|
runAndStreamScriptByPathGet: () => runAndStreamScriptByPathGet,
|
|
17187
17188
|
runAndStreamScriptByPath: () => runAndStreamScriptByPath,
|
|
17188
17189
|
runAndStreamScriptByHashGet: () => runAndStreamScriptByHashGet,
|
|
@@ -17566,6 +17567,7 @@ __export(exports_services_gen, {
|
|
|
17566
17567
|
getCapture: () => getCapture,
|
|
17567
17568
|
getAzureTrigger: () => getAzureTrigger,
|
|
17568
17569
|
getAuditLogsS3Status: () => getAuditLogsS3Status,
|
|
17570
|
+
getAuditLogsS3BackfillStatus: () => getAuditLogsS3BackfillStatus,
|
|
17569
17571
|
getAuditLog: () => getAuditLog,
|
|
17570
17572
|
getAssetsGraph: () => getAssetsGraph,
|
|
17571
17573
|
getArgsFromHistoryOrSavedInput: () => getArgsFromHistoryOrSavedInput,
|
|
@@ -18327,6 +18329,18 @@ var backendVersion = () => {
|
|
|
18327
18329
|
method: "GET",
|
|
18328
18330
|
url: "/settings/audit_logs_s3_status"
|
|
18329
18331
|
});
|
|
18332
|
+
}, runAuditLogsS3Backfill = (data3) => {
|
|
18333
|
+
return request(OpenAPI, {
|
|
18334
|
+
method: "POST",
|
|
18335
|
+
url: "/settings/audit_logs_s3_backfill",
|
|
18336
|
+
body: data3.requestBody,
|
|
18337
|
+
mediaType: "application/json"
|
|
18338
|
+
});
|
|
18339
|
+
}, getAuditLogsS3BackfillStatus = () => {
|
|
18340
|
+
return request(OpenAPI, {
|
|
18341
|
+
method: "GET",
|
|
18342
|
+
url: "/settings/audit_logs_s3_backfill_status"
|
|
18343
|
+
});
|
|
18330
18344
|
}, sendStats = () => {
|
|
18331
18345
|
return request(OpenAPI, {
|
|
18332
18346
|
method: "POST",
|
|
@@ -25528,7 +25542,7 @@ var init_auth = __esm(async () => {
|
|
|
25528
25542
|
});
|
|
25529
25543
|
|
|
25530
25544
|
// src/core/constants.ts
|
|
25531
|
-
var WM_FORK_PREFIX = "wm-fork", VERSION = "1.
|
|
25545
|
+
var WM_FORK_PREFIX = "wm-fork", VERSION = "1.742.0";
|
|
25532
25546
|
|
|
25533
25547
|
// src/utils/git.ts
|
|
25534
25548
|
var exports_git = {};
|
|
@@ -77053,6 +77067,30 @@ ${details.join(`
|
|
|
77053
77067
|
`)}
|
|
77054
77068
|
Use --remote to preview deployed workspace scripts instead.`);
|
|
77055
77069
|
}
|
|
77070
|
+
function collectStepPaths(flowValue) {
|
|
77071
|
+
const paths = [];
|
|
77072
|
+
const walk = (modules) => {
|
|
77073
|
+
for (const m of modules ?? []) {
|
|
77074
|
+
const v = m?.value;
|
|
77075
|
+
if (!v)
|
|
77076
|
+
continue;
|
|
77077
|
+
if ((v.type === "script" || v.type === "flow") && typeof v.path === "string") {
|
|
77078
|
+
paths.push(v.path);
|
|
77079
|
+
}
|
|
77080
|
+
walk(v.modules);
|
|
77081
|
+
walk(v.default);
|
|
77082
|
+
for (const b of v.branches ?? [])
|
|
77083
|
+
walk(b?.modules);
|
|
77084
|
+
walk(v.tools);
|
|
77085
|
+
}
|
|
77086
|
+
};
|
|
77087
|
+
walk(flowValue?.modules);
|
|
77088
|
+
if (flowValue?.failure_module)
|
|
77089
|
+
walk([flowValue.failure_module]);
|
|
77090
|
+
if (flowValue?.preprocessor_module)
|
|
77091
|
+
walk([flowValue.preprocessor_module]);
|
|
77092
|
+
return paths;
|
|
77093
|
+
}
|
|
77056
77094
|
async function pushFlow(workspace, remotePath, localPath, message, permissionedAsContext) {
|
|
77057
77095
|
if (alreadySynced3.includes(localPath)) {
|
|
77058
77096
|
return;
|
|
@@ -77082,6 +77120,10 @@ async function pushFlow(workspace, remotePath, localPath, message, permissionedA
|
|
|
77082
77120
|
if (missingFiles.length > 0) {
|
|
77083
77121
|
throw new Error(`Cannot push flow ${remotePath}: missing inline script file(s): ${missingFiles.join(", ")}. ` + `Either restore the file(s) or remove the !inline reference(s) from flow.yaml before pushing.`);
|
|
77084
77122
|
}
|
|
77123
|
+
const badStepPaths = collectStepPaths(localFlow.value).filter((p) => p !== "" && !/^(u|f|g|hub)\//.test(p));
|
|
77124
|
+
if (badStepPaths.length > 0) {
|
|
77125
|
+
throw new Error(`Cannot push flow ${remotePath}: step(s) reference non-workspace path(s): ${badStepPaths.join(", ")}. ` + `Flow step paths must be workspace paths (u/, f/, g/ or hub/), not absolute or local filesystem paths. ` + `This usually means flow.yaml was generated with paths from a checkout directory.`);
|
|
77126
|
+
}
|
|
77085
77127
|
const hasOnBehalfOf = localFlow.has_on_behalf_of ?? !!localFlow.on_behalf_of_email;
|
|
77086
77128
|
delete localFlow.has_on_behalf_of;
|
|
77087
77129
|
const preserveFields = {};
|
|
@@ -79453,25 +79495,27 @@ async getRootJobId(jobId?: string): Promise<string>
|
|
|
79453
79495
|
/**
|
|
79454
79496
|
* @deprecated Use runScriptByPath or runScriptByHash instead
|
|
79455
79497
|
*/
|
|
79456
|
-
async runScript(path: string | null = null, hash_: string | null = null, args: Record<string, any> | null = null, verbose: boolean = false): Promise<any>
|
|
79498
|
+
async runScript(path: string | null = null, hash_: string | null = null, args: Record<string, any> | null = null, verbose: boolean = false, tag: string | null = null): Promise<any>
|
|
79457
79499
|
|
|
79458
79500
|
/**
|
|
79459
79501
|
* Run a script synchronously by its path and wait for the result
|
|
79460
79502
|
* @param path - Script path in Windmill
|
|
79461
79503
|
* @param args - Arguments to pass to the script
|
|
79462
79504
|
* @param verbose - Enable verbose logging
|
|
79505
|
+
* @param tag - Override the worker tag the job runs on
|
|
79463
79506
|
* @returns Script execution result
|
|
79464
79507
|
*/
|
|
79465
|
-
async runScriptByPath(path: string, args: Record<string, any> | null = null, verbose: boolean = false): Promise<any>
|
|
79508
|
+
async runScriptByPath(path: string, args: Record<string, any> | null = null, verbose: boolean = false, tag: string | null = null): Promise<any>
|
|
79466
79509
|
|
|
79467
79510
|
/**
|
|
79468
79511
|
* Run a script synchronously by its hash and wait for the result
|
|
79469
79512
|
* @param hash_ - Script hash in Windmill
|
|
79470
79513
|
* @param args - Arguments to pass to the script
|
|
79471
79514
|
* @param verbose - Enable verbose logging
|
|
79515
|
+
* @param tag - Override the worker tag the job runs on
|
|
79472
79516
|
* @returns Script execution result
|
|
79473
79517
|
*/
|
|
79474
|
-
async runScriptByHash(hash_: string, args: Record<string, any> | null = null, verbose: boolean = false): Promise<any>
|
|
79518
|
+
async runScriptByHash(hash_: string, args: Record<string, any> | null = null, verbose: boolean = false, tag: string | null = null): Promise<any>
|
|
79475
79519
|
|
|
79476
79520
|
/**
|
|
79477
79521
|
* Append a text to the result stream
|
|
@@ -79490,9 +79534,10 @@ async streamResult(stream: AsyncIterable<string>): Promise<void>
|
|
|
79490
79534
|
* @param path - Flow path in Windmill
|
|
79491
79535
|
* @param args - Arguments to pass to the flow
|
|
79492
79536
|
* @param verbose - Enable verbose logging
|
|
79537
|
+
* @param tag - Override the worker tag the job runs on
|
|
79493
79538
|
* @returns Flow execution result
|
|
79494
79539
|
*/
|
|
79495
|
-
async runFlow(path: string | null = null, args: Record<string, any> | null = null, verbose: boolean = false): Promise<any>
|
|
79540
|
+
async runFlow(path: string | null = null, args: Record<string, any> | null = null, verbose: boolean = false, tag: string | null = null): Promise<any>
|
|
79496
79541
|
|
|
79497
79542
|
/**
|
|
79498
79543
|
* Wait for a job to complete and return its result
|
|
@@ -79519,25 +79564,27 @@ async getResultMaybe(jobId: string): Promise<any>
|
|
|
79519
79564
|
/**
|
|
79520
79565
|
* @deprecated Use runScriptByPathAsync or runScriptByHashAsync instead
|
|
79521
79566
|
*/
|
|
79522
|
-
async runScriptAsync(path: string | null, hash_: string | null, args: Record<string, any> | null, scheduledInSeconds: number | null = null): Promise<string>
|
|
79567
|
+
async runScriptAsync(path: string | null, hash_: string | null, args: Record<string, any> | null, scheduledInSeconds: number | null = null, tag: string | null = null): Promise<string>
|
|
79523
79568
|
|
|
79524
79569
|
/**
|
|
79525
79570
|
* Run a script asynchronously by its path
|
|
79526
79571
|
* @param path - Script path in Windmill
|
|
79527
79572
|
* @param args - Arguments to pass to the script
|
|
79528
79573
|
* @param scheduledInSeconds - Schedule execution for a future time (in seconds)
|
|
79574
|
+
* @param tag - Override the worker tag the job runs on
|
|
79529
79575
|
* @returns Job ID of the created job
|
|
79530
79576
|
*/
|
|
79531
|
-
async runScriptByPathAsync(path: string, args: Record<string, any> | null = null, scheduledInSeconds: number | null = null): Promise<string>
|
|
79577
|
+
async runScriptByPathAsync(path: string, args: Record<string, any> | null = null, scheduledInSeconds: number | null = null, tag: string | null = null): Promise<string>
|
|
79532
79578
|
|
|
79533
79579
|
/**
|
|
79534
79580
|
* Run a script asynchronously by its hash
|
|
79535
79581
|
* @param hash_ - Script hash in Windmill
|
|
79536
79582
|
* @param args - Arguments to pass to the script
|
|
79537
79583
|
* @param scheduledInSeconds - Schedule execution for a future time (in seconds)
|
|
79584
|
+
* @param tag - Override the worker tag the job runs on
|
|
79538
79585
|
* @returns Job ID of the created job
|
|
79539
79586
|
*/
|
|
79540
|
-
async runScriptByHashAsync(hash_: string, args: Record<string, any> | null = null, scheduledInSeconds: number | null = null): Promise<string>
|
|
79587
|
+
async runScriptByHashAsync(hash_: string, args: Record<string, any> | null = null, scheduledInSeconds: number | null = null, tag: string | null = null): Promise<string>
|
|
79541
79588
|
|
|
79542
79589
|
/**
|
|
79543
79590
|
* Run a flow asynchronously by its path
|
|
@@ -79545,9 +79592,10 @@ async runScriptByHashAsync(hash_: string, args: Record<string, any> | null = nul
|
|
|
79545
79592
|
* @param args - Arguments to pass to the flow
|
|
79546
79593
|
* @param scheduledInSeconds - Schedule execution for a future time (in seconds)
|
|
79547
79594
|
* @param doNotTrackInParent - If false, tracks state in parent job (only use when fully awaiting the job)
|
|
79595
|
+
* @param tag - Override the worker tag the job runs on
|
|
79548
79596
|
* @returns Job ID of the created job
|
|
79549
79597
|
*/
|
|
79550
|
-
async runFlowAsync(path: string | null, args: Record<string, any> | null, scheduledInSeconds: number | null = null, // can only be set to false if this the job will be fully await and not concurrent with any other job // as otherwise the child flow and its own child will store their state in the parent job which will // lead to incorrectness and failures doNotTrackInParent: boolean = true): Promise<string>
|
|
79598
|
+
async runFlowAsync(path: string | null, args: Record<string, any> | null, scheduledInSeconds: number | null = null, // can only be set to false if this the job will be fully await and not concurrent with any other job // as otherwise the child flow and its own child will store their state in the parent job which will // lead to incorrectness and failures doNotTrackInParent: boolean = true, tag: string | null = null): Promise<string>
|
|
79551
79599
|
|
|
79552
79600
|
/**
|
|
79553
79601
|
* Resolve a resource value in case the default value was picked because the input payload was undefined
|
|
@@ -80207,25 +80255,27 @@ async getRootJobId(jobId?: string): Promise<string>
|
|
|
80207
80255
|
/**
|
|
80208
80256
|
* @deprecated Use runScriptByPath or runScriptByHash instead
|
|
80209
80257
|
*/
|
|
80210
|
-
async runScript(path: string | null = null, hash_: string | null = null, args: Record<string, any> | null = null, verbose: boolean = false): Promise<any>
|
|
80258
|
+
async runScript(path: string | null = null, hash_: string | null = null, args: Record<string, any> | null = null, verbose: boolean = false, tag: string | null = null): Promise<any>
|
|
80211
80259
|
|
|
80212
80260
|
/**
|
|
80213
80261
|
* Run a script synchronously by its path and wait for the result
|
|
80214
80262
|
* @param path - Script path in Windmill
|
|
80215
80263
|
* @param args - Arguments to pass to the script
|
|
80216
80264
|
* @param verbose - Enable verbose logging
|
|
80265
|
+
* @param tag - Override the worker tag the job runs on
|
|
80217
80266
|
* @returns Script execution result
|
|
80218
80267
|
*/
|
|
80219
|
-
async runScriptByPath(path: string, args: Record<string, any> | null = null, verbose: boolean = false): Promise<any>
|
|
80268
|
+
async runScriptByPath(path: string, args: Record<string, any> | null = null, verbose: boolean = false, tag: string | null = null): Promise<any>
|
|
80220
80269
|
|
|
80221
80270
|
/**
|
|
80222
80271
|
* Run a script synchronously by its hash and wait for the result
|
|
80223
80272
|
* @param hash_ - Script hash in Windmill
|
|
80224
80273
|
* @param args - Arguments to pass to the script
|
|
80225
80274
|
* @param verbose - Enable verbose logging
|
|
80275
|
+
* @param tag - Override the worker tag the job runs on
|
|
80226
80276
|
* @returns Script execution result
|
|
80227
80277
|
*/
|
|
80228
|
-
async runScriptByHash(hash_: string, args: Record<string, any> | null = null, verbose: boolean = false): Promise<any>
|
|
80278
|
+
async runScriptByHash(hash_: string, args: Record<string, any> | null = null, verbose: boolean = false, tag: string | null = null): Promise<any>
|
|
80229
80279
|
|
|
80230
80280
|
/**
|
|
80231
80281
|
* Append a text to the result stream
|
|
@@ -80244,9 +80294,10 @@ async streamResult(stream: AsyncIterable<string>): Promise<void>
|
|
|
80244
80294
|
* @param path - Flow path in Windmill
|
|
80245
80295
|
* @param args - Arguments to pass to the flow
|
|
80246
80296
|
* @param verbose - Enable verbose logging
|
|
80297
|
+
* @param tag - Override the worker tag the job runs on
|
|
80247
80298
|
* @returns Flow execution result
|
|
80248
80299
|
*/
|
|
80249
|
-
async runFlow(path: string | null = null, args: Record<string, any> | null = null, verbose: boolean = false): Promise<any>
|
|
80300
|
+
async runFlow(path: string | null = null, args: Record<string, any> | null = null, verbose: boolean = false, tag: string | null = null): Promise<any>
|
|
80250
80301
|
|
|
80251
80302
|
/**
|
|
80252
80303
|
* Wait for a job to complete and return its result
|
|
@@ -80273,25 +80324,27 @@ async getResultMaybe(jobId: string): Promise<any>
|
|
|
80273
80324
|
/**
|
|
80274
80325
|
* @deprecated Use runScriptByPathAsync or runScriptByHashAsync instead
|
|
80275
80326
|
*/
|
|
80276
|
-
async runScriptAsync(path: string | null, hash_: string | null, args: Record<string, any> | null, scheduledInSeconds: number | null = null): Promise<string>
|
|
80327
|
+
async runScriptAsync(path: string | null, hash_: string | null, args: Record<string, any> | null, scheduledInSeconds: number | null = null, tag: string | null = null): Promise<string>
|
|
80277
80328
|
|
|
80278
80329
|
/**
|
|
80279
80330
|
* Run a script asynchronously by its path
|
|
80280
80331
|
* @param path - Script path in Windmill
|
|
80281
80332
|
* @param args - Arguments to pass to the script
|
|
80282
80333
|
* @param scheduledInSeconds - Schedule execution for a future time (in seconds)
|
|
80334
|
+
* @param tag - Override the worker tag the job runs on
|
|
80283
80335
|
* @returns Job ID of the created job
|
|
80284
80336
|
*/
|
|
80285
|
-
async runScriptByPathAsync(path: string, args: Record<string, any> | null = null, scheduledInSeconds: number | null = null): Promise<string>
|
|
80337
|
+
async runScriptByPathAsync(path: string, args: Record<string, any> | null = null, scheduledInSeconds: number | null = null, tag: string | null = null): Promise<string>
|
|
80286
80338
|
|
|
80287
80339
|
/**
|
|
80288
80340
|
* Run a script asynchronously by its hash
|
|
80289
80341
|
* @param hash_ - Script hash in Windmill
|
|
80290
80342
|
* @param args - Arguments to pass to the script
|
|
80291
80343
|
* @param scheduledInSeconds - Schedule execution for a future time (in seconds)
|
|
80344
|
+
* @param tag - Override the worker tag the job runs on
|
|
80292
80345
|
* @returns Job ID of the created job
|
|
80293
80346
|
*/
|
|
80294
|
-
async runScriptByHashAsync(hash_: string, args: Record<string, any> | null = null, scheduledInSeconds: number | null = null): Promise<string>
|
|
80347
|
+
async runScriptByHashAsync(hash_: string, args: Record<string, any> | null = null, scheduledInSeconds: number | null = null, tag: string | null = null): Promise<string>
|
|
80295
80348
|
|
|
80296
80349
|
/**
|
|
80297
80350
|
* Run a flow asynchronously by its path
|
|
@@ -80299,9 +80352,10 @@ async runScriptByHashAsync(hash_: string, args: Record<string, any> | null = nul
|
|
|
80299
80352
|
* @param args - Arguments to pass to the flow
|
|
80300
80353
|
* @param scheduledInSeconds - Schedule execution for a future time (in seconds)
|
|
80301
80354
|
* @param doNotTrackInParent - If false, tracks state in parent job (only use when fully awaiting the job)
|
|
80355
|
+
* @param tag - Override the worker tag the job runs on
|
|
80302
80356
|
* @returns Job ID of the created job
|
|
80303
80357
|
*/
|
|
80304
|
-
async runFlowAsync(path: string | null, args: Record<string, any> | null, scheduledInSeconds: number | null = null, // can only be set to false if this the job will be fully await and not concurrent with any other job // as otherwise the child flow and its own child will store their state in the parent job which will // lead to incorrectness and failures doNotTrackInParent: boolean = true): Promise<string>
|
|
80358
|
+
async runFlowAsync(path: string | null, args: Record<string, any> | null, scheduledInSeconds: number | null = null, // can only be set to false if this the job will be fully await and not concurrent with any other job // as otherwise the child flow and its own child will store their state in the parent job which will // lead to incorrectness and failures doNotTrackInParent: boolean = true, tag: string | null = null): Promise<string>
|
|
80305
80359
|
|
|
80306
80360
|
/**
|
|
80307
80361
|
* Resolve a resource value in case the default value was picked because the input payload was undefined
|
|
@@ -81053,25 +81107,27 @@ async getRootJobId(jobId?: string): Promise<string>
|
|
|
81053
81107
|
/**
|
|
81054
81108
|
* @deprecated Use runScriptByPath or runScriptByHash instead
|
|
81055
81109
|
*/
|
|
81056
|
-
async runScript(path: string | null = null, hash_: string | null = null, args: Record<string, any> | null = null, verbose: boolean = false): Promise<any>
|
|
81110
|
+
async runScript(path: string | null = null, hash_: string | null = null, args: Record<string, any> | null = null, verbose: boolean = false, tag: string | null = null): Promise<any>
|
|
81057
81111
|
|
|
81058
81112
|
/**
|
|
81059
81113
|
* Run a script synchronously by its path and wait for the result
|
|
81060
81114
|
* @param path - Script path in Windmill
|
|
81061
81115
|
* @param args - Arguments to pass to the script
|
|
81062
81116
|
* @param verbose - Enable verbose logging
|
|
81117
|
+
* @param tag - Override the worker tag the job runs on
|
|
81063
81118
|
* @returns Script execution result
|
|
81064
81119
|
*/
|
|
81065
|
-
async runScriptByPath(path: string, args: Record<string, any> | null = null, verbose: boolean = false): Promise<any>
|
|
81120
|
+
async runScriptByPath(path: string, args: Record<string, any> | null = null, verbose: boolean = false, tag: string | null = null): Promise<any>
|
|
81066
81121
|
|
|
81067
81122
|
/**
|
|
81068
81123
|
* Run a script synchronously by its hash and wait for the result
|
|
81069
81124
|
* @param hash_ - Script hash in Windmill
|
|
81070
81125
|
* @param args - Arguments to pass to the script
|
|
81071
81126
|
* @param verbose - Enable verbose logging
|
|
81127
|
+
* @param tag - Override the worker tag the job runs on
|
|
81072
81128
|
* @returns Script execution result
|
|
81073
81129
|
*/
|
|
81074
|
-
async runScriptByHash(hash_: string, args: Record<string, any> | null = null, verbose: boolean = false): Promise<any>
|
|
81130
|
+
async runScriptByHash(hash_: string, args: Record<string, any> | null = null, verbose: boolean = false, tag: string | null = null): Promise<any>
|
|
81075
81131
|
|
|
81076
81132
|
/**
|
|
81077
81133
|
* Append a text to the result stream
|
|
@@ -81090,9 +81146,10 @@ async streamResult(stream: AsyncIterable<string>): Promise<void>
|
|
|
81090
81146
|
* @param path - Flow path in Windmill
|
|
81091
81147
|
* @param args - Arguments to pass to the flow
|
|
81092
81148
|
* @param verbose - Enable verbose logging
|
|
81149
|
+
* @param tag - Override the worker tag the job runs on
|
|
81093
81150
|
* @returns Flow execution result
|
|
81094
81151
|
*/
|
|
81095
|
-
async runFlow(path: string | null = null, args: Record<string, any> | null = null, verbose: boolean = false): Promise<any>
|
|
81152
|
+
async runFlow(path: string | null = null, args: Record<string, any> | null = null, verbose: boolean = false, tag: string | null = null): Promise<any>
|
|
81096
81153
|
|
|
81097
81154
|
/**
|
|
81098
81155
|
* Wait for a job to complete and return its result
|
|
@@ -81119,25 +81176,27 @@ async getResultMaybe(jobId: string): Promise<any>
|
|
|
81119
81176
|
/**
|
|
81120
81177
|
* @deprecated Use runScriptByPathAsync or runScriptByHashAsync instead
|
|
81121
81178
|
*/
|
|
81122
|
-
async runScriptAsync(path: string | null, hash_: string | null, args: Record<string, any> | null, scheduledInSeconds: number | null = null): Promise<string>
|
|
81179
|
+
async runScriptAsync(path: string | null, hash_: string | null, args: Record<string, any> | null, scheduledInSeconds: number | null = null, tag: string | null = null): Promise<string>
|
|
81123
81180
|
|
|
81124
81181
|
/**
|
|
81125
81182
|
* Run a script asynchronously by its path
|
|
81126
81183
|
* @param path - Script path in Windmill
|
|
81127
81184
|
* @param args - Arguments to pass to the script
|
|
81128
81185
|
* @param scheduledInSeconds - Schedule execution for a future time (in seconds)
|
|
81186
|
+
* @param tag - Override the worker tag the job runs on
|
|
81129
81187
|
* @returns Job ID of the created job
|
|
81130
81188
|
*/
|
|
81131
|
-
async runScriptByPathAsync(path: string, args: Record<string, any> | null = null, scheduledInSeconds: number | null = null): Promise<string>
|
|
81189
|
+
async runScriptByPathAsync(path: string, args: Record<string, any> | null = null, scheduledInSeconds: number | null = null, tag: string | null = null): Promise<string>
|
|
81132
81190
|
|
|
81133
81191
|
/**
|
|
81134
81192
|
* Run a script asynchronously by its hash
|
|
81135
81193
|
* @param hash_ - Script hash in Windmill
|
|
81136
81194
|
* @param args - Arguments to pass to the script
|
|
81137
81195
|
* @param scheduledInSeconds - Schedule execution for a future time (in seconds)
|
|
81196
|
+
* @param tag - Override the worker tag the job runs on
|
|
81138
81197
|
* @returns Job ID of the created job
|
|
81139
81198
|
*/
|
|
81140
|
-
async runScriptByHashAsync(hash_: string, args: Record<string, any> | null = null, scheduledInSeconds: number | null = null): Promise<string>
|
|
81199
|
+
async runScriptByHashAsync(hash_: string, args: Record<string, any> | null = null, scheduledInSeconds: number | null = null, tag: string | null = null): Promise<string>
|
|
81141
81200
|
|
|
81142
81201
|
/**
|
|
81143
81202
|
* Run a flow asynchronously by its path
|
|
@@ -81145,9 +81204,10 @@ async runScriptByHashAsync(hash_: string, args: Record<string, any> | null = nul
|
|
|
81145
81204
|
* @param args - Arguments to pass to the flow
|
|
81146
81205
|
* @param scheduledInSeconds - Schedule execution for a future time (in seconds)
|
|
81147
81206
|
* @param doNotTrackInParent - If false, tracks state in parent job (only use when fully awaiting the job)
|
|
81207
|
+
* @param tag - Override the worker tag the job runs on
|
|
81148
81208
|
* @returns Job ID of the created job
|
|
81149
81209
|
*/
|
|
81150
|
-
async runFlowAsync(path: string | null, args: Record<string, any> | null, scheduledInSeconds: number | null = null, // can only be set to false if this the job will be fully await and not concurrent with any other job // as otherwise the child flow and its own child will store their state in the parent job which will // lead to incorrectness and failures doNotTrackInParent: boolean = true): Promise<string>
|
|
81210
|
+
async runFlowAsync(path: string | null, args: Record<string, any> | null, scheduledInSeconds: number | null = null, // can only be set to false if this the job will be fully await and not concurrent with any other job // as otherwise the child flow and its own child will store their state in the parent job which will // lead to incorrectness and failures doNotTrackInParent: boolean = true, tag: string | null = null): Promise<string>
|
|
81151
81211
|
|
|
81152
81212
|
/**
|
|
81153
81213
|
* Resolve a resource value in case the default value was picked because the input payload was undefined
|
|
@@ -82742,27 +82802,27 @@ def create_token(duration = dt.timedelta(days=1)) -> str
|
|
|
82742
82802
|
# Create a script job and return its job id.
|
|
82743
82803
|
#
|
|
82744
82804
|
# .. deprecated:: Use run_script_by_path_async or run_script_by_hash_async instead.
|
|
82745
|
-
def run_script_async(path: str = None, hash_: str = None, args: dict = None, scheduled_in_secs: int = None) -> str
|
|
82805
|
+
def run_script_async(path: str = None, hash_: str = None, args: dict = None, scheduled_in_secs: int = None, tag: str = None) -> str
|
|
82746
82806
|
|
|
82747
82807
|
# Create a script job by path and return its job id.
|
|
82748
|
-
def run_script_by_path_async(path: str, args: dict = None, scheduled_in_secs: int = None) -> str
|
|
82808
|
+
def run_script_by_path_async(path: str, args: dict = None, scheduled_in_secs: int = None, tag: str = None) -> str
|
|
82749
82809
|
|
|
82750
82810
|
# Create a script job by hash and return its job id.
|
|
82751
|
-
def run_script_by_hash_async(hash_: str, args: dict = None, scheduled_in_secs: int = None) -> str
|
|
82811
|
+
def run_script_by_hash_async(hash_: str, args: dict = None, scheduled_in_secs: int = None, tag: str = None) -> str
|
|
82752
82812
|
|
|
82753
82813
|
# Create a flow job and return its job id.
|
|
82754
|
-
def run_flow_async(path: str, args: dict = None, scheduled_in_secs: int = None, do_not_track_in_parent: bool = True) -> str
|
|
82814
|
+
def run_flow_async(path: str, args: dict = None, scheduled_in_secs: int = None, do_not_track_in_parent: bool = True, tag: str = None) -> str
|
|
82755
82815
|
|
|
82756
82816
|
# Run script synchronously and return its result.
|
|
82757
82817
|
#
|
|
82758
82818
|
# .. deprecated:: Use run_script_by_path or run_script_by_hash instead.
|
|
82759
|
-
def run_script(path: str = None, hash_: str = None, args: dict = None, timeout: dt.timedelta | int | float | None = None, verbose: bool = False, cleanup: bool = True, assert_result_is_not_none: bool = False) -> Any
|
|
82819
|
+
def run_script(path: str = None, hash_: str = None, args: dict = None, timeout: dt.timedelta | int | float | None = None, verbose: bool = False, cleanup: bool = True, assert_result_is_not_none: bool = False, tag: str = None) -> Any
|
|
82760
82820
|
|
|
82761
82821
|
# Run script by path synchronously and return its result.
|
|
82762
|
-
def run_script_by_path(path: str, args: dict = None, timeout: dt.timedelta | int | float | None = None, verbose: bool = False, cleanup: bool = True, assert_result_is_not_none: bool = False) -> Any
|
|
82822
|
+
def run_script_by_path(path: str, args: dict = None, timeout: dt.timedelta | int | float | None = None, verbose: bool = False, cleanup: bool = True, assert_result_is_not_none: bool = False, tag: str = None) -> Any
|
|
82763
82823
|
|
|
82764
82824
|
# Run script by hash synchronously and return its result.
|
|
82765
|
-
def run_script_by_hash(hash_: str, args: dict = None, timeout: dt.timedelta | int | float | None = None, verbose: bool = False, cleanup: bool = True, assert_result_is_not_none: bool = False) -> Any
|
|
82825
|
+
def run_script_by_hash(hash_: str, args: dict = None, timeout: dt.timedelta | int | float | None = None, verbose: bool = False, cleanup: bool = True, assert_result_is_not_none: bool = False, tag: str = None) -> Any
|
|
82766
82826
|
|
|
82767
82827
|
# Run a script on the current worker without creating a job.
|
|
82768
82828
|
#
|
|
@@ -83180,10 +83240,11 @@ def get_version() -> str
|
|
|
83180
83240
|
# assert_result_is_not_none: Raise exception if result is None
|
|
83181
83241
|
# cleanup: Register cleanup handler to cancel job on exit
|
|
83182
83242
|
# timeout: Maximum time to wait
|
|
83243
|
+
# tag: Override the worker tag the job runs on
|
|
83183
83244
|
#
|
|
83184
83245
|
# Returns:
|
|
83185
83246
|
# Script result
|
|
83186
|
-
def run_script_sync(hash: str, args: Dict[str, Any] = None, verbose: bool = False, assert_result_is_not_none: bool = True, cleanup: bool = True, timeout: dt.timedelta = None) -> Any
|
|
83247
|
+
def run_script_sync(hash: str, args: Dict[str, Any] = None, verbose: bool = False, assert_result_is_not_none: bool = True, cleanup: bool = True, timeout: dt.timedelta = None, tag: str = None) -> Any
|
|
83187
83248
|
|
|
83188
83249
|
# Run a script synchronously by path and return its result.
|
|
83189
83250
|
#
|
|
@@ -83194,10 +83255,11 @@ def run_script_sync(hash: str, args: Dict[str, Any] = None, verbose: bool = Fals
|
|
|
83194
83255
|
# assert_result_is_not_none: Raise exception if result is None
|
|
83195
83256
|
# cleanup: Register cleanup handler to cancel job on exit
|
|
83196
83257
|
# timeout: Maximum time to wait
|
|
83258
|
+
# tag: Override the worker tag the job runs on
|
|
83197
83259
|
#
|
|
83198
83260
|
# Returns:
|
|
83199
83261
|
# Script result
|
|
83200
|
-
def run_script_by_path_sync(path: str, args: Dict[str, Any] = None, verbose: bool = False, assert_result_is_not_none: bool = True, cleanup: bool = True, timeout: dt.timedelta = None) -> Any
|
|
83262
|
+
def run_script_by_path_sync(path: str, args: Dict[str, Any] = None, verbose: bool = False, assert_result_is_not_none: bool = True, cleanup: bool = True, timeout: dt.timedelta = None, tag: str = None) -> Any
|
|
83201
83263
|
|
|
83202
83264
|
# Convenient helpers that takes an S3 resource as input and returns the settings necessary to
|
|
83203
83265
|
# initiate an S3 connection from DuckDB
|