@trigger.dev/core 0.0.0-v3-trigger-dirs-20240422221109 → 0.0.0-v3-trigger-dirs-20240423123825
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/{consoleInterceptor-6WZo2qUS.d.ts → catalog-e2OUDZEa.d.mts} +368 -400
- package/dist/{consoleInterceptor-hjdjADX8.d.mts → catalog-ndN7py2b.d.ts} +368 -400
- package/dist/{messages-GvjBDSAA.d.mts → messages-AriaDDm0.d.mts} +439 -439
- package/dist/{messages-GvjBDSAA.d.ts → messages-AriaDDm0.d.ts} +439 -439
- package/dist/v3/dev/index.d.mts +1 -1
- package/dist/v3/dev/index.d.ts +1 -1
- package/dist/v3/index.d.mts +107 -321
- package/dist/v3/index.d.ts +107 -321
- package/dist/v3/index.js +2045 -2595
- package/dist/v3/index.js.map +1 -1
- package/dist/v3/index.mjs +2065 -2603
- package/dist/v3/index.mjs.map +1 -1
- package/dist/v3/otel/index.d.mts +34 -6
- package/dist/v3/otel/index.d.ts +34 -6
- package/dist/v3/otel/index.js +62 -38
- package/dist/v3/otel/index.js.map +1 -1
- package/dist/v3/otel/index.mjs +62 -38
- package/dist/v3/otel/index.mjs.map +1 -1
- package/dist/v3/prod/index.d.mts +2 -2
- package/dist/v3/prod/index.d.ts +2 -2
- package/dist/v3/prod/index.js.map +1 -1
- package/dist/v3/prod/index.mjs.map +1 -1
- package/dist/v3/workers/index.d.mts +57 -12
- package/dist/v3/workers/index.d.ts +57 -12
- package/dist/v3/workers/index.js +728 -124
- package/dist/v3/workers/index.js.map +1 -1
- package/dist/v3/workers/index.mjs +718 -125
- package/dist/v3/workers/index.mjs.map +1 -1
- package/package.json +3 -3
- package/dist/tracingSDK-XMTLzw35.d.mts +0 -35
- package/dist/tracingSDK-XMTLzw35.d.ts +0 -35
- package/dist/{manager-psJfQhBB.d.mts → manager-M9GLDnhJ.d.mts} +62 -62
- package/dist/{manager-psJfQhBB.d.ts → manager-M9GLDnhJ.d.ts} +62 -62
package/dist/v3/dev/index.d.mts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { R as RuntimeManager, T as TaskRunExecutionResult, B as BatchTaskRunExecutionResult, b as TaskRunContext, p as TaskRunExecution } from '../../manager-
|
|
1
|
+
import { R as RuntimeManager, T as TaskRunExecutionResult, B as BatchTaskRunExecutionResult, b as TaskRunContext, p as TaskRunExecution } from '../../manager-M9GLDnhJ.mjs';
|
|
2
2
|
import 'zod';
|
|
3
3
|
|
|
4
4
|
declare class DevRuntimeManager implements RuntimeManager {
|
package/dist/v3/dev/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { R as RuntimeManager, T as TaskRunExecutionResult, B as BatchTaskRunExecutionResult, b as TaskRunContext, p as TaskRunExecution } from '../../manager-
|
|
1
|
+
import { R as RuntimeManager, T as TaskRunExecutionResult, B as BatchTaskRunExecutionResult, b as TaskRunContext, p as TaskRunExecution } from '../../manager-M9GLDnhJ.js';
|
|
2
2
|
import 'zod';
|
|
3
3
|
|
|
4
4
|
declare class DevRuntimeManager implements RuntimeManager {
|
package/dist/v3/index.d.mts
CHANGED
|
@@ -1,21 +1,15 @@
|
|
|
1
|
-
import * as zod from 'zod';
|
|
2
1
|
import { z } from 'zod';
|
|
3
|
-
import { T as TaskRunExecutionResult, B as BatchTaskRunExecutionResult, a as TaskRunError, b as TaskRunContext, R as RuntimeManager } from '../manager-
|
|
4
|
-
export { h as TaskRun, c as TaskRunBuiltInError, d as TaskRunCustomErrorObject, f as TaskRunErrorCodes, p as TaskRunExecution, j as TaskRunExecutionAttempt, o as TaskRunExecutionBatch, k as TaskRunExecutionEnvironment, l as TaskRunExecutionOrganization, m as TaskRunExecutionProject, n as TaskRunExecutionQueue, q as TaskRunExecutionRetry, i as TaskRunExecutionTask, r as TaskRunFailedExecutionResult, g as TaskRunInternalError, e as TaskRunStringError, s as TaskRunSuccessfulExecutionResult } from '../manager-
|
|
5
|
-
import {
|
|
6
|
-
export {
|
|
7
|
-
import {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
import { SeverityNumber } from '@opentelemetry/api-logs';
|
|
2
|
+
import { T as TaskRunExecutionResult, B as BatchTaskRunExecutionResult, a as TaskRunError, b as TaskRunContext, R as RuntimeManager } from '../manager-M9GLDnhJ.mjs';
|
|
3
|
+
export { h as TaskRun, c as TaskRunBuiltInError, d as TaskRunCustomErrorObject, f as TaskRunErrorCodes, p as TaskRunExecution, j as TaskRunExecutionAttempt, o as TaskRunExecutionBatch, k as TaskRunExecutionEnvironment, l as TaskRunExecutionOrganization, m as TaskRunExecutionProject, n as TaskRunExecutionQueue, q as TaskRunExecutionRetry, i as TaskRunExecutionTask, r as TaskRunFailedExecutionResult, g as TaskRunInternalError, e as TaskRunStringError, s as TaskRunSuccessfulExecutionResult } from '../manager-M9GLDnhJ.mjs';
|
|
4
|
+
import { P as Prettify, C as Clock, a as ClockTime, T as TaskLogger, b as TaskCatalog, c as TaskMetadataWithFunctions, d as TriggerTracer } from '../catalog-e2OUDZEa.mjs';
|
|
5
|
+
export { l as ClientToSharedQueueMessages, g as Config, r as Context, j as CoordinatorToPlatformMessages, n as CoordinatorToProdWorkerMessages, v as HandleErrorArgs, H as HandleErrorFnParams, w as HandleErrorFunction, t as HandleErrorModificationOptions, u as HandleErrorResult, q as InitFnParams, I as InitOutput, L as LogLevel, M as MiddlewareFnParams, k as PlatformToCoordinatorMessages, i as PlatformToProviderMessages, e as PostStartCauses, f as PreStopCauses, o as ProdWorkerSocketData, m as ProdWorkerToCoordinatorMessages, y as ProjectConfig, h as ProviderToPlatformMessages, x as RequireKeys, R as ResolvedConfig, p as RunFnParams, S as SharedQueueToClientMessages, s as SuccessFnParams, W as WaitReason } from '../catalog-e2OUDZEa.mjs';
|
|
6
|
+
import { Attributes, Span } from '@opentelemetry/api';
|
|
7
|
+
import { B as BackgroundWorkerProperties, T as TaskFileMetadata, a as TaskMetadataWithFilePath, R as RetryOptions } from '../messages-AriaDDm0.mjs';
|
|
8
|
+
export { g as BackgroundWorkerClientMessages, f as BackgroundWorkerServerMessages, E as EnvironmentType, F as FixedWindowRateLimit, c as Machine, M as MachineCpu, b as MachineMemory, m as ProdChildToWorkerMessages, P as ProdTaskRunExecution, e as ProdTaskRunExecutionPayload, n as ProdWorkerToChildMessages, Q as QueueOptions, i as RateLimitOptions, S as SlidingWindowRateLimit, j as TaskMetadata, k as TaskMetadataFailedToParseData, d as TaskRunExecutionPayload, U as UncaughtExceptionMessage, l as childToWorkerMessages, h as clientWebsocketMessages, s as serverWebsocketMessages, w as workerToChildMessages } from '../messages-AriaDDm0.mjs';
|
|
11
9
|
import { Unit } from 'humanize-duration';
|
|
12
10
|
export { e as eventFilterMatches } from '../eventFilterMatches-2kHImluE.mjs';
|
|
13
|
-
|
|
14
|
-
export { a as TracingDiagnosticLogLevel, T as TracingSDK } from '../tracingSDK-XMTLzw35.mjs';
|
|
11
|
+
import '@opentelemetry/api-logs';
|
|
15
12
|
import '@opentelemetry/instrumentation';
|
|
16
|
-
import '@opentelemetry/sdk-trace-base';
|
|
17
|
-
import '@opentelemetry/resources';
|
|
18
|
-
import '@opentelemetry/sdk-logs';
|
|
19
13
|
|
|
20
14
|
declare const CreateAuthorizationCodeResponseSchema: z.ZodObject<{
|
|
21
15
|
url: z.ZodString;
|
|
@@ -522,8 +516,8 @@ declare const CreateBackgroundWorkerRequestBody: z.ZodObject<{
|
|
|
522
516
|
triggerSource?: string | undefined;
|
|
523
517
|
}>, "many">;
|
|
524
518
|
}, "strip", z.ZodTypeAny, {
|
|
525
|
-
packageVersion: string;
|
|
526
519
|
contentHash: string;
|
|
520
|
+
packageVersion: string;
|
|
527
521
|
tasks: {
|
|
528
522
|
id: string;
|
|
529
523
|
filePath: string;
|
|
@@ -581,8 +575,8 @@ declare const CreateBackgroundWorkerRequestBody: z.ZodObject<{
|
|
|
581
575
|
}[];
|
|
582
576
|
cliPackageVersion?: string | undefined;
|
|
583
577
|
}, {
|
|
584
|
-
packageVersion: string;
|
|
585
578
|
contentHash: string;
|
|
579
|
+
packageVersion: string;
|
|
586
580
|
tasks: {
|
|
587
581
|
id: string;
|
|
588
582
|
filePath: string;
|
|
@@ -642,8 +636,8 @@ declare const CreateBackgroundWorkerRequestBody: z.ZodObject<{
|
|
|
642
636
|
}>;
|
|
643
637
|
}, "strip", z.ZodTypeAny, {
|
|
644
638
|
metadata: {
|
|
645
|
-
packageVersion: string;
|
|
646
639
|
contentHash: string;
|
|
640
|
+
packageVersion: string;
|
|
647
641
|
tasks: {
|
|
648
642
|
id: string;
|
|
649
643
|
filePath: string;
|
|
@@ -704,8 +698,8 @@ declare const CreateBackgroundWorkerRequestBody: z.ZodObject<{
|
|
|
704
698
|
localOnly: boolean;
|
|
705
699
|
}, {
|
|
706
700
|
metadata: {
|
|
707
|
-
packageVersion: string;
|
|
708
701
|
contentHash: string;
|
|
702
|
+
packageVersion: string;
|
|
709
703
|
tasks: {
|
|
710
704
|
id: string;
|
|
711
705
|
filePath: string;
|
|
@@ -1696,19 +1690,19 @@ declare const GetBatchResponseBody: z.ZodObject<{
|
|
|
1696
1690
|
taskRunId: string;
|
|
1697
1691
|
}>, "many">;
|
|
1698
1692
|
}, "strip", z.ZodTypeAny, {
|
|
1693
|
+
id: string;
|
|
1699
1694
|
items: {
|
|
1700
1695
|
status: "PENDING" | "CANCELED" | "COMPLETED" | "FAILED";
|
|
1701
1696
|
id: string;
|
|
1702
1697
|
taskRunId: string;
|
|
1703
1698
|
}[];
|
|
1704
|
-
id: string;
|
|
1705
1699
|
}, {
|
|
1700
|
+
id: string;
|
|
1706
1701
|
items: {
|
|
1707
1702
|
status: "PENDING" | "CANCELED" | "COMPLETED" | "FAILED";
|
|
1708
1703
|
id: string;
|
|
1709
1704
|
taskRunId: string;
|
|
1710
1705
|
}[];
|
|
1711
|
-
id: string;
|
|
1712
1706
|
}>;
|
|
1713
1707
|
type GetBatchResponseBody = z.infer<typeof GetBatchResponseBody>;
|
|
1714
1708
|
declare const GetEnvironmentVariablesResponseBody: z.ZodObject<{
|
|
@@ -1814,12 +1808,12 @@ declare const DeploymentErrorData: z.ZodObject<{
|
|
|
1814
1808
|
message: z.ZodString;
|
|
1815
1809
|
stack: z.ZodOptional<z.ZodString>;
|
|
1816
1810
|
}, "strip", z.ZodTypeAny, {
|
|
1817
|
-
name: string;
|
|
1818
1811
|
message: string;
|
|
1812
|
+
name: string;
|
|
1819
1813
|
stack?: string | undefined;
|
|
1820
1814
|
}, {
|
|
1821
|
-
name: string;
|
|
1822
1815
|
message: string;
|
|
1816
|
+
name: string;
|
|
1823
1817
|
stack?: string | undefined;
|
|
1824
1818
|
}>;
|
|
1825
1819
|
declare const GetDeploymentResponseBody: z.ZodObject<{
|
|
@@ -1834,12 +1828,12 @@ declare const GetDeploymentResponseBody: z.ZodObject<{
|
|
|
1834
1828
|
message: z.ZodString;
|
|
1835
1829
|
stack: z.ZodOptional<z.ZodString>;
|
|
1836
1830
|
}, "strip", z.ZodTypeAny, {
|
|
1837
|
-
name: string;
|
|
1838
1831
|
message: string;
|
|
1832
|
+
name: string;
|
|
1839
1833
|
stack?: string | undefined;
|
|
1840
1834
|
}, {
|
|
1841
|
-
name: string;
|
|
1842
1835
|
message: string;
|
|
1836
|
+
name: string;
|
|
1843
1837
|
stack?: string | undefined;
|
|
1844
1838
|
}>>>;
|
|
1845
1839
|
worker: z.ZodOptional<z.ZodObject<{
|
|
@@ -1888,8 +1882,8 @@ declare const GetDeploymentResponseBody: z.ZodObject<{
|
|
|
1888
1882
|
shortCode: string;
|
|
1889
1883
|
imageReference?: string | undefined;
|
|
1890
1884
|
errorData?: {
|
|
1891
|
-
name: string;
|
|
1892
1885
|
message: string;
|
|
1886
|
+
name: string;
|
|
1893
1887
|
stack?: string | undefined;
|
|
1894
1888
|
} | null | undefined;
|
|
1895
1889
|
worker?: {
|
|
@@ -1910,8 +1904,8 @@ declare const GetDeploymentResponseBody: z.ZodObject<{
|
|
|
1910
1904
|
shortCode: string;
|
|
1911
1905
|
imageReference?: string | undefined;
|
|
1912
1906
|
errorData?: {
|
|
1913
|
-
name: string;
|
|
1914
1907
|
message: string;
|
|
1908
|
+
name: string;
|
|
1915
1909
|
stack?: string | undefined;
|
|
1916
1910
|
} | null | undefined;
|
|
1917
1911
|
worker?: {
|
|
@@ -2951,8 +2945,8 @@ declare const BackgroundWorkerMetadata: z.ZodObject<{
|
|
|
2951
2945
|
triggerSource?: string | undefined;
|
|
2952
2946
|
}>, "many">;
|
|
2953
2947
|
}, "strip", z.ZodTypeAny, {
|
|
2954
|
-
packageVersion: string;
|
|
2955
2948
|
contentHash: string;
|
|
2949
|
+
packageVersion: string;
|
|
2956
2950
|
tasks: {
|
|
2957
2951
|
id: string;
|
|
2958
2952
|
filePath: string;
|
|
@@ -3010,8 +3004,8 @@ declare const BackgroundWorkerMetadata: z.ZodObject<{
|
|
|
3010
3004
|
}[];
|
|
3011
3005
|
cliPackageVersion?: string | undefined;
|
|
3012
3006
|
}, {
|
|
3013
|
-
packageVersion: string;
|
|
3014
3007
|
contentHash: string;
|
|
3008
|
+
packageVersion: string;
|
|
3015
3009
|
tasks: {
|
|
3016
3010
|
id: string;
|
|
3017
3011
|
filePath: string;
|
|
@@ -4119,21 +4113,6 @@ declare class ApiClientManager {
|
|
|
4119
4113
|
}
|
|
4120
4114
|
declare const apiClientManager: ApiClientManager;
|
|
4121
4115
|
|
|
4122
|
-
declare function parseError(error: unknown): TaskRunError;
|
|
4123
|
-
declare function createErrorTaskError(error: TaskRunError): any;
|
|
4124
|
-
declare function correctErrorStackTrace(stackTrace: string, projectDir?: string, options?: {
|
|
4125
|
-
removeFirstLine?: boolean;
|
|
4126
|
-
}): string;
|
|
4127
|
-
declare function groupTaskMetadataIssuesByTask(tasks: any, issues: z.ZodIssue[]): Record<number, {
|
|
4128
|
-
id: any;
|
|
4129
|
-
exportName: string;
|
|
4130
|
-
filePath: string;
|
|
4131
|
-
issues: Array<{
|
|
4132
|
-
message: string;
|
|
4133
|
-
path?: string;
|
|
4134
|
-
}>;
|
|
4135
|
-
}>;
|
|
4136
|
-
|
|
4137
4116
|
type APIHeaders = Record<string, string | null | undefined>;
|
|
4138
4117
|
declare class APIError extends Error {
|
|
4139
4118
|
readonly status: number | undefined;
|
|
@@ -4177,28 +4156,44 @@ declare class RateLimitError extends APIError {
|
|
|
4177
4156
|
declare class InternalServerError extends APIError {
|
|
4178
4157
|
}
|
|
4179
4158
|
|
|
4180
|
-
declare class
|
|
4159
|
+
declare class ClockAPI {
|
|
4181
4160
|
#private;
|
|
4182
4161
|
private static _instance?;
|
|
4183
4162
|
private constructor();
|
|
4184
|
-
static getInstance():
|
|
4185
|
-
|
|
4186
|
-
|
|
4187
|
-
|
|
4188
|
-
id: string;
|
|
4189
|
-
ctx: TaskRunContext;
|
|
4190
|
-
}): Promise<TaskRunExecutionResult>;
|
|
4191
|
-
waitForBatch(params: {
|
|
4192
|
-
id: string;
|
|
4193
|
-
runs: string[];
|
|
4194
|
-
ctx: TaskRunContext;
|
|
4195
|
-
}): Promise<BatchTaskRunExecutionResult>;
|
|
4196
|
-
setGlobalRuntimeManager(runtimeManager: RuntimeManager): boolean;
|
|
4197
|
-
disable(): void;
|
|
4163
|
+
static getInstance(): ClockAPI;
|
|
4164
|
+
setGlobalClock(clock: Clock): boolean;
|
|
4165
|
+
preciseNow(): ClockTime;
|
|
4166
|
+
reset(): void;
|
|
4198
4167
|
}
|
|
4199
4168
|
|
|
4200
|
-
/** Entrypoint for
|
|
4201
|
-
declare const
|
|
4169
|
+
/** Entrypoint for clock API */
|
|
4170
|
+
declare const clock: ClockAPI;
|
|
4171
|
+
|
|
4172
|
+
declare function parseError(error: unknown): TaskRunError;
|
|
4173
|
+
declare function createErrorTaskError(error: TaskRunError): any;
|
|
4174
|
+
declare function correctErrorStackTrace(stackTrace: string, projectDir?: string, options?: {
|
|
4175
|
+
removeFirstLine?: boolean;
|
|
4176
|
+
}): string;
|
|
4177
|
+
declare function groupTaskMetadataIssuesByTask(tasks: any, issues: z.ZodIssue[]): Record<number, {
|
|
4178
|
+
id: any;
|
|
4179
|
+
exportName: string;
|
|
4180
|
+
filePath: string;
|
|
4181
|
+
issues: Array<{
|
|
4182
|
+
message: string;
|
|
4183
|
+
path?: string;
|
|
4184
|
+
}>;
|
|
4185
|
+
}>;
|
|
4186
|
+
|
|
4187
|
+
declare const OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT = 256;
|
|
4188
|
+
declare const OTEL_LOG_ATTRIBUTE_COUNT_LIMIT = 256;
|
|
4189
|
+
declare const OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT = 1028;
|
|
4190
|
+
declare const OTEL_LOG_ATTRIBUTE_VALUE_LENGTH_LIMIT = 1028;
|
|
4191
|
+
declare const OTEL_SPAN_EVENT_COUNT_LIMIT = 10;
|
|
4192
|
+
declare const OTEL_LINK_COUNT_LIMIT = 2;
|
|
4193
|
+
declare const OTEL_ATTRIBUTE_PER_LINK_COUNT_LIMIT = 10;
|
|
4194
|
+
declare const OTEL_ATTRIBUTE_PER_EVENT_COUNT_LIMIT = 10;
|
|
4195
|
+
declare const OFFLOAD_IO_PACKET_LENGTH_LIMIT: number;
|
|
4196
|
+
declare function imposeAttributeLimits(attributes: Attributes): Attributes;
|
|
4202
4197
|
|
|
4203
4198
|
declare class LoggerAPI implements TaskLogger {
|
|
4204
4199
|
#private;
|
|
@@ -4218,56 +4213,51 @@ declare class LoggerAPI implements TaskLogger {
|
|
|
4218
4213
|
/** Entrypoint for logger API */
|
|
4219
4214
|
declare const logger: LoggerAPI;
|
|
4220
4215
|
|
|
4221
|
-
declare class
|
|
4216
|
+
declare class RuntimeAPI {
|
|
4222
4217
|
#private;
|
|
4223
4218
|
private static _instance?;
|
|
4224
4219
|
private constructor();
|
|
4225
|
-
static getInstance():
|
|
4226
|
-
|
|
4227
|
-
|
|
4228
|
-
|
|
4220
|
+
static getInstance(): RuntimeAPI;
|
|
4221
|
+
waitForDuration(ms: number): Promise<void>;
|
|
4222
|
+
waitUntil(date: Date): Promise<void>;
|
|
4223
|
+
waitForTask(params: {
|
|
4224
|
+
id: string;
|
|
4225
|
+
ctx: TaskRunContext;
|
|
4226
|
+
}): Promise<TaskRunExecutionResult>;
|
|
4227
|
+
waitForBatch(params: {
|
|
4228
|
+
id: string;
|
|
4229
|
+
runs: string[];
|
|
4230
|
+
ctx: TaskRunContext;
|
|
4231
|
+
}): Promise<BatchTaskRunExecutionResult>;
|
|
4232
|
+
setGlobalRuntimeManager(runtimeManager: RuntimeManager): boolean;
|
|
4233
|
+
disable(): void;
|
|
4229
4234
|
}
|
|
4230
4235
|
|
|
4231
|
-
/** Entrypoint for
|
|
4232
|
-
declare const
|
|
4236
|
+
/** Entrypoint for runtime API */
|
|
4237
|
+
declare const runtime: RuntimeAPI;
|
|
4233
4238
|
|
|
4234
|
-
|
|
4235
|
-
|
|
4236
|
-
|
|
4237
|
-
|
|
4238
|
-
getAllTaskMetadata(): Array<TaskMetadataWithFilePath>;
|
|
4239
|
-
getTaskMetadata(id: string): TaskMetadataWithFilePath | undefined;
|
|
4240
|
-
getTask(id: string): TaskMetadataWithFunctions | undefined;
|
|
4241
|
-
}
|
|
4239
|
+
type TaskContext = {
|
|
4240
|
+
ctx: TaskRunContext;
|
|
4241
|
+
worker: BackgroundWorkerProperties;
|
|
4242
|
+
};
|
|
4242
4243
|
|
|
4243
|
-
declare class
|
|
4244
|
+
declare class TaskContextAPI {
|
|
4244
4245
|
#private;
|
|
4245
4246
|
private static _instance?;
|
|
4246
4247
|
private constructor();
|
|
4247
|
-
static getInstance():
|
|
4248
|
-
|
|
4248
|
+
static getInstance(): TaskContextAPI;
|
|
4249
|
+
get isInsideTask(): boolean;
|
|
4250
|
+
get ctx(): TaskRunContext | undefined;
|
|
4251
|
+
get worker(): BackgroundWorkerProperties | undefined;
|
|
4252
|
+
get attributes(): Attributes;
|
|
4253
|
+
get workerAttributes(): Attributes;
|
|
4254
|
+
get contextAttributes(): Attributes;
|
|
4249
4255
|
disable(): void;
|
|
4250
|
-
|
|
4251
|
-
updateTaskMetadata(id: string, updates: Partial<TaskMetadataWithFunctions>): void;
|
|
4252
|
-
registerTaskFileMetadata(id: string, metadata: TaskFileMetadata): void;
|
|
4253
|
-
getAllTaskMetadata(): Array<TaskMetadataWithFilePath>;
|
|
4254
|
-
getTaskMetadata(id: string): TaskMetadataWithFilePath | undefined;
|
|
4255
|
-
getTask(id: string): TaskMetadataWithFunctions | undefined;
|
|
4256
|
+
setGlobalTaskContext(taskContext: TaskContext): boolean;
|
|
4256
4257
|
}
|
|
4257
4258
|
|
|
4258
|
-
/** Entrypoint for
|
|
4259
|
-
declare const
|
|
4260
|
-
|
|
4261
|
-
declare const OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT = 256;
|
|
4262
|
-
declare const OTEL_LOG_ATTRIBUTE_COUNT_LIMIT = 256;
|
|
4263
|
-
declare const OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT = 1028;
|
|
4264
|
-
declare const OTEL_LOG_ATTRIBUTE_VALUE_LENGTH_LIMIT = 1028;
|
|
4265
|
-
declare const OTEL_SPAN_EVENT_COUNT_LIMIT = 10;
|
|
4266
|
-
declare const OTEL_LINK_COUNT_LIMIT = 2;
|
|
4267
|
-
declare const OTEL_ATTRIBUTE_PER_LINK_COUNT_LIMIT = 10;
|
|
4268
|
-
declare const OTEL_ATTRIBUTE_PER_EVENT_COUNT_LIMIT = 10;
|
|
4269
|
-
declare const OFFLOAD_IO_PACKET_LENGTH_LIMIT: number;
|
|
4270
|
-
declare function imposeAttributeLimits(attributes: Attributes): Attributes;
|
|
4259
|
+
/** Entrypoint for logger API */
|
|
4260
|
+
declare const taskContext: TaskContextAPI;
|
|
4271
4261
|
|
|
4272
4262
|
declare const SemanticInternalAttributes: {
|
|
4273
4263
|
ENVIRONMENT_ID: string;
|
|
@@ -4315,7 +4305,23 @@ declare const SemanticInternalAttributes: {
|
|
|
4315
4305
|
IDEMPOTENCY_KEY: string;
|
|
4316
4306
|
};
|
|
4317
4307
|
|
|
4318
|
-
declare
|
|
4308
|
+
declare class TaskCatalogAPI {
|
|
4309
|
+
#private;
|
|
4310
|
+
private static _instance?;
|
|
4311
|
+
private constructor();
|
|
4312
|
+
static getInstance(): TaskCatalogAPI;
|
|
4313
|
+
setGlobalTaskCatalog(taskCatalog: TaskCatalog): boolean;
|
|
4314
|
+
disable(): void;
|
|
4315
|
+
registerTaskMetadata(task: TaskMetadataWithFunctions): void;
|
|
4316
|
+
updateTaskMetadata(id: string, updates: Partial<TaskMetadataWithFunctions>): void;
|
|
4317
|
+
registerTaskFileMetadata(id: string, metadata: TaskFileMetadata): void;
|
|
4318
|
+
getAllTaskMetadata(): Array<TaskMetadataWithFilePath>;
|
|
4319
|
+
getTaskMetadata(id: string): TaskMetadataWithFilePath | undefined;
|
|
4320
|
+
getTask(id: string): TaskMetadataWithFunctions | undefined;
|
|
4321
|
+
}
|
|
4322
|
+
|
|
4323
|
+
/** Entrypoint for runtime API */
|
|
4324
|
+
declare const taskCatalog: TaskCatalogAPI;
|
|
4319
4325
|
|
|
4320
4326
|
type DurationOptions = {
|
|
4321
4327
|
style?: "long" | "short";
|
|
@@ -4329,12 +4335,12 @@ declare function formatDurationNanoseconds(nanoseconds: number, options?: Durati
|
|
|
4329
4335
|
declare function formatDurationMilliseconds(milliseconds: number, options?: DurationOptions): string;
|
|
4330
4336
|
declare function formatDurationInDays(milliseconds: number): string;
|
|
4331
4337
|
|
|
4332
|
-
declare function getEnvVar(name: string): string | undefined;
|
|
4333
|
-
|
|
4334
4338
|
declare function flattenAttributes(obj: Record<string, unknown> | Array<unknown> | string | boolean | number | null | undefined, prefix?: string): Attributes;
|
|
4335
4339
|
declare function unflattenAttributes(obj: Attributes): Record<string, unknown>;
|
|
4336
4340
|
declare function primitiveValueOrflattenedAttributes(obj: Record<string, unknown> | Array<unknown> | string | boolean | number | undefined, prefix: string | undefined): Attributes | string | number | boolean | undefined;
|
|
4337
4341
|
|
|
4342
|
+
declare function omit<T extends Record<string, any>, K extends keyof T>(obj: T, ...keys: K[]): Omit<T, K>;
|
|
4343
|
+
|
|
4338
4344
|
declare const defaultRetryOptions: {
|
|
4339
4345
|
maxAttempts: number;
|
|
4340
4346
|
factor: number;
|
|
@@ -4379,8 +4385,6 @@ declare function calculateResetAt(resets: string | undefined | null, format: "un
|
|
|
4379
4385
|
|
|
4380
4386
|
declare function accessoryAttributes(accessory: Accessory): Attributes;
|
|
4381
4387
|
|
|
4382
|
-
declare function omit<T extends Record<string, any>, K extends keyof T>(obj: T, ...keys: K[]): Omit<T, K>;
|
|
4383
|
-
|
|
4384
4388
|
declare function detectDependencyVersion(dependency: string): string | undefined;
|
|
4385
4389
|
|
|
4386
4390
|
type IOPacket = {
|
|
@@ -4399,222 +4403,4 @@ declare function createPacketAttributes(packet: IOPacket, dataKey: string, dataT
|
|
|
4399
4403
|
declare function createPacketAttributesAsJson(data: any, dataType: string): Promise<Attributes>;
|
|
4400
4404
|
declare function prettyPrintPacket(rawData: any, dataType?: string): Promise<string>;
|
|
4401
4405
|
|
|
4402
|
-
|
|
4403
|
-
private _taskMetadata;
|
|
4404
|
-
private _taskFunctions;
|
|
4405
|
-
private _taskFileMetadata;
|
|
4406
|
-
registerTaskMetadata(task: TaskMetadataWithFunctions): void;
|
|
4407
|
-
updateTaskMetadata(id: string, updates: Partial<TaskMetadataWithFunctions>): void;
|
|
4408
|
-
registerTaskFileMetadata(id: string, metadata: TaskFileMetadata): void;
|
|
4409
|
-
getAllTaskMetadata(): Array<TaskMetadataWithFilePath>;
|
|
4410
|
-
getTaskMetadata(id: string): TaskMetadataWithFilePath | undefined;
|
|
4411
|
-
getTask(id: string): TaskMetadataWithFunctions | undefined;
|
|
4412
|
-
disable(): void;
|
|
4413
|
-
}
|
|
4414
|
-
|
|
4415
|
-
declare function parseTriggerTaskRequestBody(body: unknown): zod.SafeParseReturnType<{
|
|
4416
|
-
payload?: any;
|
|
4417
|
-
context?: any;
|
|
4418
|
-
options?: {
|
|
4419
|
-
dependentAttempt?: string | undefined;
|
|
4420
|
-
dependentBatch?: string | undefined;
|
|
4421
|
-
lockToVersion?: string | undefined;
|
|
4422
|
-
queue?: {
|
|
4423
|
-
name?: string | undefined;
|
|
4424
|
-
concurrencyLimit?: number | undefined;
|
|
4425
|
-
rateLimit?: {
|
|
4426
|
-
type: "fixed-window";
|
|
4427
|
-
limit: number;
|
|
4428
|
-
window: ({
|
|
4429
|
-
seconds: number;
|
|
4430
|
-
} | {
|
|
4431
|
-
minutes: number;
|
|
4432
|
-
} | {
|
|
4433
|
-
hours: number;
|
|
4434
|
-
}) & ({
|
|
4435
|
-
seconds: number;
|
|
4436
|
-
} | {
|
|
4437
|
-
minutes: number;
|
|
4438
|
-
} | {
|
|
4439
|
-
hours: number;
|
|
4440
|
-
} | undefined);
|
|
4441
|
-
} | {
|
|
4442
|
-
type: "sliding-window";
|
|
4443
|
-
limit: number;
|
|
4444
|
-
window: ({
|
|
4445
|
-
seconds: number;
|
|
4446
|
-
} | {
|
|
4447
|
-
minutes: number;
|
|
4448
|
-
} | {
|
|
4449
|
-
hours: number;
|
|
4450
|
-
}) & ({
|
|
4451
|
-
seconds: number;
|
|
4452
|
-
} | {
|
|
4453
|
-
minutes: number;
|
|
4454
|
-
} | {
|
|
4455
|
-
hours: number;
|
|
4456
|
-
} | undefined);
|
|
4457
|
-
} | undefined;
|
|
4458
|
-
} | undefined;
|
|
4459
|
-
concurrencyKey?: string | undefined;
|
|
4460
|
-
idempotencyKey?: string | undefined;
|
|
4461
|
-
test?: boolean | undefined;
|
|
4462
|
-
payloadType?: string | undefined;
|
|
4463
|
-
} | undefined;
|
|
4464
|
-
}, {
|
|
4465
|
-
payload?: any;
|
|
4466
|
-
context?: any;
|
|
4467
|
-
options?: {
|
|
4468
|
-
dependentAttempt?: string | undefined;
|
|
4469
|
-
dependentBatch?: string | undefined;
|
|
4470
|
-
lockToVersion?: string | undefined;
|
|
4471
|
-
queue?: {
|
|
4472
|
-
name?: string | undefined;
|
|
4473
|
-
concurrencyLimit?: number | undefined;
|
|
4474
|
-
rateLimit?: {
|
|
4475
|
-
type: "fixed-window";
|
|
4476
|
-
limit: number;
|
|
4477
|
-
window: ({
|
|
4478
|
-
seconds: number;
|
|
4479
|
-
} | {
|
|
4480
|
-
minutes: number;
|
|
4481
|
-
} | {
|
|
4482
|
-
hours: number;
|
|
4483
|
-
}) & ({
|
|
4484
|
-
seconds: number;
|
|
4485
|
-
} | {
|
|
4486
|
-
minutes: number;
|
|
4487
|
-
} | {
|
|
4488
|
-
hours: number;
|
|
4489
|
-
} | undefined);
|
|
4490
|
-
} | {
|
|
4491
|
-
type: "sliding-window";
|
|
4492
|
-
limit: number;
|
|
4493
|
-
window: ({
|
|
4494
|
-
seconds: number;
|
|
4495
|
-
} | {
|
|
4496
|
-
minutes: number;
|
|
4497
|
-
} | {
|
|
4498
|
-
hours: number;
|
|
4499
|
-
}) & ({
|
|
4500
|
-
seconds: number;
|
|
4501
|
-
} | {
|
|
4502
|
-
minutes: number;
|
|
4503
|
-
} | {
|
|
4504
|
-
hours: number;
|
|
4505
|
-
} | undefined);
|
|
4506
|
-
} | undefined;
|
|
4507
|
-
} | undefined;
|
|
4508
|
-
concurrencyKey?: string | undefined;
|
|
4509
|
-
idempotencyKey?: string | undefined;
|
|
4510
|
-
test?: boolean | undefined;
|
|
4511
|
-
payloadType?: string | undefined;
|
|
4512
|
-
} | undefined;
|
|
4513
|
-
}>;
|
|
4514
|
-
declare function parseBatchTriggerTaskRequestBody(body: unknown): zod.SafeParseReturnType<{
|
|
4515
|
-
items: {
|
|
4516
|
-
payload?: any;
|
|
4517
|
-
context?: any;
|
|
4518
|
-
options?: {
|
|
4519
|
-
dependentAttempt?: string | undefined;
|
|
4520
|
-
dependentBatch?: string | undefined;
|
|
4521
|
-
lockToVersion?: string | undefined;
|
|
4522
|
-
queue?: {
|
|
4523
|
-
name?: string | undefined;
|
|
4524
|
-
concurrencyLimit?: number | undefined;
|
|
4525
|
-
rateLimit?: {
|
|
4526
|
-
type: "fixed-window";
|
|
4527
|
-
limit: number;
|
|
4528
|
-
window: ({
|
|
4529
|
-
seconds: number;
|
|
4530
|
-
} | {
|
|
4531
|
-
minutes: number;
|
|
4532
|
-
} | {
|
|
4533
|
-
hours: number;
|
|
4534
|
-
}) & ({
|
|
4535
|
-
seconds: number;
|
|
4536
|
-
} | {
|
|
4537
|
-
minutes: number;
|
|
4538
|
-
} | {
|
|
4539
|
-
hours: number;
|
|
4540
|
-
} | undefined);
|
|
4541
|
-
} | {
|
|
4542
|
-
type: "sliding-window";
|
|
4543
|
-
limit: number;
|
|
4544
|
-
window: ({
|
|
4545
|
-
seconds: number;
|
|
4546
|
-
} | {
|
|
4547
|
-
minutes: number;
|
|
4548
|
-
} | {
|
|
4549
|
-
hours: number;
|
|
4550
|
-
}) & ({
|
|
4551
|
-
seconds: number;
|
|
4552
|
-
} | {
|
|
4553
|
-
minutes: number;
|
|
4554
|
-
} | {
|
|
4555
|
-
hours: number;
|
|
4556
|
-
} | undefined);
|
|
4557
|
-
} | undefined;
|
|
4558
|
-
} | undefined;
|
|
4559
|
-
concurrencyKey?: string | undefined;
|
|
4560
|
-
idempotencyKey?: string | undefined;
|
|
4561
|
-
test?: boolean | undefined;
|
|
4562
|
-
payloadType?: string | undefined;
|
|
4563
|
-
} | undefined;
|
|
4564
|
-
}[];
|
|
4565
|
-
dependentAttempt?: string | undefined;
|
|
4566
|
-
}, {
|
|
4567
|
-
items: {
|
|
4568
|
-
payload?: any;
|
|
4569
|
-
context?: any;
|
|
4570
|
-
options?: {
|
|
4571
|
-
dependentAttempt?: string | undefined;
|
|
4572
|
-
dependentBatch?: string | undefined;
|
|
4573
|
-
lockToVersion?: string | undefined;
|
|
4574
|
-
queue?: {
|
|
4575
|
-
name?: string | undefined;
|
|
4576
|
-
concurrencyLimit?: number | undefined;
|
|
4577
|
-
rateLimit?: {
|
|
4578
|
-
type: "fixed-window";
|
|
4579
|
-
limit: number;
|
|
4580
|
-
window: ({
|
|
4581
|
-
seconds: number;
|
|
4582
|
-
} | {
|
|
4583
|
-
minutes: number;
|
|
4584
|
-
} | {
|
|
4585
|
-
hours: number;
|
|
4586
|
-
}) & ({
|
|
4587
|
-
seconds: number;
|
|
4588
|
-
} | {
|
|
4589
|
-
minutes: number;
|
|
4590
|
-
} | {
|
|
4591
|
-
hours: number;
|
|
4592
|
-
} | undefined);
|
|
4593
|
-
} | {
|
|
4594
|
-
type: "sliding-window";
|
|
4595
|
-
limit: number;
|
|
4596
|
-
window: ({
|
|
4597
|
-
seconds: number;
|
|
4598
|
-
} | {
|
|
4599
|
-
minutes: number;
|
|
4600
|
-
} | {
|
|
4601
|
-
hours: number;
|
|
4602
|
-
}) & ({
|
|
4603
|
-
seconds: number;
|
|
4604
|
-
} | {
|
|
4605
|
-
minutes: number;
|
|
4606
|
-
} | {
|
|
4607
|
-
hours: number;
|
|
4608
|
-
} | undefined);
|
|
4609
|
-
} | undefined;
|
|
4610
|
-
} | undefined;
|
|
4611
|
-
concurrencyKey?: string | undefined;
|
|
4612
|
-
idempotencyKey?: string | undefined;
|
|
4613
|
-
test?: boolean | undefined;
|
|
4614
|
-
payloadType?: string | undefined;
|
|
4615
|
-
} | undefined;
|
|
4616
|
-
}[];
|
|
4617
|
-
dependentAttempt?: string | undefined;
|
|
4618
|
-
}>;
|
|
4619
|
-
|
|
4620
|
-
export { APIConnectionError, APIError, type APIHeaders, Accessory, ApiClient, ApiClientManager, AuthenticationError, BackgroundWorkerMetadata, BadRequestError, BatchTaskRunExecutionResult, BatchTriggerTaskRequestBody, BatchTriggerTaskResponse, CanceledRunResponse, CancellationSpanEvent, ConflictError, type CreateAuthorizationCodeResponse, CreateAuthorizationCodeResponseSchema, CreateBackgroundWorkerRequestBody, CreateBackgroundWorkerResponse, CreateScheduleOptions, CreateUploadPayloadUrlResponseBody, DeletedScheduleObject, DeploymentErrorData, EventFilter, ExceptionEventProperties, ExceptionSpanEvent, ExternalBuildData, FetchRetryBackoffStrategy, FetchRetryByStatusOptions, FetchRetryHeadersStrategy, FetchRetryOptions, FetchRetryStrategy, FetchTimeoutOptions, GetBatchResponseBody, GetDeploymentResponseBody, GetEnvironmentVariablesResponseBody, type GetPersonalAccessTokenRequest, GetPersonalAccessTokenRequestSchema, type GetPersonalAccessTokenResponse, GetPersonalAccessTokenResponseSchema, GetProjectEnvResponse, GetProjectResponseBody, GetProjectsResponseBody, type IOPacket, ImageDetailsMetadata, InitializeDeploymentRequestBody, InitializeDeploymentResponseBody, InternalServerError, ListScheduleOptions, ListSchedulesResult, NotFoundError, OFFLOAD_IO_PACKET_LENGTH_LIMIT, OTEL_ATTRIBUTE_PER_EVENT_COUNT_LIMIT, OTEL_ATTRIBUTE_PER_LINK_COUNT_LIMIT, OTEL_LINK_COUNT_LIMIT, OTEL_LOG_ATTRIBUTE_COUNT_LIMIT, OTEL_LOG_ATTRIBUTE_VALUE_LENGTH_LIMIT, OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT, OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT, OTEL_SPAN_EVENT_COUNT_LIMIT, OtherSpanEvent, PRIMARY_VARIANT, PermissionDeniedError, Prettify, RateLimitError, ReplayRunResponse, RetryOptions, ScheduleObject, ScheduledTaskPayload, SemanticInternalAttributes, SpanEvent, SpanEvents, SpanMessagingEvent, StandardTaskCatalog, StartDeploymentIndexingRequestBody, StartDeploymentIndexingResponseBody, TaskEventStyle, TaskFileMetadata, TaskLogger, TaskMetadataWithFilePath, TaskMetadataWithFunctions, TaskResource, TaskRunContext, TaskRunError, TaskRunExecutionResult, type TriggerOptions, TriggerTaskRequestBody, TriggerTaskResponse, TriggerTracer, UnprocessableEntityError, UpdateScheduleOptions, Variant, type WhoAmIResponse, WhoAmIResponseSchema, accessoryAttributes, apiClientManager, calculateNextRetryDelay, calculateResetAt, clock, conditionallyExportPacket, conditionallyImportPacket, correctErrorStackTrace, createErrorTaskError, createPacketAttributes, createPacketAttributesAsJson, defaultFetchRetryOptions, defaultRetryOptions, detectDependencyVersion, flattenAttributes, formatDuration, formatDurationInDays, formatDurationMilliseconds, formatDurationNanoseconds, getEnvVar, groupTaskMetadataIssuesByTask, iconStringForSeverity, imposeAttributeLimits, isCancellationSpanEvent, isExceptionSpanEvent, logger, millisecondsToNanoseconds, nanosecondsToMilliseconds, omit, packetRequiresOffloading, parseBatchTriggerTaskRequestBody, parseError, parsePacket, parseTriggerTaskRequestBody, prettyPrintPacket, primitiveValueOrflattenedAttributes, runtime, stringPatternMatchers, stringifyIO, taskCatalog, unflattenAttributes };
|
|
4406
|
+
export { APIConnectionError, APIError, type APIHeaders, Accessory, ApiClient, ApiClientManager, AuthenticationError, BackgroundWorkerMetadata, BackgroundWorkerProperties, BadRequestError, BatchTaskRunExecutionResult, BatchTriggerTaskRequestBody, BatchTriggerTaskResponse, CanceledRunResponse, CancellationSpanEvent, ConflictError, type CreateAuthorizationCodeResponse, CreateAuthorizationCodeResponseSchema, CreateBackgroundWorkerRequestBody, CreateBackgroundWorkerResponse, CreateScheduleOptions, CreateUploadPayloadUrlResponseBody, DeletedScheduleObject, DeploymentErrorData, EventFilter, ExceptionEventProperties, ExceptionSpanEvent, ExternalBuildData, FetchRetryBackoffStrategy, FetchRetryByStatusOptions, FetchRetryHeadersStrategy, FetchRetryOptions, FetchRetryStrategy, FetchTimeoutOptions, GetBatchResponseBody, GetDeploymentResponseBody, GetEnvironmentVariablesResponseBody, type GetPersonalAccessTokenRequest, GetPersonalAccessTokenRequestSchema, type GetPersonalAccessTokenResponse, GetPersonalAccessTokenResponseSchema, GetProjectEnvResponse, GetProjectResponseBody, GetProjectsResponseBody, type IOPacket, ImageDetailsMetadata, InitializeDeploymentRequestBody, InitializeDeploymentResponseBody, InternalServerError, ListScheduleOptions, ListSchedulesResult, NotFoundError, OFFLOAD_IO_PACKET_LENGTH_LIMIT, OTEL_ATTRIBUTE_PER_EVENT_COUNT_LIMIT, OTEL_ATTRIBUTE_PER_LINK_COUNT_LIMIT, OTEL_LINK_COUNT_LIMIT, OTEL_LOG_ATTRIBUTE_COUNT_LIMIT, OTEL_LOG_ATTRIBUTE_VALUE_LENGTH_LIMIT, OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT, OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT, OTEL_SPAN_EVENT_COUNT_LIMIT, OtherSpanEvent, PRIMARY_VARIANT, PermissionDeniedError, Prettify, RateLimitError, ReplayRunResponse, RetryOptions, ScheduleObject, ScheduledTaskPayload, SemanticInternalAttributes, SpanEvent, SpanEvents, SpanMessagingEvent, StartDeploymentIndexingRequestBody, StartDeploymentIndexingResponseBody, TaskEventStyle, TaskFileMetadata, TaskMetadataWithFilePath, TaskMetadataWithFunctions, TaskResource, TaskRunContext, TaskRunError, TaskRunExecutionResult, type TriggerOptions, TriggerTaskRequestBody, TriggerTaskResponse, TriggerTracer, UnprocessableEntityError, UpdateScheduleOptions, Variant, type WhoAmIResponse, WhoAmIResponseSchema, accessoryAttributes, apiClientManager, calculateNextRetryDelay, calculateResetAt, clock, conditionallyExportPacket, conditionallyImportPacket, correctErrorStackTrace, createErrorTaskError, createPacketAttributes, createPacketAttributesAsJson, defaultFetchRetryOptions, defaultRetryOptions, detectDependencyVersion, flattenAttributes, formatDuration, formatDurationInDays, formatDurationMilliseconds, formatDurationNanoseconds, groupTaskMetadataIssuesByTask, imposeAttributeLimits, isCancellationSpanEvent, isExceptionSpanEvent, logger, millisecondsToNanoseconds, nanosecondsToMilliseconds, omit, packetRequiresOffloading, parseError, parsePacket, prettyPrintPacket, primitiveValueOrflattenedAttributes, runtime, stringPatternMatchers, stringifyIO, taskCatalog, taskContext, unflattenAttributes };
|