@eigenpal/cli 0.7.1 → 0.7.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/cli.js +292 -2663
- package/package.json +1 -1
package/dist/cli.js
CHANGED
|
@@ -17080,2478 +17080,14 @@ var require_picocolors = __commonJS((exports, module) => {
|
|
|
17080
17080
|
module.exports.createColors = createColors;
|
|
17081
17081
|
});
|
|
17082
17082
|
|
|
17083
|
-
// ../../node_modules/nanoid/url-alphabet/index.js
|
|
17084
|
-
var urlAlphabet = "useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";
|
|
17085
|
-
|
|
17086
|
-
// ../../node_modules/nanoid/index.js
|
|
17087
|
-
import { webcrypto as crypto } from "node:crypto";
|
|
17088
|
-
function fillPool(bytes) {
|
|
17089
|
-
if (!pool || pool.length < bytes) {
|
|
17090
|
-
pool = Buffer.allocUnsafe(bytes * POOL_SIZE_MULTIPLIER);
|
|
17091
|
-
crypto.getRandomValues(pool);
|
|
17092
|
-
poolOffset = 0;
|
|
17093
|
-
} else if (poolOffset + bytes > pool.length) {
|
|
17094
|
-
crypto.getRandomValues(pool);
|
|
17095
|
-
poolOffset = 0;
|
|
17096
|
-
}
|
|
17097
|
-
poolOffset += bytes;
|
|
17098
|
-
}
|
|
17099
|
-
function nanoid3(size = 21) {
|
|
17100
|
-
fillPool(size |= 0);
|
|
17101
|
-
let id = "";
|
|
17102
|
-
for (let i = poolOffset - size;i < poolOffset; i++) {
|
|
17103
|
-
id += urlAlphabet[pool[i] & 63];
|
|
17104
|
-
}
|
|
17105
|
-
return id;
|
|
17106
|
-
}
|
|
17107
|
-
var POOL_SIZE_MULTIPLIER = 128, pool, poolOffset;
|
|
17108
|
-
var init_nanoid = () => {};
|
|
17109
|
-
|
|
17110
|
-
// ../types/src/core/common.ts
|
|
17111
|
-
function generateId(prefix) {
|
|
17112
|
-
const id = nanoid3();
|
|
17113
|
-
return prefix ? `${prefix}_${id}` : id;
|
|
17114
|
-
}
|
|
17115
|
-
function toJsonSchema(schema) {
|
|
17116
|
-
return exports_external.toJSONSchema(schema, { target: "draft-7" });
|
|
17117
|
-
}
|
|
17118
|
-
var ID_PREFIXES, TimestampSchema, JsonSchemaSchema, BaseEntitySchema;
|
|
17119
|
-
var init_common = __esm(() => {
|
|
17120
|
-
init_nanoid();
|
|
17121
|
-
init_zod();
|
|
17122
|
-
ID_PREFIXES = {
|
|
17123
|
-
WORKFLOW: "wf",
|
|
17124
|
-
WORKFLOW_VERSION: "wfv",
|
|
17125
|
-
WORKFLOW_HISTORY: "wfh",
|
|
17126
|
-
JOB: "job",
|
|
17127
|
-
EXECUTION: "exec",
|
|
17128
|
-
STEP_EXECUTION: "step",
|
|
17129
|
-
FILE: "file",
|
|
17130
|
-
TEMPLATE: "tmpl",
|
|
17131
|
-
USER: "user",
|
|
17132
|
-
TENANT: "org",
|
|
17133
|
-
TENANT_INVITE: "inv",
|
|
17134
|
-
API_KEY: "eig",
|
|
17135
|
-
PROCESSOR: "proc",
|
|
17136
|
-
AI_PROVIDER: "aip",
|
|
17137
|
-
ACCOUNT: "acct",
|
|
17138
|
-
SESSION: "sess",
|
|
17139
|
-
VERIFICATION: "vrf",
|
|
17140
|
-
DATASET: "ds",
|
|
17141
|
-
DATASET_EXAMPLE: "dex",
|
|
17142
|
-
EXPERIMENT: "exp",
|
|
17143
|
-
EXPERIMENT_RUN: "exr",
|
|
17144
|
-
EXPERIMENT_EVALUATION: "evl",
|
|
17145
|
-
EVAL_EXAMPLE: "evx",
|
|
17146
|
-
EVAL_RESULT: "evr",
|
|
17147
|
-
EVAL_BATCH: "evb",
|
|
17148
|
-
TABLE_ROW: "row",
|
|
17149
|
-
FOLDER: "fldr",
|
|
17150
|
-
AGENT_WORKFLOW: "awf",
|
|
17151
|
-
AGENT_EXECUTION: "aex",
|
|
17152
|
-
AGENT_EXAMPLE: "aeg",
|
|
17153
|
-
AGENT_VERSION: "avr",
|
|
17154
|
-
AGENT_TRAINING_SESSION: "ats",
|
|
17155
|
-
AGENT_EXPERIMENT: "aexp",
|
|
17156
|
-
AGENT_EMAIL_ALIAS: "aea",
|
|
17157
|
-
AGENT_EMAIL_INVOCATION: "aei",
|
|
17158
|
-
AUTOMATION_TRIGGER: "atr",
|
|
17159
|
-
SANDBOX_WS_TOKEN: "sws"
|
|
17160
|
-
};
|
|
17161
|
-
TimestampSchema = exports_external.union([exports_external.date(), exports_external.string().datetime()]).transform((val) => {
|
|
17162
|
-
return typeof val === "string" ? new Date(val) : val;
|
|
17163
|
-
});
|
|
17164
|
-
JsonSchemaSchema = exports_external.record(exports_external.string(), exports_external.unknown());
|
|
17165
|
-
BaseEntitySchema = exports_external.object({
|
|
17166
|
-
id: exports_external.string(),
|
|
17167
|
-
createdAt: TimestampSchema.optional(),
|
|
17168
|
-
updatedAt: TimestampSchema.optional()
|
|
17169
|
-
});
|
|
17170
|
-
});
|
|
17171
|
-
|
|
17172
|
-
// ../types/src/core/ids.ts
|
|
17173
|
-
var PROCESSOR_IDS, PARSER_IDS, INPUT_KINDS;
|
|
17174
|
-
var init_ids = __esm(() => {
|
|
17175
|
-
PROCESSOR_IDS = {
|
|
17176
|
-
MERGE: "builtin/merge",
|
|
17177
|
-
DOCUMENT_PARSER: "builtin/parser",
|
|
17178
|
-
EXTRACT: "builtin/extract",
|
|
17179
|
-
SPLIT: "builtin/split",
|
|
17180
|
-
CLASSIFY: "builtin/classify",
|
|
17181
|
-
TEMPLATE: "builtin/template",
|
|
17182
|
-
PDF_EMBEDDER: "builtin/pdf-embedder",
|
|
17183
|
-
XLSX_TO_JSON: "builtin/xlsx-to-json"
|
|
17184
|
-
};
|
|
17185
|
-
PARSER_IDS = {
|
|
17186
|
-
KREUZBERG: "builtin/kreuzberg",
|
|
17187
|
-
OCR: "builtin/ocr",
|
|
17188
|
-
LLM_VISION: "builtin/llm-vision"
|
|
17189
|
-
};
|
|
17190
|
-
INPUT_KINDS = {
|
|
17191
|
-
DOCUMENT: "document",
|
|
17192
|
-
PAYLOAD: "payload"
|
|
17193
|
-
};
|
|
17194
|
-
});
|
|
17195
|
-
|
|
17196
|
-
// ../types/src/core/pagination.ts
|
|
17197
|
-
var PaginationParamsSchema, DEFAULT_PAGE_SIZE = 50, MAX_PAGE_SIZE = 100;
|
|
17198
|
-
var init_pagination = __esm(() => {
|
|
17199
|
-
init_zod();
|
|
17200
|
-
PaginationParamsSchema = exports_external.object({
|
|
17201
|
-
limit: exports_external.coerce.number().int().min(1).max(100).default(50),
|
|
17202
|
-
offset: exports_external.coerce.number().int().min(0).default(0)
|
|
17203
|
-
});
|
|
17204
|
-
});
|
|
17205
|
-
|
|
17206
17083
|
// ../types/src/core/index.ts
|
|
17207
|
-
var init_core3 =
|
|
17208
|
-
init_common();
|
|
17209
|
-
init_ids();
|
|
17210
|
-
init_pagination();
|
|
17211
|
-
});
|
|
17212
|
-
|
|
17213
|
-
// ../../node_modules/@opentelemetry/api/build/src/version.js
|
|
17214
|
-
var require_version = __commonJS((exports) => {
|
|
17215
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17216
|
-
exports.VERSION = undefined;
|
|
17217
|
-
exports.VERSION = "1.9.1";
|
|
17218
|
-
});
|
|
17219
|
-
|
|
17220
|
-
// ../../node_modules/@opentelemetry/api/build/src/internal/semver.js
|
|
17221
|
-
var require_semver = __commonJS((exports) => {
|
|
17222
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17223
|
-
exports.isCompatible = exports._makeCompatibilityCheck = undefined;
|
|
17224
|
-
var version_1 = require_version();
|
|
17225
|
-
var re = /^(\d+)\.(\d+)\.(\d+)(-(.+))?$/;
|
|
17226
|
-
function _makeCompatibilityCheck(ownVersion) {
|
|
17227
|
-
const acceptedVersions = new Set([ownVersion]);
|
|
17228
|
-
const rejectedVersions = new Set;
|
|
17229
|
-
const myVersionMatch = ownVersion.match(re);
|
|
17230
|
-
if (!myVersionMatch) {
|
|
17231
|
-
return () => false;
|
|
17232
|
-
}
|
|
17233
|
-
const ownVersionParsed = {
|
|
17234
|
-
major: +myVersionMatch[1],
|
|
17235
|
-
minor: +myVersionMatch[2],
|
|
17236
|
-
patch: +myVersionMatch[3],
|
|
17237
|
-
prerelease: myVersionMatch[4]
|
|
17238
|
-
};
|
|
17239
|
-
if (ownVersionParsed.prerelease != null) {
|
|
17240
|
-
return function isExactmatch(globalVersion) {
|
|
17241
|
-
return globalVersion === ownVersion;
|
|
17242
|
-
};
|
|
17243
|
-
}
|
|
17244
|
-
function _reject(v) {
|
|
17245
|
-
rejectedVersions.add(v);
|
|
17246
|
-
return false;
|
|
17247
|
-
}
|
|
17248
|
-
function _accept(v) {
|
|
17249
|
-
acceptedVersions.add(v);
|
|
17250
|
-
return true;
|
|
17251
|
-
}
|
|
17252
|
-
return function isCompatible(globalVersion) {
|
|
17253
|
-
if (acceptedVersions.has(globalVersion)) {
|
|
17254
|
-
return true;
|
|
17255
|
-
}
|
|
17256
|
-
if (rejectedVersions.has(globalVersion)) {
|
|
17257
|
-
return false;
|
|
17258
|
-
}
|
|
17259
|
-
const globalVersionMatch = globalVersion.match(re);
|
|
17260
|
-
if (!globalVersionMatch) {
|
|
17261
|
-
return _reject(globalVersion);
|
|
17262
|
-
}
|
|
17263
|
-
const globalVersionParsed = {
|
|
17264
|
-
major: +globalVersionMatch[1],
|
|
17265
|
-
minor: +globalVersionMatch[2],
|
|
17266
|
-
patch: +globalVersionMatch[3],
|
|
17267
|
-
prerelease: globalVersionMatch[4]
|
|
17268
|
-
};
|
|
17269
|
-
if (globalVersionParsed.prerelease != null) {
|
|
17270
|
-
return _reject(globalVersion);
|
|
17271
|
-
}
|
|
17272
|
-
if (ownVersionParsed.major !== globalVersionParsed.major) {
|
|
17273
|
-
return _reject(globalVersion);
|
|
17274
|
-
}
|
|
17275
|
-
if (ownVersionParsed.major === 0) {
|
|
17276
|
-
if (ownVersionParsed.minor === globalVersionParsed.minor && ownVersionParsed.patch <= globalVersionParsed.patch) {
|
|
17277
|
-
return _accept(globalVersion);
|
|
17278
|
-
}
|
|
17279
|
-
return _reject(globalVersion);
|
|
17280
|
-
}
|
|
17281
|
-
if (ownVersionParsed.minor <= globalVersionParsed.minor) {
|
|
17282
|
-
return _accept(globalVersion);
|
|
17283
|
-
}
|
|
17284
|
-
return _reject(globalVersion);
|
|
17285
|
-
};
|
|
17286
|
-
}
|
|
17287
|
-
exports._makeCompatibilityCheck = _makeCompatibilityCheck;
|
|
17288
|
-
exports.isCompatible = _makeCompatibilityCheck(version_1.VERSION);
|
|
17289
|
-
});
|
|
17290
|
-
|
|
17291
|
-
// ../../node_modules/@opentelemetry/api/build/src/internal/global-utils.js
|
|
17292
|
-
var require_global_utils = __commonJS((exports) => {
|
|
17293
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17294
|
-
exports.unregisterGlobal = exports.getGlobal = exports.registerGlobal = undefined;
|
|
17295
|
-
var version_1 = require_version();
|
|
17296
|
-
var semver_1 = require_semver();
|
|
17297
|
-
var major = version_1.VERSION.split(".")[0];
|
|
17298
|
-
var GLOBAL_OPENTELEMETRY_API_KEY = Symbol.for(`opentelemetry.js.api.${major}`);
|
|
17299
|
-
var _global = typeof globalThis === "object" ? globalThis : typeof self === "object" ? self : typeof window === "object" ? window : typeof global === "object" ? global : {};
|
|
17300
|
-
function registerGlobal(type, instance, diag, allowOverride = false) {
|
|
17301
|
-
var _a3;
|
|
17302
|
-
const api2 = _global[GLOBAL_OPENTELEMETRY_API_KEY] = (_a3 = _global[GLOBAL_OPENTELEMETRY_API_KEY]) !== null && _a3 !== undefined ? _a3 : {
|
|
17303
|
-
version: version_1.VERSION
|
|
17304
|
-
};
|
|
17305
|
-
if (!allowOverride && api2[type]) {
|
|
17306
|
-
const err = new Error(`@opentelemetry/api: Attempted duplicate registration of API: ${type}`);
|
|
17307
|
-
diag.error(err.stack || err.message);
|
|
17308
|
-
return false;
|
|
17309
|
-
}
|
|
17310
|
-
if (api2.version !== version_1.VERSION) {
|
|
17311
|
-
const err = new Error(`@opentelemetry/api: Registration of version v${api2.version} for ${type} does not match previously registered API v${version_1.VERSION}`);
|
|
17312
|
-
diag.error(err.stack || err.message);
|
|
17313
|
-
return false;
|
|
17314
|
-
}
|
|
17315
|
-
api2[type] = instance;
|
|
17316
|
-
diag.debug(`@opentelemetry/api: Registered a global for ${type} v${version_1.VERSION}.`);
|
|
17317
|
-
return true;
|
|
17318
|
-
}
|
|
17319
|
-
exports.registerGlobal = registerGlobal;
|
|
17320
|
-
function getGlobal(type) {
|
|
17321
|
-
var _a3, _b;
|
|
17322
|
-
const globalVersion = (_a3 = _global[GLOBAL_OPENTELEMETRY_API_KEY]) === null || _a3 === undefined ? undefined : _a3.version;
|
|
17323
|
-
if (!globalVersion || !(0, semver_1.isCompatible)(globalVersion)) {
|
|
17324
|
-
return;
|
|
17325
|
-
}
|
|
17326
|
-
return (_b = _global[GLOBAL_OPENTELEMETRY_API_KEY]) === null || _b === undefined ? undefined : _b[type];
|
|
17327
|
-
}
|
|
17328
|
-
exports.getGlobal = getGlobal;
|
|
17329
|
-
function unregisterGlobal(type, diag) {
|
|
17330
|
-
diag.debug(`@opentelemetry/api: Unregistering a global for ${type} v${version_1.VERSION}.`);
|
|
17331
|
-
const api2 = _global[GLOBAL_OPENTELEMETRY_API_KEY];
|
|
17332
|
-
if (api2) {
|
|
17333
|
-
delete api2[type];
|
|
17334
|
-
}
|
|
17335
|
-
}
|
|
17336
|
-
exports.unregisterGlobal = unregisterGlobal;
|
|
17337
|
-
});
|
|
17338
|
-
|
|
17339
|
-
// ../../node_modules/@opentelemetry/api/build/src/diag/ComponentLogger.js
|
|
17340
|
-
var require_ComponentLogger = __commonJS((exports) => {
|
|
17341
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17342
|
-
exports.DiagComponentLogger = undefined;
|
|
17343
|
-
var global_utils_1 = require_global_utils();
|
|
17344
|
-
|
|
17345
|
-
class DiagComponentLogger {
|
|
17346
|
-
constructor(props) {
|
|
17347
|
-
this._namespace = props.namespace || "DiagComponentLogger";
|
|
17348
|
-
}
|
|
17349
|
-
debug(...args) {
|
|
17350
|
-
return logProxy("debug", this._namespace, args);
|
|
17351
|
-
}
|
|
17352
|
-
error(...args) {
|
|
17353
|
-
return logProxy("error", this._namespace, args);
|
|
17354
|
-
}
|
|
17355
|
-
info(...args) {
|
|
17356
|
-
return logProxy("info", this._namespace, args);
|
|
17357
|
-
}
|
|
17358
|
-
warn(...args) {
|
|
17359
|
-
return logProxy("warn", this._namespace, args);
|
|
17360
|
-
}
|
|
17361
|
-
verbose(...args) {
|
|
17362
|
-
return logProxy("verbose", this._namespace, args);
|
|
17363
|
-
}
|
|
17364
|
-
}
|
|
17365
|
-
exports.DiagComponentLogger = DiagComponentLogger;
|
|
17366
|
-
function logProxy(funcName, namespace, args) {
|
|
17367
|
-
const logger = (0, global_utils_1.getGlobal)("diag");
|
|
17368
|
-
if (!logger) {
|
|
17369
|
-
return;
|
|
17370
|
-
}
|
|
17371
|
-
return logger[funcName](namespace, ...args);
|
|
17372
|
-
}
|
|
17373
|
-
});
|
|
17374
|
-
|
|
17375
|
-
// ../../node_modules/@opentelemetry/api/build/src/diag/types.js
|
|
17376
|
-
var require_types = __commonJS((exports) => {
|
|
17377
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17378
|
-
exports.DiagLogLevel = undefined;
|
|
17379
|
-
var DiagLogLevel;
|
|
17380
|
-
(function(DiagLogLevel2) {
|
|
17381
|
-
DiagLogLevel2[DiagLogLevel2["NONE"] = 0] = "NONE";
|
|
17382
|
-
DiagLogLevel2[DiagLogLevel2["ERROR"] = 30] = "ERROR";
|
|
17383
|
-
DiagLogLevel2[DiagLogLevel2["WARN"] = 50] = "WARN";
|
|
17384
|
-
DiagLogLevel2[DiagLogLevel2["INFO"] = 60] = "INFO";
|
|
17385
|
-
DiagLogLevel2[DiagLogLevel2["DEBUG"] = 70] = "DEBUG";
|
|
17386
|
-
DiagLogLevel2[DiagLogLevel2["VERBOSE"] = 80] = "VERBOSE";
|
|
17387
|
-
DiagLogLevel2[DiagLogLevel2["ALL"] = 9999] = "ALL";
|
|
17388
|
-
})(DiagLogLevel = exports.DiagLogLevel || (exports.DiagLogLevel = {}));
|
|
17389
|
-
});
|
|
17390
|
-
|
|
17391
|
-
// ../../node_modules/@opentelemetry/api/build/src/diag/internal/logLevelLogger.js
|
|
17392
|
-
var require_logLevelLogger = __commonJS((exports) => {
|
|
17393
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17394
|
-
exports.createLogLevelDiagLogger = undefined;
|
|
17395
|
-
var types_1 = require_types();
|
|
17396
|
-
function createLogLevelDiagLogger(maxLevel, logger) {
|
|
17397
|
-
if (maxLevel < types_1.DiagLogLevel.NONE) {
|
|
17398
|
-
maxLevel = types_1.DiagLogLevel.NONE;
|
|
17399
|
-
} else if (maxLevel > types_1.DiagLogLevel.ALL) {
|
|
17400
|
-
maxLevel = types_1.DiagLogLevel.ALL;
|
|
17401
|
-
}
|
|
17402
|
-
logger = logger || {};
|
|
17403
|
-
function _filterFunc(funcName, theLevel) {
|
|
17404
|
-
const theFunc = logger[funcName];
|
|
17405
|
-
if (typeof theFunc === "function" && maxLevel >= theLevel) {
|
|
17406
|
-
return theFunc.bind(logger);
|
|
17407
|
-
}
|
|
17408
|
-
return function() {};
|
|
17409
|
-
}
|
|
17410
|
-
return {
|
|
17411
|
-
error: _filterFunc("error", types_1.DiagLogLevel.ERROR),
|
|
17412
|
-
warn: _filterFunc("warn", types_1.DiagLogLevel.WARN),
|
|
17413
|
-
info: _filterFunc("info", types_1.DiagLogLevel.INFO),
|
|
17414
|
-
debug: _filterFunc("debug", types_1.DiagLogLevel.DEBUG),
|
|
17415
|
-
verbose: _filterFunc("verbose", types_1.DiagLogLevel.VERBOSE)
|
|
17416
|
-
};
|
|
17417
|
-
}
|
|
17418
|
-
exports.createLogLevelDiagLogger = createLogLevelDiagLogger;
|
|
17419
|
-
});
|
|
17420
|
-
|
|
17421
|
-
// ../../node_modules/@opentelemetry/api/build/src/api/diag.js
|
|
17422
|
-
var require_diag = __commonJS((exports) => {
|
|
17423
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17424
|
-
exports.DiagAPI = undefined;
|
|
17425
|
-
var ComponentLogger_1 = require_ComponentLogger();
|
|
17426
|
-
var logLevelLogger_1 = require_logLevelLogger();
|
|
17427
|
-
var types_1 = require_types();
|
|
17428
|
-
var global_utils_1 = require_global_utils();
|
|
17429
|
-
var API_NAME = "diag";
|
|
17430
|
-
|
|
17431
|
-
class DiagAPI {
|
|
17432
|
-
static instance() {
|
|
17433
|
-
if (!this._instance) {
|
|
17434
|
-
this._instance = new DiagAPI;
|
|
17435
|
-
}
|
|
17436
|
-
return this._instance;
|
|
17437
|
-
}
|
|
17438
|
-
constructor() {
|
|
17439
|
-
function _logProxy(funcName) {
|
|
17440
|
-
return function(...args) {
|
|
17441
|
-
const logger = (0, global_utils_1.getGlobal)("diag");
|
|
17442
|
-
if (!logger)
|
|
17443
|
-
return;
|
|
17444
|
-
return logger[funcName](...args);
|
|
17445
|
-
};
|
|
17446
|
-
}
|
|
17447
|
-
const self2 = this;
|
|
17448
|
-
const setLogger = (logger, optionsOrLogLevel = { logLevel: types_1.DiagLogLevel.INFO }) => {
|
|
17449
|
-
var _a3, _b, _c;
|
|
17450
|
-
if (logger === self2) {
|
|
17451
|
-
const err = new Error("Cannot use diag as the logger for itself. Please use a DiagLogger implementation like ConsoleDiagLogger or a custom implementation");
|
|
17452
|
-
self2.error((_a3 = err.stack) !== null && _a3 !== undefined ? _a3 : err.message);
|
|
17453
|
-
return false;
|
|
17454
|
-
}
|
|
17455
|
-
if (typeof optionsOrLogLevel === "number") {
|
|
17456
|
-
optionsOrLogLevel = {
|
|
17457
|
-
logLevel: optionsOrLogLevel
|
|
17458
|
-
};
|
|
17459
|
-
}
|
|
17460
|
-
const oldLogger = (0, global_utils_1.getGlobal)("diag");
|
|
17461
|
-
const newLogger = (0, logLevelLogger_1.createLogLevelDiagLogger)((_b = optionsOrLogLevel.logLevel) !== null && _b !== undefined ? _b : types_1.DiagLogLevel.INFO, logger);
|
|
17462
|
-
if (oldLogger && !optionsOrLogLevel.suppressOverrideMessage) {
|
|
17463
|
-
const stack = (_c = new Error().stack) !== null && _c !== undefined ? _c : "<failed to generate stacktrace>";
|
|
17464
|
-
oldLogger.warn(`Current logger will be overwritten from ${stack}`);
|
|
17465
|
-
newLogger.warn(`Current logger will overwrite one already registered from ${stack}`);
|
|
17466
|
-
}
|
|
17467
|
-
return (0, global_utils_1.registerGlobal)("diag", newLogger, self2, true);
|
|
17468
|
-
};
|
|
17469
|
-
self2.setLogger = setLogger;
|
|
17470
|
-
self2.disable = () => {
|
|
17471
|
-
(0, global_utils_1.unregisterGlobal)(API_NAME, self2);
|
|
17472
|
-
};
|
|
17473
|
-
self2.createComponentLogger = (options) => {
|
|
17474
|
-
return new ComponentLogger_1.DiagComponentLogger(options);
|
|
17475
|
-
};
|
|
17476
|
-
self2.verbose = _logProxy("verbose");
|
|
17477
|
-
self2.debug = _logProxy("debug");
|
|
17478
|
-
self2.info = _logProxy("info");
|
|
17479
|
-
self2.warn = _logProxy("warn");
|
|
17480
|
-
self2.error = _logProxy("error");
|
|
17481
|
-
}
|
|
17482
|
-
}
|
|
17483
|
-
exports.DiagAPI = DiagAPI;
|
|
17484
|
-
});
|
|
17485
|
-
|
|
17486
|
-
// ../../node_modules/@opentelemetry/api/build/src/baggage/internal/baggage-impl.js
|
|
17487
|
-
var require_baggage_impl = __commonJS((exports) => {
|
|
17488
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17489
|
-
exports.BaggageImpl = undefined;
|
|
17490
|
-
|
|
17491
|
-
class BaggageImpl {
|
|
17492
|
-
constructor(entries) {
|
|
17493
|
-
this._entries = entries ? new Map(entries) : new Map;
|
|
17494
|
-
}
|
|
17495
|
-
getEntry(key) {
|
|
17496
|
-
const entry = this._entries.get(key);
|
|
17497
|
-
if (!entry) {
|
|
17498
|
-
return;
|
|
17499
|
-
}
|
|
17500
|
-
return Object.assign({}, entry);
|
|
17501
|
-
}
|
|
17502
|
-
getAllEntries() {
|
|
17503
|
-
return Array.from(this._entries.entries());
|
|
17504
|
-
}
|
|
17505
|
-
setEntry(key, entry) {
|
|
17506
|
-
const newBaggage = new BaggageImpl(this._entries);
|
|
17507
|
-
newBaggage._entries.set(key, entry);
|
|
17508
|
-
return newBaggage;
|
|
17509
|
-
}
|
|
17510
|
-
removeEntry(key) {
|
|
17511
|
-
const newBaggage = new BaggageImpl(this._entries);
|
|
17512
|
-
newBaggage._entries.delete(key);
|
|
17513
|
-
return newBaggage;
|
|
17514
|
-
}
|
|
17515
|
-
removeEntries(...keys) {
|
|
17516
|
-
const newBaggage = new BaggageImpl(this._entries);
|
|
17517
|
-
for (const key of keys) {
|
|
17518
|
-
newBaggage._entries.delete(key);
|
|
17519
|
-
}
|
|
17520
|
-
return newBaggage;
|
|
17521
|
-
}
|
|
17522
|
-
clear() {
|
|
17523
|
-
return new BaggageImpl;
|
|
17524
|
-
}
|
|
17525
|
-
}
|
|
17526
|
-
exports.BaggageImpl = BaggageImpl;
|
|
17527
|
-
});
|
|
17528
|
-
|
|
17529
|
-
// ../../node_modules/@opentelemetry/api/build/src/baggage/internal/symbol.js
|
|
17530
|
-
var require_symbol = __commonJS((exports) => {
|
|
17531
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17532
|
-
exports.baggageEntryMetadataSymbol = undefined;
|
|
17533
|
-
exports.baggageEntryMetadataSymbol = Symbol("BaggageEntryMetadata");
|
|
17534
|
-
});
|
|
17535
|
-
|
|
17536
|
-
// ../../node_modules/@opentelemetry/api/build/src/baggage/utils.js
|
|
17537
|
-
var require_utils = __commonJS((exports) => {
|
|
17538
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17539
|
-
exports.baggageEntryMetadataFromString = exports.createBaggage = undefined;
|
|
17540
|
-
var diag_1 = require_diag();
|
|
17541
|
-
var baggage_impl_1 = require_baggage_impl();
|
|
17542
|
-
var symbol_1 = require_symbol();
|
|
17543
|
-
var diag = diag_1.DiagAPI.instance();
|
|
17544
|
-
function createBaggage(entries = {}) {
|
|
17545
|
-
return new baggage_impl_1.BaggageImpl(new Map(Object.entries(entries)));
|
|
17546
|
-
}
|
|
17547
|
-
exports.createBaggage = createBaggage;
|
|
17548
|
-
function baggageEntryMetadataFromString(str) {
|
|
17549
|
-
if (typeof str !== "string") {
|
|
17550
|
-
diag.error(`Cannot create baggage metadata from unknown type: ${typeof str}`);
|
|
17551
|
-
str = "";
|
|
17552
|
-
}
|
|
17553
|
-
return {
|
|
17554
|
-
__TYPE__: symbol_1.baggageEntryMetadataSymbol,
|
|
17555
|
-
toString() {
|
|
17556
|
-
return str;
|
|
17557
|
-
}
|
|
17558
|
-
};
|
|
17559
|
-
}
|
|
17560
|
-
exports.baggageEntryMetadataFromString = baggageEntryMetadataFromString;
|
|
17561
|
-
});
|
|
17562
|
-
|
|
17563
|
-
// ../../node_modules/@opentelemetry/api/build/src/context/context.js
|
|
17564
|
-
var require_context = __commonJS((exports) => {
|
|
17565
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17566
|
-
exports.ROOT_CONTEXT = exports.createContextKey = undefined;
|
|
17567
|
-
function createContextKey(description) {
|
|
17568
|
-
return Symbol.for(description);
|
|
17569
|
-
}
|
|
17570
|
-
exports.createContextKey = createContextKey;
|
|
17571
|
-
|
|
17572
|
-
class BaseContext {
|
|
17573
|
-
constructor(parentContext) {
|
|
17574
|
-
const self2 = this;
|
|
17575
|
-
self2._currentContext = parentContext ? new Map(parentContext) : new Map;
|
|
17576
|
-
self2.getValue = (key) => self2._currentContext.get(key);
|
|
17577
|
-
self2.setValue = (key, value) => {
|
|
17578
|
-
const context = new BaseContext(self2._currentContext);
|
|
17579
|
-
context._currentContext.set(key, value);
|
|
17580
|
-
return context;
|
|
17581
|
-
};
|
|
17582
|
-
self2.deleteValue = (key) => {
|
|
17583
|
-
const context = new BaseContext(self2._currentContext);
|
|
17584
|
-
context._currentContext.delete(key);
|
|
17585
|
-
return context;
|
|
17586
|
-
};
|
|
17587
|
-
}
|
|
17588
|
-
}
|
|
17589
|
-
exports.ROOT_CONTEXT = new BaseContext;
|
|
17590
|
-
});
|
|
17591
|
-
|
|
17592
|
-
// ../../node_modules/@opentelemetry/api/build/src/diag/consoleLogger.js
|
|
17593
|
-
var require_consoleLogger = __commonJS((exports) => {
|
|
17594
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17595
|
-
exports.DiagConsoleLogger = exports._originalConsoleMethods = undefined;
|
|
17596
|
-
var consoleMap = [
|
|
17597
|
-
{ n: "error", c: "error" },
|
|
17598
|
-
{ n: "warn", c: "warn" },
|
|
17599
|
-
{ n: "info", c: "info" },
|
|
17600
|
-
{ n: "debug", c: "debug" },
|
|
17601
|
-
{ n: "verbose", c: "trace" }
|
|
17602
|
-
];
|
|
17603
|
-
exports._originalConsoleMethods = {};
|
|
17604
|
-
if (typeof console !== "undefined") {
|
|
17605
|
-
const keys = [
|
|
17606
|
-
"error",
|
|
17607
|
-
"warn",
|
|
17608
|
-
"info",
|
|
17609
|
-
"debug",
|
|
17610
|
-
"trace",
|
|
17611
|
-
"log"
|
|
17612
|
-
];
|
|
17613
|
-
for (const key of keys) {
|
|
17614
|
-
if (typeof console[key] === "function") {
|
|
17615
|
-
exports._originalConsoleMethods[key] = console[key];
|
|
17616
|
-
}
|
|
17617
|
-
}
|
|
17618
|
-
}
|
|
17619
|
-
|
|
17620
|
-
class DiagConsoleLogger {
|
|
17621
|
-
constructor() {
|
|
17622
|
-
function _consoleFunc(funcName) {
|
|
17623
|
-
return function(...args) {
|
|
17624
|
-
let theFunc = exports._originalConsoleMethods[funcName];
|
|
17625
|
-
if (typeof theFunc !== "function") {
|
|
17626
|
-
theFunc = exports._originalConsoleMethods["log"];
|
|
17627
|
-
}
|
|
17628
|
-
if (typeof theFunc !== "function" && console) {
|
|
17629
|
-
theFunc = console[funcName];
|
|
17630
|
-
if (typeof theFunc !== "function") {
|
|
17631
|
-
theFunc = console.log;
|
|
17632
|
-
}
|
|
17633
|
-
}
|
|
17634
|
-
if (typeof theFunc === "function") {
|
|
17635
|
-
return theFunc.apply(console, args);
|
|
17636
|
-
}
|
|
17637
|
-
};
|
|
17638
|
-
}
|
|
17639
|
-
for (let i = 0;i < consoleMap.length; i++) {
|
|
17640
|
-
this[consoleMap[i].n] = _consoleFunc(consoleMap[i].c);
|
|
17641
|
-
}
|
|
17642
|
-
}
|
|
17643
|
-
}
|
|
17644
|
-
exports.DiagConsoleLogger = DiagConsoleLogger;
|
|
17645
|
-
});
|
|
17646
|
-
|
|
17647
|
-
// ../../node_modules/@opentelemetry/api/build/src/metrics/NoopMeter.js
|
|
17648
|
-
var require_NoopMeter = __commonJS((exports) => {
|
|
17649
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17650
|
-
exports.createNoopMeter = exports.NOOP_OBSERVABLE_UP_DOWN_COUNTER_METRIC = exports.NOOP_OBSERVABLE_GAUGE_METRIC = exports.NOOP_OBSERVABLE_COUNTER_METRIC = exports.NOOP_UP_DOWN_COUNTER_METRIC = exports.NOOP_HISTOGRAM_METRIC = exports.NOOP_GAUGE_METRIC = exports.NOOP_COUNTER_METRIC = exports.NOOP_METER = exports.NoopObservableUpDownCounterMetric = exports.NoopObservableGaugeMetric = exports.NoopObservableCounterMetric = exports.NoopObservableMetric = exports.NoopHistogramMetric = exports.NoopGaugeMetric = exports.NoopUpDownCounterMetric = exports.NoopCounterMetric = exports.NoopMetric = exports.NoopMeter = undefined;
|
|
17651
|
-
|
|
17652
|
-
class NoopMeter {
|
|
17653
|
-
constructor() {}
|
|
17654
|
-
createGauge(_name, _options) {
|
|
17655
|
-
return exports.NOOP_GAUGE_METRIC;
|
|
17656
|
-
}
|
|
17657
|
-
createHistogram(_name, _options) {
|
|
17658
|
-
return exports.NOOP_HISTOGRAM_METRIC;
|
|
17659
|
-
}
|
|
17660
|
-
createCounter(_name, _options) {
|
|
17661
|
-
return exports.NOOP_COUNTER_METRIC;
|
|
17662
|
-
}
|
|
17663
|
-
createUpDownCounter(_name, _options) {
|
|
17664
|
-
return exports.NOOP_UP_DOWN_COUNTER_METRIC;
|
|
17665
|
-
}
|
|
17666
|
-
createObservableGauge(_name, _options) {
|
|
17667
|
-
return exports.NOOP_OBSERVABLE_GAUGE_METRIC;
|
|
17668
|
-
}
|
|
17669
|
-
createObservableCounter(_name, _options) {
|
|
17670
|
-
return exports.NOOP_OBSERVABLE_COUNTER_METRIC;
|
|
17671
|
-
}
|
|
17672
|
-
createObservableUpDownCounter(_name, _options) {
|
|
17673
|
-
return exports.NOOP_OBSERVABLE_UP_DOWN_COUNTER_METRIC;
|
|
17674
|
-
}
|
|
17675
|
-
addBatchObservableCallback(_callback, _observables) {}
|
|
17676
|
-
removeBatchObservableCallback(_callback) {}
|
|
17677
|
-
}
|
|
17678
|
-
exports.NoopMeter = NoopMeter;
|
|
17679
|
-
|
|
17680
|
-
class NoopMetric {
|
|
17681
|
-
}
|
|
17682
|
-
exports.NoopMetric = NoopMetric;
|
|
17683
|
-
|
|
17684
|
-
class NoopCounterMetric extends NoopMetric {
|
|
17685
|
-
add(_value, _attributes) {}
|
|
17686
|
-
}
|
|
17687
|
-
exports.NoopCounterMetric = NoopCounterMetric;
|
|
17688
|
-
|
|
17689
|
-
class NoopUpDownCounterMetric extends NoopMetric {
|
|
17690
|
-
add(_value, _attributes) {}
|
|
17691
|
-
}
|
|
17692
|
-
exports.NoopUpDownCounterMetric = NoopUpDownCounterMetric;
|
|
17693
|
-
|
|
17694
|
-
class NoopGaugeMetric extends NoopMetric {
|
|
17695
|
-
record(_value, _attributes) {}
|
|
17696
|
-
}
|
|
17697
|
-
exports.NoopGaugeMetric = NoopGaugeMetric;
|
|
17698
|
-
|
|
17699
|
-
class NoopHistogramMetric extends NoopMetric {
|
|
17700
|
-
record(_value, _attributes) {}
|
|
17701
|
-
}
|
|
17702
|
-
exports.NoopHistogramMetric = NoopHistogramMetric;
|
|
17703
|
-
|
|
17704
|
-
class NoopObservableMetric {
|
|
17705
|
-
addCallback(_callback) {}
|
|
17706
|
-
removeCallback(_callback) {}
|
|
17707
|
-
}
|
|
17708
|
-
exports.NoopObservableMetric = NoopObservableMetric;
|
|
17709
|
-
|
|
17710
|
-
class NoopObservableCounterMetric extends NoopObservableMetric {
|
|
17711
|
-
}
|
|
17712
|
-
exports.NoopObservableCounterMetric = NoopObservableCounterMetric;
|
|
17713
|
-
|
|
17714
|
-
class NoopObservableGaugeMetric extends NoopObservableMetric {
|
|
17715
|
-
}
|
|
17716
|
-
exports.NoopObservableGaugeMetric = NoopObservableGaugeMetric;
|
|
17717
|
-
|
|
17718
|
-
class NoopObservableUpDownCounterMetric extends NoopObservableMetric {
|
|
17719
|
-
}
|
|
17720
|
-
exports.NoopObservableUpDownCounterMetric = NoopObservableUpDownCounterMetric;
|
|
17721
|
-
exports.NOOP_METER = new NoopMeter;
|
|
17722
|
-
exports.NOOP_COUNTER_METRIC = new NoopCounterMetric;
|
|
17723
|
-
exports.NOOP_GAUGE_METRIC = new NoopGaugeMetric;
|
|
17724
|
-
exports.NOOP_HISTOGRAM_METRIC = new NoopHistogramMetric;
|
|
17725
|
-
exports.NOOP_UP_DOWN_COUNTER_METRIC = new NoopUpDownCounterMetric;
|
|
17726
|
-
exports.NOOP_OBSERVABLE_COUNTER_METRIC = new NoopObservableCounterMetric;
|
|
17727
|
-
exports.NOOP_OBSERVABLE_GAUGE_METRIC = new NoopObservableGaugeMetric;
|
|
17728
|
-
exports.NOOP_OBSERVABLE_UP_DOWN_COUNTER_METRIC = new NoopObservableUpDownCounterMetric;
|
|
17729
|
-
function createNoopMeter() {
|
|
17730
|
-
return exports.NOOP_METER;
|
|
17731
|
-
}
|
|
17732
|
-
exports.createNoopMeter = createNoopMeter;
|
|
17733
|
-
});
|
|
17734
|
-
|
|
17735
|
-
// ../../node_modules/@opentelemetry/api/build/src/metrics/Metric.js
|
|
17736
|
-
var require_Metric = __commonJS((exports) => {
|
|
17737
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17738
|
-
exports.ValueType = undefined;
|
|
17739
|
-
var ValueType;
|
|
17740
|
-
(function(ValueType2) {
|
|
17741
|
-
ValueType2[ValueType2["INT"] = 0] = "INT";
|
|
17742
|
-
ValueType2[ValueType2["DOUBLE"] = 1] = "DOUBLE";
|
|
17743
|
-
})(ValueType = exports.ValueType || (exports.ValueType = {}));
|
|
17744
|
-
});
|
|
17745
|
-
|
|
17746
|
-
// ../../node_modules/@opentelemetry/api/build/src/propagation/TextMapPropagator.js
|
|
17747
|
-
var require_TextMapPropagator = __commonJS((exports) => {
|
|
17748
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17749
|
-
exports.defaultTextMapSetter = exports.defaultTextMapGetter = undefined;
|
|
17750
|
-
exports.defaultTextMapGetter = {
|
|
17751
|
-
get(carrier, key) {
|
|
17752
|
-
if (carrier == null) {
|
|
17753
|
-
return;
|
|
17754
|
-
}
|
|
17755
|
-
return carrier[key];
|
|
17756
|
-
},
|
|
17757
|
-
keys(carrier) {
|
|
17758
|
-
if (carrier == null) {
|
|
17759
|
-
return [];
|
|
17760
|
-
}
|
|
17761
|
-
return Object.keys(carrier);
|
|
17762
|
-
}
|
|
17763
|
-
};
|
|
17764
|
-
exports.defaultTextMapSetter = {
|
|
17765
|
-
set(carrier, key, value) {
|
|
17766
|
-
if (carrier == null) {
|
|
17767
|
-
return;
|
|
17768
|
-
}
|
|
17769
|
-
carrier[key] = value;
|
|
17770
|
-
}
|
|
17771
|
-
};
|
|
17772
|
-
});
|
|
17773
|
-
|
|
17774
|
-
// ../../node_modules/@opentelemetry/api/build/src/context/NoopContextManager.js
|
|
17775
|
-
var require_NoopContextManager = __commonJS((exports) => {
|
|
17776
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17777
|
-
exports.NoopContextManager = undefined;
|
|
17778
|
-
var context_1 = require_context();
|
|
17779
|
-
|
|
17780
|
-
class NoopContextManager {
|
|
17781
|
-
active() {
|
|
17782
|
-
return context_1.ROOT_CONTEXT;
|
|
17783
|
-
}
|
|
17784
|
-
with(_context, fn, thisArg, ...args) {
|
|
17785
|
-
return fn.call(thisArg, ...args);
|
|
17786
|
-
}
|
|
17787
|
-
bind(_context, target) {
|
|
17788
|
-
return target;
|
|
17789
|
-
}
|
|
17790
|
-
enable() {
|
|
17791
|
-
return this;
|
|
17792
|
-
}
|
|
17793
|
-
disable() {
|
|
17794
|
-
return this;
|
|
17795
|
-
}
|
|
17796
|
-
}
|
|
17797
|
-
exports.NoopContextManager = NoopContextManager;
|
|
17798
|
-
});
|
|
17799
|
-
|
|
17800
|
-
// ../../node_modules/@opentelemetry/api/build/src/api/context.js
|
|
17801
|
-
var require_context2 = __commonJS((exports) => {
|
|
17802
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17803
|
-
exports.ContextAPI = undefined;
|
|
17804
|
-
var NoopContextManager_1 = require_NoopContextManager();
|
|
17805
|
-
var global_utils_1 = require_global_utils();
|
|
17806
|
-
var diag_1 = require_diag();
|
|
17807
|
-
var API_NAME = "context";
|
|
17808
|
-
var NOOP_CONTEXT_MANAGER = new NoopContextManager_1.NoopContextManager;
|
|
17809
|
-
|
|
17810
|
-
class ContextAPI {
|
|
17811
|
-
constructor() {}
|
|
17812
|
-
static getInstance() {
|
|
17813
|
-
if (!this._instance) {
|
|
17814
|
-
this._instance = new ContextAPI;
|
|
17815
|
-
}
|
|
17816
|
-
return this._instance;
|
|
17817
|
-
}
|
|
17818
|
-
setGlobalContextManager(contextManager) {
|
|
17819
|
-
return (0, global_utils_1.registerGlobal)(API_NAME, contextManager, diag_1.DiagAPI.instance());
|
|
17820
|
-
}
|
|
17821
|
-
active() {
|
|
17822
|
-
return this._getContextManager().active();
|
|
17823
|
-
}
|
|
17824
|
-
with(context, fn, thisArg, ...args) {
|
|
17825
|
-
return this._getContextManager().with(context, fn, thisArg, ...args);
|
|
17826
|
-
}
|
|
17827
|
-
bind(context, target) {
|
|
17828
|
-
return this._getContextManager().bind(context, target);
|
|
17829
|
-
}
|
|
17830
|
-
_getContextManager() {
|
|
17831
|
-
return (0, global_utils_1.getGlobal)(API_NAME) || NOOP_CONTEXT_MANAGER;
|
|
17832
|
-
}
|
|
17833
|
-
disable() {
|
|
17834
|
-
this._getContextManager().disable();
|
|
17835
|
-
(0, global_utils_1.unregisterGlobal)(API_NAME, diag_1.DiagAPI.instance());
|
|
17836
|
-
}
|
|
17837
|
-
}
|
|
17838
|
-
exports.ContextAPI = ContextAPI;
|
|
17839
|
-
});
|
|
17840
|
-
|
|
17841
|
-
// ../../node_modules/@opentelemetry/api/build/src/trace/trace_flags.js
|
|
17842
|
-
var require_trace_flags = __commonJS((exports) => {
|
|
17843
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17844
|
-
exports.TraceFlags = undefined;
|
|
17845
|
-
var TraceFlags;
|
|
17846
|
-
(function(TraceFlags2) {
|
|
17847
|
-
TraceFlags2[TraceFlags2["NONE"] = 0] = "NONE";
|
|
17848
|
-
TraceFlags2[TraceFlags2["SAMPLED"] = 1] = "SAMPLED";
|
|
17849
|
-
})(TraceFlags = exports.TraceFlags || (exports.TraceFlags = {}));
|
|
17850
|
-
});
|
|
17851
|
-
|
|
17852
|
-
// ../../node_modules/@opentelemetry/api/build/src/trace/invalid-span-constants.js
|
|
17853
|
-
var require_invalid_span_constants = __commonJS((exports) => {
|
|
17854
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17855
|
-
exports.INVALID_SPAN_CONTEXT = exports.INVALID_TRACEID = exports.INVALID_SPANID = undefined;
|
|
17856
|
-
var trace_flags_1 = require_trace_flags();
|
|
17857
|
-
exports.INVALID_SPANID = "0000000000000000";
|
|
17858
|
-
exports.INVALID_TRACEID = "00000000000000000000000000000000";
|
|
17859
|
-
exports.INVALID_SPAN_CONTEXT = {
|
|
17860
|
-
traceId: exports.INVALID_TRACEID,
|
|
17861
|
-
spanId: exports.INVALID_SPANID,
|
|
17862
|
-
traceFlags: trace_flags_1.TraceFlags.NONE
|
|
17863
|
-
};
|
|
17864
|
-
});
|
|
17865
|
-
|
|
17866
|
-
// ../../node_modules/@opentelemetry/api/build/src/trace/NonRecordingSpan.js
|
|
17867
|
-
var require_NonRecordingSpan = __commonJS((exports) => {
|
|
17868
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17869
|
-
exports.NonRecordingSpan = undefined;
|
|
17870
|
-
var invalid_span_constants_1 = require_invalid_span_constants();
|
|
17871
|
-
|
|
17872
|
-
class NonRecordingSpan {
|
|
17873
|
-
constructor(spanContext = invalid_span_constants_1.INVALID_SPAN_CONTEXT) {
|
|
17874
|
-
this._spanContext = spanContext;
|
|
17875
|
-
}
|
|
17876
|
-
spanContext() {
|
|
17877
|
-
return this._spanContext;
|
|
17878
|
-
}
|
|
17879
|
-
setAttribute(_key, _value) {
|
|
17880
|
-
return this;
|
|
17881
|
-
}
|
|
17882
|
-
setAttributes(_attributes) {
|
|
17883
|
-
return this;
|
|
17884
|
-
}
|
|
17885
|
-
addEvent(_name, _attributes) {
|
|
17886
|
-
return this;
|
|
17887
|
-
}
|
|
17888
|
-
addLink(_link) {
|
|
17889
|
-
return this;
|
|
17890
|
-
}
|
|
17891
|
-
addLinks(_links) {
|
|
17892
|
-
return this;
|
|
17893
|
-
}
|
|
17894
|
-
setStatus(_status) {
|
|
17895
|
-
return this;
|
|
17896
|
-
}
|
|
17897
|
-
updateName(_name) {
|
|
17898
|
-
return this;
|
|
17899
|
-
}
|
|
17900
|
-
end(_endTime) {}
|
|
17901
|
-
isRecording() {
|
|
17902
|
-
return false;
|
|
17903
|
-
}
|
|
17904
|
-
recordException(_exception, _time) {}
|
|
17905
|
-
}
|
|
17906
|
-
exports.NonRecordingSpan = NonRecordingSpan;
|
|
17907
|
-
});
|
|
17908
|
-
|
|
17909
|
-
// ../../node_modules/@opentelemetry/api/build/src/trace/context-utils.js
|
|
17910
|
-
var require_context_utils = __commonJS((exports) => {
|
|
17911
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17912
|
-
exports.getSpanContext = exports.setSpanContext = exports.deleteSpan = exports.setSpan = exports.getActiveSpan = exports.getSpan = undefined;
|
|
17913
|
-
var context_1 = require_context();
|
|
17914
|
-
var NonRecordingSpan_1 = require_NonRecordingSpan();
|
|
17915
|
-
var context_2 = require_context2();
|
|
17916
|
-
var SPAN_KEY = (0, context_1.createContextKey)("OpenTelemetry Context Key SPAN");
|
|
17917
|
-
function getSpan(context) {
|
|
17918
|
-
return context.getValue(SPAN_KEY) || undefined;
|
|
17919
|
-
}
|
|
17920
|
-
exports.getSpan = getSpan;
|
|
17921
|
-
function getActiveSpan() {
|
|
17922
|
-
return getSpan(context_2.ContextAPI.getInstance().active());
|
|
17923
|
-
}
|
|
17924
|
-
exports.getActiveSpan = getActiveSpan;
|
|
17925
|
-
function setSpan(context, span) {
|
|
17926
|
-
return context.setValue(SPAN_KEY, span);
|
|
17927
|
-
}
|
|
17928
|
-
exports.setSpan = setSpan;
|
|
17929
|
-
function deleteSpan(context) {
|
|
17930
|
-
return context.deleteValue(SPAN_KEY);
|
|
17931
|
-
}
|
|
17932
|
-
exports.deleteSpan = deleteSpan;
|
|
17933
|
-
function setSpanContext(context, spanContext) {
|
|
17934
|
-
return setSpan(context, new NonRecordingSpan_1.NonRecordingSpan(spanContext));
|
|
17935
|
-
}
|
|
17936
|
-
exports.setSpanContext = setSpanContext;
|
|
17937
|
-
function getSpanContext(context) {
|
|
17938
|
-
var _a3;
|
|
17939
|
-
return (_a3 = getSpan(context)) === null || _a3 === undefined ? undefined : _a3.spanContext();
|
|
17940
|
-
}
|
|
17941
|
-
exports.getSpanContext = getSpanContext;
|
|
17942
|
-
});
|
|
17943
|
-
|
|
17944
|
-
// ../../node_modules/@opentelemetry/api/build/src/trace/spancontext-utils.js
|
|
17945
|
-
var require_spancontext_utils = __commonJS((exports) => {
|
|
17946
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17947
|
-
exports.wrapSpanContext = exports.isSpanContextValid = exports.isValidSpanId = exports.isValidTraceId = undefined;
|
|
17948
|
-
var invalid_span_constants_1 = require_invalid_span_constants();
|
|
17949
|
-
var NonRecordingSpan_1 = require_NonRecordingSpan();
|
|
17950
|
-
var isHex = new Uint8Array([
|
|
17951
|
-
0,
|
|
17952
|
-
0,
|
|
17953
|
-
0,
|
|
17954
|
-
0,
|
|
17955
|
-
0,
|
|
17956
|
-
0,
|
|
17957
|
-
0,
|
|
17958
|
-
0,
|
|
17959
|
-
0,
|
|
17960
|
-
0,
|
|
17961
|
-
0,
|
|
17962
|
-
0,
|
|
17963
|
-
0,
|
|
17964
|
-
0,
|
|
17965
|
-
0,
|
|
17966
|
-
0,
|
|
17967
|
-
0,
|
|
17968
|
-
0,
|
|
17969
|
-
0,
|
|
17970
|
-
0,
|
|
17971
|
-
0,
|
|
17972
|
-
0,
|
|
17973
|
-
0,
|
|
17974
|
-
0,
|
|
17975
|
-
0,
|
|
17976
|
-
0,
|
|
17977
|
-
0,
|
|
17978
|
-
0,
|
|
17979
|
-
0,
|
|
17980
|
-
0,
|
|
17981
|
-
0,
|
|
17982
|
-
0,
|
|
17983
|
-
0,
|
|
17984
|
-
0,
|
|
17985
|
-
0,
|
|
17986
|
-
0,
|
|
17987
|
-
0,
|
|
17988
|
-
0,
|
|
17989
|
-
0,
|
|
17990
|
-
0,
|
|
17991
|
-
0,
|
|
17992
|
-
0,
|
|
17993
|
-
0,
|
|
17994
|
-
0,
|
|
17995
|
-
0,
|
|
17996
|
-
0,
|
|
17997
|
-
0,
|
|
17998
|
-
0,
|
|
17999
|
-
1,
|
|
18000
|
-
1,
|
|
18001
|
-
1,
|
|
18002
|
-
1,
|
|
18003
|
-
1,
|
|
18004
|
-
1,
|
|
18005
|
-
1,
|
|
18006
|
-
1,
|
|
18007
|
-
1,
|
|
18008
|
-
1,
|
|
18009
|
-
0,
|
|
18010
|
-
0,
|
|
18011
|
-
0,
|
|
18012
|
-
0,
|
|
18013
|
-
0,
|
|
18014
|
-
0,
|
|
18015
|
-
0,
|
|
18016
|
-
1,
|
|
18017
|
-
1,
|
|
18018
|
-
1,
|
|
18019
|
-
1,
|
|
18020
|
-
1,
|
|
18021
|
-
1,
|
|
18022
|
-
0,
|
|
18023
|
-
0,
|
|
18024
|
-
0,
|
|
18025
|
-
0,
|
|
18026
|
-
0,
|
|
18027
|
-
0,
|
|
18028
|
-
0,
|
|
18029
|
-
0,
|
|
18030
|
-
0,
|
|
18031
|
-
0,
|
|
18032
|
-
0,
|
|
18033
|
-
0,
|
|
18034
|
-
0,
|
|
18035
|
-
0,
|
|
18036
|
-
0,
|
|
18037
|
-
0,
|
|
18038
|
-
0,
|
|
18039
|
-
0,
|
|
18040
|
-
0,
|
|
18041
|
-
0,
|
|
18042
|
-
0,
|
|
18043
|
-
0,
|
|
18044
|
-
0,
|
|
18045
|
-
0,
|
|
18046
|
-
0,
|
|
18047
|
-
0,
|
|
18048
|
-
1,
|
|
18049
|
-
1,
|
|
18050
|
-
1,
|
|
18051
|
-
1,
|
|
18052
|
-
1,
|
|
18053
|
-
1
|
|
18054
|
-
]);
|
|
18055
|
-
function isValidHex(id, length) {
|
|
18056
|
-
if (typeof id !== "string" || id.length !== length)
|
|
18057
|
-
return false;
|
|
18058
|
-
let r = 0;
|
|
18059
|
-
for (let i = 0;i < id.length; i += 4) {
|
|
18060
|
-
r += (isHex[id.charCodeAt(i)] | 0) + (isHex[id.charCodeAt(i + 1)] | 0) + (isHex[id.charCodeAt(i + 2)] | 0) + (isHex[id.charCodeAt(i + 3)] | 0);
|
|
18061
|
-
}
|
|
18062
|
-
return r === length;
|
|
18063
|
-
}
|
|
18064
|
-
function isValidTraceId(traceId) {
|
|
18065
|
-
return isValidHex(traceId, 32) && traceId !== invalid_span_constants_1.INVALID_TRACEID;
|
|
18066
|
-
}
|
|
18067
|
-
exports.isValidTraceId = isValidTraceId;
|
|
18068
|
-
function isValidSpanId(spanId) {
|
|
18069
|
-
return isValidHex(spanId, 16) && spanId !== invalid_span_constants_1.INVALID_SPANID;
|
|
18070
|
-
}
|
|
18071
|
-
exports.isValidSpanId = isValidSpanId;
|
|
18072
|
-
function isSpanContextValid(spanContext) {
|
|
18073
|
-
return isValidTraceId(spanContext.traceId) && isValidSpanId(spanContext.spanId);
|
|
18074
|
-
}
|
|
18075
|
-
exports.isSpanContextValid = isSpanContextValid;
|
|
18076
|
-
function wrapSpanContext(spanContext) {
|
|
18077
|
-
return new NonRecordingSpan_1.NonRecordingSpan(spanContext);
|
|
18078
|
-
}
|
|
18079
|
-
exports.wrapSpanContext = wrapSpanContext;
|
|
18080
|
-
});
|
|
18081
|
-
|
|
18082
|
-
// ../../node_modules/@opentelemetry/api/build/src/trace/NoopTracer.js
|
|
18083
|
-
var require_NoopTracer = __commonJS((exports) => {
|
|
18084
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18085
|
-
exports.NoopTracer = undefined;
|
|
18086
|
-
var context_1 = require_context2();
|
|
18087
|
-
var context_utils_1 = require_context_utils();
|
|
18088
|
-
var NonRecordingSpan_1 = require_NonRecordingSpan();
|
|
18089
|
-
var spancontext_utils_1 = require_spancontext_utils();
|
|
18090
|
-
var contextApi = context_1.ContextAPI.getInstance();
|
|
18091
|
-
|
|
18092
|
-
class NoopTracer {
|
|
18093
|
-
startSpan(name, options, context = contextApi.active()) {
|
|
18094
|
-
const root = Boolean(options === null || options === undefined ? undefined : options.root);
|
|
18095
|
-
if (root) {
|
|
18096
|
-
return new NonRecordingSpan_1.NonRecordingSpan;
|
|
18097
|
-
}
|
|
18098
|
-
const parentFromContext = context && (0, context_utils_1.getSpanContext)(context);
|
|
18099
|
-
if (isSpanContext(parentFromContext) && (0, spancontext_utils_1.isSpanContextValid)(parentFromContext)) {
|
|
18100
|
-
return new NonRecordingSpan_1.NonRecordingSpan(parentFromContext);
|
|
18101
|
-
} else {
|
|
18102
|
-
return new NonRecordingSpan_1.NonRecordingSpan;
|
|
18103
|
-
}
|
|
18104
|
-
}
|
|
18105
|
-
startActiveSpan(name, arg2, arg3, arg4) {
|
|
18106
|
-
let opts;
|
|
18107
|
-
let ctx;
|
|
18108
|
-
let fn;
|
|
18109
|
-
if (arguments.length < 2) {
|
|
18110
|
-
return;
|
|
18111
|
-
} else if (arguments.length === 2) {
|
|
18112
|
-
fn = arg2;
|
|
18113
|
-
} else if (arguments.length === 3) {
|
|
18114
|
-
opts = arg2;
|
|
18115
|
-
fn = arg3;
|
|
18116
|
-
} else {
|
|
18117
|
-
opts = arg2;
|
|
18118
|
-
ctx = arg3;
|
|
18119
|
-
fn = arg4;
|
|
18120
|
-
}
|
|
18121
|
-
const parentContext = ctx !== null && ctx !== undefined ? ctx : contextApi.active();
|
|
18122
|
-
const span = this.startSpan(name, opts, parentContext);
|
|
18123
|
-
const contextWithSpanSet = (0, context_utils_1.setSpan)(parentContext, span);
|
|
18124
|
-
return contextApi.with(contextWithSpanSet, fn, undefined, span);
|
|
18125
|
-
}
|
|
18126
|
-
}
|
|
18127
|
-
exports.NoopTracer = NoopTracer;
|
|
18128
|
-
function isSpanContext(spanContext) {
|
|
18129
|
-
return spanContext !== null && typeof spanContext === "object" && "spanId" in spanContext && typeof spanContext["spanId"] === "string" && "traceId" in spanContext && typeof spanContext["traceId"] === "string" && "traceFlags" in spanContext && typeof spanContext["traceFlags"] === "number";
|
|
18130
|
-
}
|
|
18131
|
-
});
|
|
18132
|
-
|
|
18133
|
-
// ../../node_modules/@opentelemetry/api/build/src/trace/ProxyTracer.js
|
|
18134
|
-
var require_ProxyTracer = __commonJS((exports) => {
|
|
18135
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18136
|
-
exports.ProxyTracer = undefined;
|
|
18137
|
-
var NoopTracer_1 = require_NoopTracer();
|
|
18138
|
-
var NOOP_TRACER = new NoopTracer_1.NoopTracer;
|
|
18139
|
-
|
|
18140
|
-
class ProxyTracer {
|
|
18141
|
-
constructor(provider, name, version2, options) {
|
|
18142
|
-
this._provider = provider;
|
|
18143
|
-
this.name = name;
|
|
18144
|
-
this.version = version2;
|
|
18145
|
-
this.options = options;
|
|
18146
|
-
}
|
|
18147
|
-
startSpan(name, options, context) {
|
|
18148
|
-
return this._getTracer().startSpan(name, options, context);
|
|
18149
|
-
}
|
|
18150
|
-
startActiveSpan(_name, _options, _context, _fn) {
|
|
18151
|
-
const tracer = this._getTracer();
|
|
18152
|
-
return Reflect.apply(tracer.startActiveSpan, tracer, arguments);
|
|
18153
|
-
}
|
|
18154
|
-
_getTracer() {
|
|
18155
|
-
if (this._delegate) {
|
|
18156
|
-
return this._delegate;
|
|
18157
|
-
}
|
|
18158
|
-
const tracer = this._provider.getDelegateTracer(this.name, this.version, this.options);
|
|
18159
|
-
if (!tracer) {
|
|
18160
|
-
return NOOP_TRACER;
|
|
18161
|
-
}
|
|
18162
|
-
this._delegate = tracer;
|
|
18163
|
-
return this._delegate;
|
|
18164
|
-
}
|
|
18165
|
-
}
|
|
18166
|
-
exports.ProxyTracer = ProxyTracer;
|
|
18167
|
-
});
|
|
18168
|
-
|
|
18169
|
-
// ../../node_modules/@opentelemetry/api/build/src/trace/NoopTracerProvider.js
|
|
18170
|
-
var require_NoopTracerProvider = __commonJS((exports) => {
|
|
18171
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18172
|
-
exports.NoopTracerProvider = undefined;
|
|
18173
|
-
var NoopTracer_1 = require_NoopTracer();
|
|
18174
|
-
|
|
18175
|
-
class NoopTracerProvider {
|
|
18176
|
-
getTracer(_name, _version, _options) {
|
|
18177
|
-
return new NoopTracer_1.NoopTracer;
|
|
18178
|
-
}
|
|
18179
|
-
}
|
|
18180
|
-
exports.NoopTracerProvider = NoopTracerProvider;
|
|
18181
|
-
});
|
|
18182
|
-
|
|
18183
|
-
// ../../node_modules/@opentelemetry/api/build/src/trace/ProxyTracerProvider.js
|
|
18184
|
-
var require_ProxyTracerProvider = __commonJS((exports) => {
|
|
18185
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18186
|
-
exports.ProxyTracerProvider = undefined;
|
|
18187
|
-
var ProxyTracer_1 = require_ProxyTracer();
|
|
18188
|
-
var NoopTracerProvider_1 = require_NoopTracerProvider();
|
|
18189
|
-
var NOOP_TRACER_PROVIDER = new NoopTracerProvider_1.NoopTracerProvider;
|
|
18190
|
-
|
|
18191
|
-
class ProxyTracerProvider {
|
|
18192
|
-
getTracer(name, version2, options) {
|
|
18193
|
-
var _a3;
|
|
18194
|
-
return (_a3 = this.getDelegateTracer(name, version2, options)) !== null && _a3 !== undefined ? _a3 : new ProxyTracer_1.ProxyTracer(this, name, version2, options);
|
|
18195
|
-
}
|
|
18196
|
-
getDelegate() {
|
|
18197
|
-
var _a3;
|
|
18198
|
-
return (_a3 = this._delegate) !== null && _a3 !== undefined ? _a3 : NOOP_TRACER_PROVIDER;
|
|
18199
|
-
}
|
|
18200
|
-
setDelegate(delegate) {
|
|
18201
|
-
this._delegate = delegate;
|
|
18202
|
-
}
|
|
18203
|
-
getDelegateTracer(name, version2, options) {
|
|
18204
|
-
var _a3;
|
|
18205
|
-
return (_a3 = this._delegate) === null || _a3 === undefined ? undefined : _a3.getTracer(name, version2, options);
|
|
18206
|
-
}
|
|
18207
|
-
}
|
|
18208
|
-
exports.ProxyTracerProvider = ProxyTracerProvider;
|
|
18209
|
-
});
|
|
18210
|
-
|
|
18211
|
-
// ../../node_modules/@opentelemetry/api/build/src/trace/SamplingResult.js
|
|
18212
|
-
var require_SamplingResult = __commonJS((exports) => {
|
|
18213
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18214
|
-
exports.SamplingDecision = undefined;
|
|
18215
|
-
var SamplingDecision;
|
|
18216
|
-
(function(SamplingDecision2) {
|
|
18217
|
-
SamplingDecision2[SamplingDecision2["NOT_RECORD"] = 0] = "NOT_RECORD";
|
|
18218
|
-
SamplingDecision2[SamplingDecision2["RECORD"] = 1] = "RECORD";
|
|
18219
|
-
SamplingDecision2[SamplingDecision2["RECORD_AND_SAMPLED"] = 2] = "RECORD_AND_SAMPLED";
|
|
18220
|
-
})(SamplingDecision = exports.SamplingDecision || (exports.SamplingDecision = {}));
|
|
18221
|
-
});
|
|
18222
|
-
|
|
18223
|
-
// ../../node_modules/@opentelemetry/api/build/src/trace/span_kind.js
|
|
18224
|
-
var require_span_kind = __commonJS((exports) => {
|
|
18225
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18226
|
-
exports.SpanKind = undefined;
|
|
18227
|
-
var SpanKind;
|
|
18228
|
-
(function(SpanKind2) {
|
|
18229
|
-
SpanKind2[SpanKind2["INTERNAL"] = 0] = "INTERNAL";
|
|
18230
|
-
SpanKind2[SpanKind2["SERVER"] = 1] = "SERVER";
|
|
18231
|
-
SpanKind2[SpanKind2["CLIENT"] = 2] = "CLIENT";
|
|
18232
|
-
SpanKind2[SpanKind2["PRODUCER"] = 3] = "PRODUCER";
|
|
18233
|
-
SpanKind2[SpanKind2["CONSUMER"] = 4] = "CONSUMER";
|
|
18234
|
-
})(SpanKind = exports.SpanKind || (exports.SpanKind = {}));
|
|
18235
|
-
});
|
|
18236
|
-
|
|
18237
|
-
// ../../node_modules/@opentelemetry/api/build/src/trace/status.js
|
|
18238
|
-
var require_status = __commonJS((exports) => {
|
|
18239
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18240
|
-
exports.SpanStatusCode = undefined;
|
|
18241
|
-
var SpanStatusCode;
|
|
18242
|
-
(function(SpanStatusCode2) {
|
|
18243
|
-
SpanStatusCode2[SpanStatusCode2["UNSET"] = 0] = "UNSET";
|
|
18244
|
-
SpanStatusCode2[SpanStatusCode2["OK"] = 1] = "OK";
|
|
18245
|
-
SpanStatusCode2[SpanStatusCode2["ERROR"] = 2] = "ERROR";
|
|
18246
|
-
})(SpanStatusCode = exports.SpanStatusCode || (exports.SpanStatusCode = {}));
|
|
18247
|
-
});
|
|
18248
|
-
|
|
18249
|
-
// ../../node_modules/@opentelemetry/api/build/src/trace/internal/tracestate-validators.js
|
|
18250
|
-
var require_tracestate_validators = __commonJS((exports) => {
|
|
18251
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18252
|
-
exports.validateValue = exports.validateKey = undefined;
|
|
18253
|
-
var VALID_KEY_CHAR_RANGE = "[_0-9a-z-*/]";
|
|
18254
|
-
var VALID_KEY = `[a-z]${VALID_KEY_CHAR_RANGE}{0,255}`;
|
|
18255
|
-
var VALID_VENDOR_KEY = `[a-z0-9]${VALID_KEY_CHAR_RANGE}{0,240}@[a-z]${VALID_KEY_CHAR_RANGE}{0,13}`;
|
|
18256
|
-
var VALID_KEY_REGEX = new RegExp(`^(?:${VALID_KEY}|${VALID_VENDOR_KEY})$`);
|
|
18257
|
-
var VALID_VALUE_BASE_REGEX = /^[ -~]{0,255}[!-~]$/;
|
|
18258
|
-
var INVALID_VALUE_COMMA_EQUAL_REGEX = /,|=/;
|
|
18259
|
-
function validateKey(key) {
|
|
18260
|
-
return VALID_KEY_REGEX.test(key);
|
|
18261
|
-
}
|
|
18262
|
-
exports.validateKey = validateKey;
|
|
18263
|
-
function validateValue(value) {
|
|
18264
|
-
return VALID_VALUE_BASE_REGEX.test(value) && !INVALID_VALUE_COMMA_EQUAL_REGEX.test(value);
|
|
18265
|
-
}
|
|
18266
|
-
exports.validateValue = validateValue;
|
|
18267
|
-
});
|
|
18268
|
-
|
|
18269
|
-
// ../../node_modules/@opentelemetry/api/build/src/trace/internal/tracestate-impl.js
|
|
18270
|
-
var require_tracestate_impl = __commonJS((exports) => {
|
|
18271
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18272
|
-
exports.TraceStateImpl = undefined;
|
|
18273
|
-
var tracestate_validators_1 = require_tracestate_validators();
|
|
18274
|
-
var MAX_TRACE_STATE_ITEMS = 32;
|
|
18275
|
-
var MAX_TRACE_STATE_LEN = 512;
|
|
18276
|
-
var LIST_MEMBERS_SEPARATOR = ",";
|
|
18277
|
-
var LIST_MEMBER_KEY_VALUE_SPLITTER = "=";
|
|
18278
|
-
|
|
18279
|
-
class TraceStateImpl {
|
|
18280
|
-
constructor(rawTraceState) {
|
|
18281
|
-
this._internalState = new Map;
|
|
18282
|
-
if (rawTraceState)
|
|
18283
|
-
this._parse(rawTraceState);
|
|
18284
|
-
}
|
|
18285
|
-
set(key, value) {
|
|
18286
|
-
const traceState = this._clone();
|
|
18287
|
-
if (traceState._internalState.has(key)) {
|
|
18288
|
-
traceState._internalState.delete(key);
|
|
18289
|
-
}
|
|
18290
|
-
traceState._internalState.set(key, value);
|
|
18291
|
-
return traceState;
|
|
18292
|
-
}
|
|
18293
|
-
unset(key) {
|
|
18294
|
-
const traceState = this._clone();
|
|
18295
|
-
traceState._internalState.delete(key);
|
|
18296
|
-
return traceState;
|
|
18297
|
-
}
|
|
18298
|
-
get(key) {
|
|
18299
|
-
return this._internalState.get(key);
|
|
18300
|
-
}
|
|
18301
|
-
serialize() {
|
|
18302
|
-
return Array.from(this._internalState.keys()).reduceRight((agg, key) => {
|
|
18303
|
-
agg.push(key + LIST_MEMBER_KEY_VALUE_SPLITTER + this.get(key));
|
|
18304
|
-
return agg;
|
|
18305
|
-
}, []).join(LIST_MEMBERS_SEPARATOR);
|
|
18306
|
-
}
|
|
18307
|
-
_parse(rawTraceState) {
|
|
18308
|
-
if (rawTraceState.length > MAX_TRACE_STATE_LEN)
|
|
18309
|
-
return;
|
|
18310
|
-
this._internalState = rawTraceState.split(LIST_MEMBERS_SEPARATOR).reduceRight((agg, part) => {
|
|
18311
|
-
const listMember = part.trim();
|
|
18312
|
-
const i = listMember.indexOf(LIST_MEMBER_KEY_VALUE_SPLITTER);
|
|
18313
|
-
if (i !== -1) {
|
|
18314
|
-
const key = listMember.slice(0, i);
|
|
18315
|
-
const value = listMember.slice(i + 1, part.length);
|
|
18316
|
-
if ((0, tracestate_validators_1.validateKey)(key) && (0, tracestate_validators_1.validateValue)(value)) {
|
|
18317
|
-
agg.set(key, value);
|
|
18318
|
-
}
|
|
18319
|
-
}
|
|
18320
|
-
return agg;
|
|
18321
|
-
}, new Map);
|
|
18322
|
-
if (this._internalState.size > MAX_TRACE_STATE_ITEMS) {
|
|
18323
|
-
this._internalState = new Map(Array.from(this._internalState.entries()).reverse().slice(0, MAX_TRACE_STATE_ITEMS));
|
|
18324
|
-
}
|
|
18325
|
-
}
|
|
18326
|
-
_keys() {
|
|
18327
|
-
return Array.from(this._internalState.keys()).reverse();
|
|
18328
|
-
}
|
|
18329
|
-
_clone() {
|
|
18330
|
-
const traceState = new TraceStateImpl;
|
|
18331
|
-
traceState._internalState = new Map(this._internalState);
|
|
18332
|
-
return traceState;
|
|
18333
|
-
}
|
|
18334
|
-
}
|
|
18335
|
-
exports.TraceStateImpl = TraceStateImpl;
|
|
18336
|
-
});
|
|
18337
|
-
|
|
18338
|
-
// ../../node_modules/@opentelemetry/api/build/src/trace/internal/utils.js
|
|
18339
|
-
var require_utils2 = __commonJS((exports) => {
|
|
18340
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18341
|
-
exports.createTraceState = undefined;
|
|
18342
|
-
var tracestate_impl_1 = require_tracestate_impl();
|
|
18343
|
-
function createTraceState(rawTraceState) {
|
|
18344
|
-
return new tracestate_impl_1.TraceStateImpl(rawTraceState);
|
|
18345
|
-
}
|
|
18346
|
-
exports.createTraceState = createTraceState;
|
|
18347
|
-
});
|
|
18348
|
-
|
|
18349
|
-
// ../../node_modules/@opentelemetry/api/build/src/context-api.js
|
|
18350
|
-
var require_context_api = __commonJS((exports) => {
|
|
18351
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18352
|
-
exports.context = undefined;
|
|
18353
|
-
var context_1 = require_context2();
|
|
18354
|
-
exports.context = context_1.ContextAPI.getInstance();
|
|
18355
|
-
});
|
|
18356
|
-
|
|
18357
|
-
// ../../node_modules/@opentelemetry/api/build/src/diag-api.js
|
|
18358
|
-
var require_diag_api = __commonJS((exports) => {
|
|
18359
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18360
|
-
exports.diag = undefined;
|
|
18361
|
-
var diag_1 = require_diag();
|
|
18362
|
-
exports.diag = diag_1.DiagAPI.instance();
|
|
18363
|
-
});
|
|
18364
|
-
|
|
18365
|
-
// ../../node_modules/@opentelemetry/api/build/src/metrics/NoopMeterProvider.js
|
|
18366
|
-
var require_NoopMeterProvider = __commonJS((exports) => {
|
|
18367
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18368
|
-
exports.NOOP_METER_PROVIDER = exports.NoopMeterProvider = undefined;
|
|
18369
|
-
var NoopMeter_1 = require_NoopMeter();
|
|
18370
|
-
|
|
18371
|
-
class NoopMeterProvider {
|
|
18372
|
-
getMeter(_name, _version, _options) {
|
|
18373
|
-
return NoopMeter_1.NOOP_METER;
|
|
18374
|
-
}
|
|
18375
|
-
}
|
|
18376
|
-
exports.NoopMeterProvider = NoopMeterProvider;
|
|
18377
|
-
exports.NOOP_METER_PROVIDER = new NoopMeterProvider;
|
|
18378
|
-
});
|
|
18379
|
-
|
|
18380
|
-
// ../../node_modules/@opentelemetry/api/build/src/api/metrics.js
|
|
18381
|
-
var require_metrics = __commonJS((exports) => {
|
|
18382
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18383
|
-
exports.MetricsAPI = undefined;
|
|
18384
|
-
var NoopMeterProvider_1 = require_NoopMeterProvider();
|
|
18385
|
-
var global_utils_1 = require_global_utils();
|
|
18386
|
-
var diag_1 = require_diag();
|
|
18387
|
-
var API_NAME = "metrics";
|
|
18388
|
-
|
|
18389
|
-
class MetricsAPI {
|
|
18390
|
-
constructor() {}
|
|
18391
|
-
static getInstance() {
|
|
18392
|
-
if (!this._instance) {
|
|
18393
|
-
this._instance = new MetricsAPI;
|
|
18394
|
-
}
|
|
18395
|
-
return this._instance;
|
|
18396
|
-
}
|
|
18397
|
-
setGlobalMeterProvider(provider) {
|
|
18398
|
-
return (0, global_utils_1.registerGlobal)(API_NAME, provider, diag_1.DiagAPI.instance());
|
|
18399
|
-
}
|
|
18400
|
-
getMeterProvider() {
|
|
18401
|
-
return (0, global_utils_1.getGlobal)(API_NAME) || NoopMeterProvider_1.NOOP_METER_PROVIDER;
|
|
18402
|
-
}
|
|
18403
|
-
getMeter(name, version2, options) {
|
|
18404
|
-
return this.getMeterProvider().getMeter(name, version2, options);
|
|
18405
|
-
}
|
|
18406
|
-
disable() {
|
|
18407
|
-
(0, global_utils_1.unregisterGlobal)(API_NAME, diag_1.DiagAPI.instance());
|
|
18408
|
-
}
|
|
18409
|
-
}
|
|
18410
|
-
exports.MetricsAPI = MetricsAPI;
|
|
18411
|
-
});
|
|
18412
|
-
|
|
18413
|
-
// ../../node_modules/@opentelemetry/api/build/src/metrics-api.js
|
|
18414
|
-
var require_metrics_api = __commonJS((exports) => {
|
|
18415
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18416
|
-
exports.metrics = undefined;
|
|
18417
|
-
var metrics_1 = require_metrics();
|
|
18418
|
-
exports.metrics = metrics_1.MetricsAPI.getInstance();
|
|
18419
|
-
});
|
|
18420
|
-
|
|
18421
|
-
// ../../node_modules/@opentelemetry/api/build/src/propagation/NoopTextMapPropagator.js
|
|
18422
|
-
var require_NoopTextMapPropagator = __commonJS((exports) => {
|
|
18423
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18424
|
-
exports.NoopTextMapPropagator = undefined;
|
|
18425
|
-
|
|
18426
|
-
class NoopTextMapPropagator {
|
|
18427
|
-
inject(_context, _carrier) {}
|
|
18428
|
-
extract(context, _carrier) {
|
|
18429
|
-
return context;
|
|
18430
|
-
}
|
|
18431
|
-
fields() {
|
|
18432
|
-
return [];
|
|
18433
|
-
}
|
|
18434
|
-
}
|
|
18435
|
-
exports.NoopTextMapPropagator = NoopTextMapPropagator;
|
|
18436
|
-
});
|
|
18437
|
-
|
|
18438
|
-
// ../../node_modules/@opentelemetry/api/build/src/baggage/context-helpers.js
|
|
18439
|
-
var require_context_helpers = __commonJS((exports) => {
|
|
18440
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18441
|
-
exports.deleteBaggage = exports.setBaggage = exports.getActiveBaggage = exports.getBaggage = undefined;
|
|
18442
|
-
var context_1 = require_context2();
|
|
18443
|
-
var context_2 = require_context();
|
|
18444
|
-
var BAGGAGE_KEY = (0, context_2.createContextKey)("OpenTelemetry Baggage Key");
|
|
18445
|
-
function getBaggage(context) {
|
|
18446
|
-
return context.getValue(BAGGAGE_KEY) || undefined;
|
|
18447
|
-
}
|
|
18448
|
-
exports.getBaggage = getBaggage;
|
|
18449
|
-
function getActiveBaggage() {
|
|
18450
|
-
return getBaggage(context_1.ContextAPI.getInstance().active());
|
|
18451
|
-
}
|
|
18452
|
-
exports.getActiveBaggage = getActiveBaggage;
|
|
18453
|
-
function setBaggage(context, baggage) {
|
|
18454
|
-
return context.setValue(BAGGAGE_KEY, baggage);
|
|
18455
|
-
}
|
|
18456
|
-
exports.setBaggage = setBaggage;
|
|
18457
|
-
function deleteBaggage(context) {
|
|
18458
|
-
return context.deleteValue(BAGGAGE_KEY);
|
|
18459
|
-
}
|
|
18460
|
-
exports.deleteBaggage = deleteBaggage;
|
|
18461
|
-
});
|
|
18462
|
-
|
|
18463
|
-
// ../../node_modules/@opentelemetry/api/build/src/api/propagation.js
|
|
18464
|
-
var require_propagation = __commonJS((exports) => {
|
|
18465
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18466
|
-
exports.PropagationAPI = undefined;
|
|
18467
|
-
var global_utils_1 = require_global_utils();
|
|
18468
|
-
var NoopTextMapPropagator_1 = require_NoopTextMapPropagator();
|
|
18469
|
-
var TextMapPropagator_1 = require_TextMapPropagator();
|
|
18470
|
-
var context_helpers_1 = require_context_helpers();
|
|
18471
|
-
var utils_1 = require_utils();
|
|
18472
|
-
var diag_1 = require_diag();
|
|
18473
|
-
var API_NAME = "propagation";
|
|
18474
|
-
var NOOP_TEXT_MAP_PROPAGATOR = new NoopTextMapPropagator_1.NoopTextMapPropagator;
|
|
18475
|
-
|
|
18476
|
-
class PropagationAPI {
|
|
18477
|
-
constructor() {
|
|
18478
|
-
this.createBaggage = utils_1.createBaggage;
|
|
18479
|
-
this.getBaggage = context_helpers_1.getBaggage;
|
|
18480
|
-
this.getActiveBaggage = context_helpers_1.getActiveBaggage;
|
|
18481
|
-
this.setBaggage = context_helpers_1.setBaggage;
|
|
18482
|
-
this.deleteBaggage = context_helpers_1.deleteBaggage;
|
|
18483
|
-
}
|
|
18484
|
-
static getInstance() {
|
|
18485
|
-
if (!this._instance) {
|
|
18486
|
-
this._instance = new PropagationAPI;
|
|
18487
|
-
}
|
|
18488
|
-
return this._instance;
|
|
18489
|
-
}
|
|
18490
|
-
setGlobalPropagator(propagator) {
|
|
18491
|
-
return (0, global_utils_1.registerGlobal)(API_NAME, propagator, diag_1.DiagAPI.instance());
|
|
18492
|
-
}
|
|
18493
|
-
inject(context, carrier, setter = TextMapPropagator_1.defaultTextMapSetter) {
|
|
18494
|
-
return this._getGlobalPropagator().inject(context, carrier, setter);
|
|
18495
|
-
}
|
|
18496
|
-
extract(context, carrier, getter = TextMapPropagator_1.defaultTextMapGetter) {
|
|
18497
|
-
return this._getGlobalPropagator().extract(context, carrier, getter);
|
|
18498
|
-
}
|
|
18499
|
-
fields() {
|
|
18500
|
-
return this._getGlobalPropagator().fields();
|
|
18501
|
-
}
|
|
18502
|
-
disable() {
|
|
18503
|
-
(0, global_utils_1.unregisterGlobal)(API_NAME, diag_1.DiagAPI.instance());
|
|
18504
|
-
}
|
|
18505
|
-
_getGlobalPropagator() {
|
|
18506
|
-
return (0, global_utils_1.getGlobal)(API_NAME) || NOOP_TEXT_MAP_PROPAGATOR;
|
|
18507
|
-
}
|
|
18508
|
-
}
|
|
18509
|
-
exports.PropagationAPI = PropagationAPI;
|
|
18510
|
-
});
|
|
18511
|
-
|
|
18512
|
-
// ../../node_modules/@opentelemetry/api/build/src/propagation-api.js
|
|
18513
|
-
var require_propagation_api = __commonJS((exports) => {
|
|
18514
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18515
|
-
exports.propagation = undefined;
|
|
18516
|
-
var propagation_1 = require_propagation();
|
|
18517
|
-
exports.propagation = propagation_1.PropagationAPI.getInstance();
|
|
18518
|
-
});
|
|
18519
|
-
|
|
18520
|
-
// ../../node_modules/@opentelemetry/api/build/src/api/trace.js
|
|
18521
|
-
var require_trace = __commonJS((exports) => {
|
|
18522
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18523
|
-
exports.TraceAPI = undefined;
|
|
18524
|
-
var global_utils_1 = require_global_utils();
|
|
18525
|
-
var ProxyTracerProvider_1 = require_ProxyTracerProvider();
|
|
18526
|
-
var spancontext_utils_1 = require_spancontext_utils();
|
|
18527
|
-
var context_utils_1 = require_context_utils();
|
|
18528
|
-
var diag_1 = require_diag();
|
|
18529
|
-
var API_NAME = "trace";
|
|
18530
|
-
|
|
18531
|
-
class TraceAPI {
|
|
18532
|
-
constructor() {
|
|
18533
|
-
this._proxyTracerProvider = new ProxyTracerProvider_1.ProxyTracerProvider;
|
|
18534
|
-
this.wrapSpanContext = spancontext_utils_1.wrapSpanContext;
|
|
18535
|
-
this.isSpanContextValid = spancontext_utils_1.isSpanContextValid;
|
|
18536
|
-
this.deleteSpan = context_utils_1.deleteSpan;
|
|
18537
|
-
this.getSpan = context_utils_1.getSpan;
|
|
18538
|
-
this.getActiveSpan = context_utils_1.getActiveSpan;
|
|
18539
|
-
this.getSpanContext = context_utils_1.getSpanContext;
|
|
18540
|
-
this.setSpan = context_utils_1.setSpan;
|
|
18541
|
-
this.setSpanContext = context_utils_1.setSpanContext;
|
|
18542
|
-
}
|
|
18543
|
-
static getInstance() {
|
|
18544
|
-
if (!this._instance) {
|
|
18545
|
-
this._instance = new TraceAPI;
|
|
18546
|
-
}
|
|
18547
|
-
return this._instance;
|
|
18548
|
-
}
|
|
18549
|
-
setGlobalTracerProvider(provider) {
|
|
18550
|
-
const success3 = (0, global_utils_1.registerGlobal)(API_NAME, this._proxyTracerProvider, diag_1.DiagAPI.instance());
|
|
18551
|
-
if (success3) {
|
|
18552
|
-
this._proxyTracerProvider.setDelegate(provider);
|
|
18553
|
-
}
|
|
18554
|
-
return success3;
|
|
18555
|
-
}
|
|
18556
|
-
getTracerProvider() {
|
|
18557
|
-
return (0, global_utils_1.getGlobal)(API_NAME) || this._proxyTracerProvider;
|
|
18558
|
-
}
|
|
18559
|
-
getTracer(name, version2) {
|
|
18560
|
-
return this.getTracerProvider().getTracer(name, version2);
|
|
18561
|
-
}
|
|
18562
|
-
disable() {
|
|
18563
|
-
(0, global_utils_1.unregisterGlobal)(API_NAME, diag_1.DiagAPI.instance());
|
|
18564
|
-
this._proxyTracerProvider = new ProxyTracerProvider_1.ProxyTracerProvider;
|
|
18565
|
-
}
|
|
18566
|
-
}
|
|
18567
|
-
exports.TraceAPI = TraceAPI;
|
|
18568
|
-
});
|
|
18569
|
-
|
|
18570
|
-
// ../../node_modules/@opentelemetry/api/build/src/trace-api.js
|
|
18571
|
-
var require_trace_api = __commonJS((exports) => {
|
|
18572
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18573
|
-
exports.trace = undefined;
|
|
18574
|
-
var trace_1 = require_trace();
|
|
18575
|
-
exports.trace = trace_1.TraceAPI.getInstance();
|
|
18576
|
-
});
|
|
18577
|
-
|
|
18578
|
-
// ../../node_modules/@opentelemetry/api/build/src/index.js
|
|
18579
|
-
var require_src = __commonJS((exports) => {
|
|
18580
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18581
|
-
exports.trace = exports.propagation = exports.metrics = exports.diag = exports.context = exports.INVALID_SPAN_CONTEXT = exports.INVALID_TRACEID = exports.INVALID_SPANID = exports.isValidSpanId = exports.isValidTraceId = exports.isSpanContextValid = exports.createTraceState = exports.TraceFlags = exports.SpanStatusCode = exports.SpanKind = exports.SamplingDecision = exports.ProxyTracerProvider = exports.ProxyTracer = exports.defaultTextMapSetter = exports.defaultTextMapGetter = exports.ValueType = exports.createNoopMeter = exports.DiagLogLevel = exports.DiagConsoleLogger = exports.ROOT_CONTEXT = exports.createContextKey = exports.baggageEntryMetadataFromString = undefined;
|
|
18582
|
-
var utils_1 = require_utils();
|
|
18583
|
-
Object.defineProperty(exports, "baggageEntryMetadataFromString", { enumerable: true, get: function() {
|
|
18584
|
-
return utils_1.baggageEntryMetadataFromString;
|
|
18585
|
-
} });
|
|
18586
|
-
var context_1 = require_context();
|
|
18587
|
-
Object.defineProperty(exports, "createContextKey", { enumerable: true, get: function() {
|
|
18588
|
-
return context_1.createContextKey;
|
|
18589
|
-
} });
|
|
18590
|
-
Object.defineProperty(exports, "ROOT_CONTEXT", { enumerable: true, get: function() {
|
|
18591
|
-
return context_1.ROOT_CONTEXT;
|
|
18592
|
-
} });
|
|
18593
|
-
var consoleLogger_1 = require_consoleLogger();
|
|
18594
|
-
Object.defineProperty(exports, "DiagConsoleLogger", { enumerable: true, get: function() {
|
|
18595
|
-
return consoleLogger_1.DiagConsoleLogger;
|
|
18596
|
-
} });
|
|
18597
|
-
var types_1 = require_types();
|
|
18598
|
-
Object.defineProperty(exports, "DiagLogLevel", { enumerable: true, get: function() {
|
|
18599
|
-
return types_1.DiagLogLevel;
|
|
18600
|
-
} });
|
|
18601
|
-
var NoopMeter_1 = require_NoopMeter();
|
|
18602
|
-
Object.defineProperty(exports, "createNoopMeter", { enumerable: true, get: function() {
|
|
18603
|
-
return NoopMeter_1.createNoopMeter;
|
|
18604
|
-
} });
|
|
18605
|
-
var Metric_1 = require_Metric();
|
|
18606
|
-
Object.defineProperty(exports, "ValueType", { enumerable: true, get: function() {
|
|
18607
|
-
return Metric_1.ValueType;
|
|
18608
|
-
} });
|
|
18609
|
-
var TextMapPropagator_1 = require_TextMapPropagator();
|
|
18610
|
-
Object.defineProperty(exports, "defaultTextMapGetter", { enumerable: true, get: function() {
|
|
18611
|
-
return TextMapPropagator_1.defaultTextMapGetter;
|
|
18612
|
-
} });
|
|
18613
|
-
Object.defineProperty(exports, "defaultTextMapSetter", { enumerable: true, get: function() {
|
|
18614
|
-
return TextMapPropagator_1.defaultTextMapSetter;
|
|
18615
|
-
} });
|
|
18616
|
-
var ProxyTracer_1 = require_ProxyTracer();
|
|
18617
|
-
Object.defineProperty(exports, "ProxyTracer", { enumerable: true, get: function() {
|
|
18618
|
-
return ProxyTracer_1.ProxyTracer;
|
|
18619
|
-
} });
|
|
18620
|
-
var ProxyTracerProvider_1 = require_ProxyTracerProvider();
|
|
18621
|
-
Object.defineProperty(exports, "ProxyTracerProvider", { enumerable: true, get: function() {
|
|
18622
|
-
return ProxyTracerProvider_1.ProxyTracerProvider;
|
|
18623
|
-
} });
|
|
18624
|
-
var SamplingResult_1 = require_SamplingResult();
|
|
18625
|
-
Object.defineProperty(exports, "SamplingDecision", { enumerable: true, get: function() {
|
|
18626
|
-
return SamplingResult_1.SamplingDecision;
|
|
18627
|
-
} });
|
|
18628
|
-
var span_kind_1 = require_span_kind();
|
|
18629
|
-
Object.defineProperty(exports, "SpanKind", { enumerable: true, get: function() {
|
|
18630
|
-
return span_kind_1.SpanKind;
|
|
18631
|
-
} });
|
|
18632
|
-
var status_1 = require_status();
|
|
18633
|
-
Object.defineProperty(exports, "SpanStatusCode", { enumerable: true, get: function() {
|
|
18634
|
-
return status_1.SpanStatusCode;
|
|
18635
|
-
} });
|
|
18636
|
-
var trace_flags_1 = require_trace_flags();
|
|
18637
|
-
Object.defineProperty(exports, "TraceFlags", { enumerable: true, get: function() {
|
|
18638
|
-
return trace_flags_1.TraceFlags;
|
|
18639
|
-
} });
|
|
18640
|
-
var utils_2 = require_utils2();
|
|
18641
|
-
Object.defineProperty(exports, "createTraceState", { enumerable: true, get: function() {
|
|
18642
|
-
return utils_2.createTraceState;
|
|
18643
|
-
} });
|
|
18644
|
-
var spancontext_utils_1 = require_spancontext_utils();
|
|
18645
|
-
Object.defineProperty(exports, "isSpanContextValid", { enumerable: true, get: function() {
|
|
18646
|
-
return spancontext_utils_1.isSpanContextValid;
|
|
18647
|
-
} });
|
|
18648
|
-
Object.defineProperty(exports, "isValidTraceId", { enumerable: true, get: function() {
|
|
18649
|
-
return spancontext_utils_1.isValidTraceId;
|
|
18650
|
-
} });
|
|
18651
|
-
Object.defineProperty(exports, "isValidSpanId", { enumerable: true, get: function() {
|
|
18652
|
-
return spancontext_utils_1.isValidSpanId;
|
|
18653
|
-
} });
|
|
18654
|
-
var invalid_span_constants_1 = require_invalid_span_constants();
|
|
18655
|
-
Object.defineProperty(exports, "INVALID_SPANID", { enumerable: true, get: function() {
|
|
18656
|
-
return invalid_span_constants_1.INVALID_SPANID;
|
|
18657
|
-
} });
|
|
18658
|
-
Object.defineProperty(exports, "INVALID_TRACEID", { enumerable: true, get: function() {
|
|
18659
|
-
return invalid_span_constants_1.INVALID_TRACEID;
|
|
18660
|
-
} });
|
|
18661
|
-
Object.defineProperty(exports, "INVALID_SPAN_CONTEXT", { enumerable: true, get: function() {
|
|
18662
|
-
return invalid_span_constants_1.INVALID_SPAN_CONTEXT;
|
|
18663
|
-
} });
|
|
18664
|
-
var context_api_1 = require_context_api();
|
|
18665
|
-
Object.defineProperty(exports, "context", { enumerable: true, get: function() {
|
|
18666
|
-
return context_api_1.context;
|
|
18667
|
-
} });
|
|
18668
|
-
var diag_api_1 = require_diag_api();
|
|
18669
|
-
Object.defineProperty(exports, "diag", { enumerable: true, get: function() {
|
|
18670
|
-
return diag_api_1.diag;
|
|
18671
|
-
} });
|
|
18672
|
-
var metrics_api_1 = require_metrics_api();
|
|
18673
|
-
Object.defineProperty(exports, "metrics", { enumerable: true, get: function() {
|
|
18674
|
-
return metrics_api_1.metrics;
|
|
18675
|
-
} });
|
|
18676
|
-
var propagation_api_1 = require_propagation_api();
|
|
18677
|
-
Object.defineProperty(exports, "propagation", { enumerable: true, get: function() {
|
|
18678
|
-
return propagation_api_1.propagation;
|
|
18679
|
-
} });
|
|
18680
|
-
var trace_api_1 = require_trace_api();
|
|
18681
|
-
Object.defineProperty(exports, "trace", { enumerable: true, get: function() {
|
|
18682
|
-
return trace_api_1.trace;
|
|
18683
|
-
} });
|
|
18684
|
-
exports.default = {
|
|
18685
|
-
context: context_api_1.context,
|
|
18686
|
-
diag: diag_api_1.diag,
|
|
18687
|
-
metrics: metrics_api_1.metrics,
|
|
18688
|
-
propagation: propagation_api_1.propagation,
|
|
18689
|
-
trace: trace_api_1.trace
|
|
18690
|
-
};
|
|
18691
|
-
});
|
|
18692
|
-
|
|
18693
|
-
// ../types/src/processor/processor.ts
|
|
18694
|
-
var import_api, noopTracingContext, ProcessorPortSchema, ProcessorDefinitionSchema, ProcessorExecutionContextSchema, TraceStatus;
|
|
18695
|
-
var init_processor = __esm(() => {
|
|
18696
|
-
init_zod();
|
|
18697
|
-
init_common();
|
|
18698
|
-
import_api = __toESM(require_src(), 1);
|
|
18699
|
-
noopTracingContext = {
|
|
18700
|
-
traceId: "",
|
|
18701
|
-
getActiveSpan() {
|
|
18702
|
-
return;
|
|
18703
|
-
},
|
|
18704
|
-
async withSpan(_name, _options, fn) {
|
|
18705
|
-
const noopSpan = {
|
|
18706
|
-
spanContext: () => ({
|
|
18707
|
-
traceId: "",
|
|
18708
|
-
spanId: "",
|
|
18709
|
-
traceFlags: 0
|
|
18710
|
-
}),
|
|
18711
|
-
setAttribute: () => noopSpan,
|
|
18712
|
-
setAttributes: () => noopSpan,
|
|
18713
|
-
addEvent: () => noopSpan,
|
|
18714
|
-
addLink: () => noopSpan,
|
|
18715
|
-
addLinks: () => noopSpan,
|
|
18716
|
-
setStatus: () => noopSpan,
|
|
18717
|
-
updateName: () => noopSpan,
|
|
18718
|
-
end: () => {},
|
|
18719
|
-
isRecording: () => false,
|
|
18720
|
-
recordException: () => {}
|
|
18721
|
-
};
|
|
18722
|
-
return fn(noopSpan);
|
|
18723
|
-
}
|
|
18724
|
-
};
|
|
18725
|
-
ProcessorPortSchema = exports_external.object({
|
|
18726
|
-
name: exports_external.string(),
|
|
18727
|
-
schema: JsonSchemaSchema,
|
|
18728
|
-
required: exports_external.boolean().default(true)
|
|
18729
|
-
});
|
|
18730
|
-
ProcessorDefinitionSchema = exports_external.object({
|
|
18731
|
-
id: exports_external.string(),
|
|
18732
|
-
name: exports_external.string(),
|
|
18733
|
-
description: exports_external.string().optional(),
|
|
18734
|
-
inputSchema: JsonSchemaSchema,
|
|
18735
|
-
outputSchema: JsonSchemaSchema,
|
|
18736
|
-
configSchema: JsonSchemaSchema.optional(),
|
|
18737
|
-
inputPorts: exports_external.array(ProcessorPortSchema).optional(),
|
|
18738
|
-
outputPorts: exports_external.array(ProcessorPortSchema).optional(),
|
|
18739
|
-
isBuiltin: exports_external.boolean().default(true),
|
|
18740
|
-
pluginName: exports_external.string().optional()
|
|
18741
|
-
});
|
|
18742
|
-
ProcessorExecutionContextSchema = exports_external.object({
|
|
18743
|
-
jobId: exports_external.string(),
|
|
18744
|
-
stepId: exports_external.string(),
|
|
18745
|
-
tenantId: exports_external.string(),
|
|
18746
|
-
workflowId: exports_external.string(),
|
|
18747
|
-
workerId: exports_external.string().optional()
|
|
18748
|
-
});
|
|
18749
|
-
((TraceStatus2) => {
|
|
18750
|
-
TraceStatus2["PENDING"] = "pending";
|
|
18751
|
-
TraceStatus2["RUNNING"] = "running";
|
|
18752
|
-
TraceStatus2["COMPLETED"] = "completed";
|
|
18753
|
-
TraceStatus2["FAILED"] = "failed";
|
|
18754
|
-
})(TraceStatus ||= {});
|
|
18755
|
-
});
|
|
18756
|
-
|
|
18757
|
-
// ../types/src/processor/execution.ts
|
|
18758
|
-
function asTuple(values) {
|
|
18759
|
-
return values;
|
|
18760
|
-
}
|
|
18761
|
-
var WorkflowExecutionStatusValue, WorkflowExecutionStatusSchema, StepExecutionStatusValue, StepExecutionStatusSchema, TriggerTypeValue, TriggerTypeSchema, ExecutionTypeValue, ExecutionTypeSchema, WORKFLOW_EXECUTION_STATUSES, STEP_EXECUTION_STATUSES, TRIGGER_TYPES, EXECUTION_TYPES;
|
|
18762
|
-
var init_execution = __esm(() => {
|
|
18763
|
-
init_zod();
|
|
18764
|
-
WorkflowExecutionStatusValue = {
|
|
18765
|
-
CREATED: "created",
|
|
18766
|
-
PENDING: "pending",
|
|
18767
|
-
RUNNING: "running",
|
|
18768
|
-
WAITING: "waiting",
|
|
18769
|
-
COMPLETED: "completed",
|
|
18770
|
-
FAILED: "failed",
|
|
18771
|
-
CANCELLED: "cancelled"
|
|
18772
|
-
};
|
|
18773
|
-
WorkflowExecutionStatusSchema = exports_external.enum([
|
|
18774
|
-
WorkflowExecutionStatusValue.CREATED,
|
|
18775
|
-
WorkflowExecutionStatusValue.PENDING,
|
|
18776
|
-
WorkflowExecutionStatusValue.RUNNING,
|
|
18777
|
-
WorkflowExecutionStatusValue.WAITING,
|
|
18778
|
-
WorkflowExecutionStatusValue.COMPLETED,
|
|
18779
|
-
WorkflowExecutionStatusValue.FAILED,
|
|
18780
|
-
WorkflowExecutionStatusValue.CANCELLED
|
|
18781
|
-
]);
|
|
18782
|
-
StepExecutionStatusValue = {
|
|
18783
|
-
PENDING: "pending",
|
|
18784
|
-
RUNNING: "running",
|
|
18785
|
-
SUCCESS: "success",
|
|
18786
|
-
FAILURE: "failure",
|
|
18787
|
-
WAITING: "waiting",
|
|
18788
|
-
SKIPPED: "skipped"
|
|
18789
|
-
};
|
|
18790
|
-
StepExecutionStatusSchema = exports_external.enum([
|
|
18791
|
-
StepExecutionStatusValue.PENDING,
|
|
18792
|
-
StepExecutionStatusValue.RUNNING,
|
|
18793
|
-
StepExecutionStatusValue.SUCCESS,
|
|
18794
|
-
StepExecutionStatusValue.FAILURE,
|
|
18795
|
-
StepExecutionStatusValue.WAITING,
|
|
18796
|
-
StepExecutionStatusValue.SKIPPED
|
|
18797
|
-
]);
|
|
18798
|
-
TriggerTypeValue = {
|
|
18799
|
-
MANUAL: "manual",
|
|
18800
|
-
API: "api",
|
|
18801
|
-
WEBHOOK: "webhook",
|
|
18802
|
-
SCHEDULE: "schedule",
|
|
18803
|
-
EMAIL: "email",
|
|
18804
|
-
EVAL: "eval",
|
|
18805
|
-
CLI: "cli"
|
|
18806
|
-
};
|
|
18807
|
-
TriggerTypeSchema = exports_external.enum([
|
|
18808
|
-
TriggerTypeValue.MANUAL,
|
|
18809
|
-
TriggerTypeValue.API,
|
|
18810
|
-
TriggerTypeValue.WEBHOOK,
|
|
18811
|
-
TriggerTypeValue.SCHEDULE,
|
|
18812
|
-
TriggerTypeValue.EMAIL,
|
|
18813
|
-
TriggerTypeValue.EVAL,
|
|
18814
|
-
TriggerTypeValue.CLI
|
|
18815
|
-
]);
|
|
18816
|
-
ExecutionTypeValue = {
|
|
18817
|
-
PROD: "prod",
|
|
18818
|
-
EVAL: "eval",
|
|
18819
|
-
PLAYGROUND: "playground"
|
|
18820
|
-
};
|
|
18821
|
-
ExecutionTypeSchema = exports_external.enum([
|
|
18822
|
-
ExecutionTypeValue.PROD,
|
|
18823
|
-
ExecutionTypeValue.EVAL,
|
|
18824
|
-
ExecutionTypeValue.PLAYGROUND
|
|
18825
|
-
]);
|
|
18826
|
-
WORKFLOW_EXECUTION_STATUSES = asTuple(WorkflowExecutionStatusSchema.options);
|
|
18827
|
-
STEP_EXECUTION_STATUSES = asTuple(StepExecutionStatusSchema.options);
|
|
18828
|
-
TRIGGER_TYPES = TriggerTypeSchema.options;
|
|
18829
|
-
EXECUTION_TYPES = ExecutionTypeSchema.options;
|
|
18830
|
-
});
|
|
18831
|
-
|
|
18832
|
-
// ../types/src/processor/configs/classify.ts
|
|
18833
|
-
var ClassifyInputSchema, ClassifyLabelSchema, ClassifyConfigSchema, ClassifyOutputSchema;
|
|
18834
|
-
var init_classify = __esm(() => {
|
|
18835
|
-
init_zod();
|
|
18836
|
-
ClassifyInputSchema = exports_external.object({
|
|
18837
|
-
content: exports_external.string().optional().describe("Text content to classify"),
|
|
18838
|
-
text: exports_external.string().optional().describe("Text content (alternative to content)")
|
|
18839
|
-
}).refine((data) => !!(data.content || data.text), {
|
|
18840
|
-
message: "Either content or text must be provided"
|
|
18841
|
-
});
|
|
18842
|
-
ClassifyLabelSchema = exports_external.object({
|
|
18843
|
-
name: exports_external.string().min(1).describe("Label value returned in output.label"),
|
|
18844
|
-
description: exports_external.string().optional().describe("What documents fall into this label. Fed to the LLM as guidance.")
|
|
18845
|
-
});
|
|
18846
|
-
ClassifyConfigSchema = exports_external.object({
|
|
18847
|
-
labels: exports_external.array(ClassifyLabelSchema).min(2).describe("Allowed labels. The LLM is constrained to pick exactly one of these names."),
|
|
18848
|
-
prompt: exports_external.string().optional().describe("Optional classification instructions appended to the system prompt. Use to clarify edge cases or emphasize evidence the model should weigh."),
|
|
18849
|
-
provider: exports_external.string().optional().describe('Provider ID (e.g., "openai-gpt4o-mini")'),
|
|
18850
|
-
model: exports_external.string().optional().describe("Model override"),
|
|
18851
|
-
maxInputTokens: exports_external.number().int().optional().describe("Max input tokens. Truncates input text when exceeded. Omit for no limit.")
|
|
18852
|
-
});
|
|
18853
|
-
ClassifyOutputSchema = exports_external.object({
|
|
18854
|
-
label: exports_external.string().describe("The selected label name"),
|
|
18855
|
-
confidence: exports_external.enum(["low", "medium", "high"]).describe("Coarse confidence in the classification"),
|
|
18856
|
-
reason: exports_external.string().describe("Short justification for the chosen label")
|
|
18857
|
-
});
|
|
18858
|
-
});
|
|
18859
|
-
|
|
18860
|
-
// ../types/src/parser/parser.ts
|
|
18861
|
-
function resolveEffectiveMimeType(filename, declaredMimeType) {
|
|
18862
|
-
const ext = filename.split(".").pop()?.toLowerCase();
|
|
18863
|
-
if (!ext)
|
|
18864
|
-
return declaredMimeType;
|
|
18865
|
-
const extensionMime = EXTENSION_TO_MIME[ext];
|
|
18866
|
-
return extensionMime ?? declaredMimeType;
|
|
18867
|
-
}
|
|
18868
|
-
function getParserCategory(mimeType) {
|
|
18869
|
-
const normalized = mimeType.toLowerCase().trim();
|
|
18870
|
-
if (ParserCategory.PLAINTEXT.includes(normalized)) {
|
|
18871
|
-
return "plaintext";
|
|
18872
|
-
}
|
|
18873
|
-
if (ParserCategory.OFFICE.includes(normalized)) {
|
|
18874
|
-
return "office";
|
|
18875
|
-
}
|
|
18876
|
-
if (ParserCategory.DOCUMENT.includes(normalized)) {
|
|
18877
|
-
return "document";
|
|
18878
|
-
}
|
|
18879
|
-
return null;
|
|
18880
|
-
}
|
|
18881
|
-
function requiresSpecializedParser(mimeType) {
|
|
18882
|
-
return getParserCategory(mimeType) === "document";
|
|
18883
|
-
}
|
|
18884
|
-
function getAllSupportedMimeTypes() {
|
|
18885
|
-
return [...ParserCategory.PLAINTEXT, ...ParserCategory.OFFICE, ...ParserCategory.DOCUMENT];
|
|
18886
|
-
}
|
|
18887
|
-
function getSupportedFormatsLabel() {
|
|
18888
|
-
const allMimes = getAllSupportedMimeTypes();
|
|
18889
|
-
const labels = [...new Set(allMimes.map((m) => MIME_TO_LABEL[m] ?? m))];
|
|
18890
|
-
return labels.join(", ");
|
|
18891
|
-
}
|
|
18892
|
-
var OFFICE_MIME_TYPES, ParserCategory, ParserTypeSchema, DocumentMetadataSchema, ParseUsageSchema, CoordinateUnitSchema, PointSchema, BoundingRegionSchema, PositionedTextSchema, TableCellSchema, ExtractedTableSchema, LayoutElementTypeSchema, LayoutElementSchema, PageResultSchema, ParseResultSchema, ParseOptionsSchema, ParserInputSchema, EXTENSION_TO_MIME, MIME_TO_LABEL;
|
|
18893
|
-
var init_parser = __esm(() => {
|
|
18894
|
-
init_zod();
|
|
18895
|
-
OFFICE_MIME_TYPES = [
|
|
18896
|
-
"application/vnd.openxmlformats-officedocument.wordprocessingml.document",
|
|
18897
|
-
"application/msword",
|
|
18898
|
-
"application/vnd.oasis.opendocument.text",
|
|
18899
|
-
"application/rtf",
|
|
18900
|
-
"text/rtf",
|
|
18901
|
-
"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
|
|
18902
|
-
"application/vnd.ms-excel",
|
|
18903
|
-
"application/vnd.ms-excel.sheet.macroenabled.12",
|
|
18904
|
-
"application/vnd.ms-excel.sheet.binary.macroenabled.12",
|
|
18905
|
-
"application/vnd.oasis.opendocument.spreadsheet",
|
|
18906
|
-
"application/vnd.openxmlformats-officedocument.presentationml.presentation",
|
|
18907
|
-
"application/vnd.openxmlformats-officedocument.presentationml.slideshow",
|
|
18908
|
-
"application/vnd.ms-powerpoint.presentation.macroenabled.12",
|
|
18909
|
-
"application/vnd.ms-powerpoint",
|
|
18910
|
-
"application/vnd.oasis.opendocument.presentation",
|
|
18911
|
-
"message/rfc822",
|
|
18912
|
-
"application/vnd.ms-outlook",
|
|
18913
|
-
"application/epub+zip"
|
|
18914
|
-
];
|
|
18915
|
-
ParserCategory = {
|
|
18916
|
-
PLAINTEXT: [
|
|
18917
|
-
"text/plain",
|
|
18918
|
-
"text/markdown",
|
|
18919
|
-
"text/csv",
|
|
18920
|
-
"text/tab-separated-values",
|
|
18921
|
-
"text/html",
|
|
18922
|
-
"text/xml",
|
|
18923
|
-
"application/json",
|
|
18924
|
-
"application/x-yaml",
|
|
18925
|
-
"application/toml",
|
|
18926
|
-
"image/svg+xml",
|
|
18927
|
-
"text/x-rst",
|
|
18928
|
-
"text/x-org",
|
|
18929
|
-
"application/x-latex",
|
|
18930
|
-
"application/x-ipynb+json",
|
|
18931
|
-
"application/x-bibtex",
|
|
18932
|
-
"application/docbook+xml",
|
|
18933
|
-
"application/x-fictionbook+xml"
|
|
18934
|
-
],
|
|
18935
|
-
OFFICE: [...OFFICE_MIME_TYPES],
|
|
18936
|
-
DOCUMENT: [
|
|
18937
|
-
"application/pdf",
|
|
18938
|
-
"image/png",
|
|
18939
|
-
"image/jpeg",
|
|
18940
|
-
"image/webp",
|
|
18941
|
-
"image/tiff",
|
|
18942
|
-
"image/gif",
|
|
18943
|
-
"image/bmp"
|
|
18944
|
-
]
|
|
18945
|
-
};
|
|
18946
|
-
ParserTypeSchema = exports_external.enum([
|
|
18947
|
-
"plaintext",
|
|
18948
|
-
"office",
|
|
18949
|
-
"llm-vision",
|
|
18950
|
-
"ocr"
|
|
18951
|
-
]);
|
|
18952
|
-
DocumentMetadataSchema = exports_external.object({
|
|
18953
|
-
filename: exports_external.string(),
|
|
18954
|
-
mimeType: exports_external.string(),
|
|
18955
|
-
size: exports_external.number().describe("File size in bytes"),
|
|
18956
|
-
storageRef: exports_external.string().optional().describe("Storage reference for the original file")
|
|
18957
|
-
});
|
|
18958
|
-
ParseUsageSchema = exports_external.object({
|
|
18959
|
-
pageCount: exports_external.number(),
|
|
18960
|
-
processingTimeMs: exports_external.number().optional()
|
|
18961
|
-
});
|
|
18962
|
-
CoordinateUnitSchema = exports_external.enum(["pixel", "inch", "point", "normalized"]);
|
|
18963
|
-
PointSchema = exports_external.object({
|
|
18964
|
-
x: exports_external.number(),
|
|
18965
|
-
y: exports_external.number()
|
|
18966
|
-
});
|
|
18967
|
-
BoundingRegionSchema = exports_external.object({
|
|
18968
|
-
polygon: exports_external.array(PointSchema).min(3),
|
|
18969
|
-
unit: CoordinateUnitSchema,
|
|
18970
|
-
pageIndex: exports_external.number()
|
|
18971
|
-
});
|
|
18972
|
-
PositionedTextSchema = exports_external.object({
|
|
18973
|
-
text: exports_external.string(),
|
|
18974
|
-
confidence: exports_external.number().min(0).max(1).optional(),
|
|
18975
|
-
boundingRegion: BoundingRegionSchema.optional()
|
|
18976
|
-
});
|
|
18977
|
-
TableCellSchema = exports_external.object({
|
|
18978
|
-
content: exports_external.string(),
|
|
18979
|
-
rowIndex: exports_external.number(),
|
|
18980
|
-
columnIndex: exports_external.number(),
|
|
18981
|
-
rowSpan: exports_external.number().default(1),
|
|
18982
|
-
columnSpan: exports_external.number().default(1),
|
|
18983
|
-
boundingRegion: BoundingRegionSchema.optional()
|
|
18984
|
-
});
|
|
18985
|
-
ExtractedTableSchema = exports_external.object({
|
|
18986
|
-
cells: exports_external.array(TableCellSchema),
|
|
18987
|
-
rowCount: exports_external.number(),
|
|
18988
|
-
columnCount: exports_external.number(),
|
|
18989
|
-
boundingRegion: BoundingRegionSchema.optional()
|
|
18990
|
-
});
|
|
18991
|
-
LayoutElementTypeSchema = exports_external.enum([
|
|
18992
|
-
"paragraph",
|
|
18993
|
-
"title",
|
|
18994
|
-
"sectionHeading",
|
|
18995
|
-
"pageHeader",
|
|
18996
|
-
"pageFooter",
|
|
18997
|
-
"pageNumber",
|
|
18998
|
-
"footnote",
|
|
18999
|
-
"table",
|
|
19000
|
-
"figure",
|
|
19001
|
-
"formulaBlock"
|
|
19002
|
-
]);
|
|
19003
|
-
LayoutElementSchema = exports_external.object({
|
|
19004
|
-
type: LayoutElementTypeSchema,
|
|
19005
|
-
content: exports_external.string(),
|
|
19006
|
-
table: ExtractedTableSchema.optional(),
|
|
19007
|
-
caption: exports_external.string().optional(),
|
|
19008
|
-
figureId: exports_external.string().optional(),
|
|
19009
|
-
boundingRegion: BoundingRegionSchema.optional()
|
|
19010
|
-
});
|
|
19011
|
-
PageResultSchema = exports_external.object({
|
|
19012
|
-
pageIndex: exports_external.number().describe("0-based page index"),
|
|
19013
|
-
text: exports_external.string().describe("Extracted text content (markdown/HTML)"),
|
|
19014
|
-
pageName: exports_external.string().optional().describe("Page/sheet name (e.g., Excel sheet name)"),
|
|
19015
|
-
layoutElements: exports_external.array(LayoutElementSchema).optional().describe("Semantic layout elements in reading order"),
|
|
19016
|
-
words: exports_external.array(PositionedTextSchema).optional().describe("Word-level positions"),
|
|
19017
|
-
lines: exports_external.array(PositionedTextSchema).optional().describe("Line-level positions"),
|
|
19018
|
-
tables: exports_external.array(ExtractedTableSchema).optional().describe("Extracted tables"),
|
|
19019
|
-
width: exports_external.number().optional().describe("Page width"),
|
|
19020
|
-
height: exports_external.number().optional().describe("Page height"),
|
|
19021
|
-
unit: CoordinateUnitSchema.optional().describe("Unit for width/height and bounding regions"),
|
|
19022
|
-
confidence: exports_external.number().min(0).max(1).optional().describe("Overall page confidence")
|
|
19023
|
-
});
|
|
19024
|
-
ParseResultSchema = exports_external.object({
|
|
19025
|
-
document: DocumentMetadataSchema,
|
|
19026
|
-
usage: ParseUsageSchema,
|
|
19027
|
-
pages: exports_external.array(PageResultSchema),
|
|
19028
|
-
text: exports_external.string().describe("Combined text from all pages"),
|
|
19029
|
-
parserType: ParserTypeSchema,
|
|
19030
|
-
parserVersion: exports_external.string().optional(),
|
|
19031
|
-
model: exports_external.string().optional().describe("Model used (for LLM/OCR parsers)"),
|
|
19032
|
-
rawResponse: exports_external.unknown().optional()
|
|
19033
|
-
});
|
|
19034
|
-
ParseOptionsSchema = exports_external.object({
|
|
19035
|
-
outputFormat: exports_external.enum(["plain", "markdown", "djot", "html"]).default("markdown"),
|
|
19036
|
-
ocrProvider: exports_external.string().optional().describe("OCR provider ID to use"),
|
|
19037
|
-
includeWordPositions: exports_external.boolean().default(false),
|
|
19038
|
-
includeLinePositions: exports_external.boolean().default(false),
|
|
19039
|
-
extractTables: exports_external.boolean().default(true),
|
|
19040
|
-
provider: exports_external.string().optional().describe("LLM provider ID to use"),
|
|
19041
|
-
model: exports_external.string().optional(),
|
|
19042
|
-
maxConcurrency: exports_external.number().min(1).max(30).default(3),
|
|
19043
|
-
pagesPerBatch: exports_external.number().min(1).max(20).default(5),
|
|
19044
|
-
prompt: exports_external.string().optional().describe("Custom prompt for LLM-based parsing"),
|
|
19045
|
-
languages: exports_external.array(exports_external.string()).optional().describe("OCR language hints"),
|
|
19046
|
-
tenantId: exports_external.string().optional()
|
|
19047
|
-
});
|
|
19048
|
-
ParserInputSchema = exports_external.object({
|
|
19049
|
-
data: exports_external.instanceof(Buffer).or(exports_external.instanceof(Uint8Array)),
|
|
19050
|
-
filename: exports_external.string(),
|
|
19051
|
-
mimeType: exports_external.string(),
|
|
19052
|
-
options: ParseOptionsSchema.optional()
|
|
19053
|
-
});
|
|
19054
|
-
EXTENSION_TO_MIME = {
|
|
19055
|
-
docx: "application/vnd.openxmlformats-officedocument.wordprocessingml.document",
|
|
19056
|
-
doc: "application/msword",
|
|
19057
|
-
odt: "application/vnd.oasis.opendocument.text",
|
|
19058
|
-
rtf: "application/rtf",
|
|
19059
|
-
xlsx: "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
|
|
19060
|
-
xls: "application/vnd.ms-excel",
|
|
19061
|
-
xlsm: "application/vnd.ms-excel.sheet.macroenabled.12",
|
|
19062
|
-
xlsb: "application/vnd.ms-excel.sheet.binary.macroenabled.12",
|
|
19063
|
-
ods: "application/vnd.oasis.opendocument.spreadsheet",
|
|
19064
|
-
pptx: "application/vnd.openxmlformats-officedocument.presentationml.presentation",
|
|
19065
|
-
ppsx: "application/vnd.openxmlformats-officedocument.presentationml.slideshow",
|
|
19066
|
-
pptm: "application/vnd.ms-powerpoint.presentation.macroenabled.12",
|
|
19067
|
-
ppt: "application/vnd.ms-powerpoint",
|
|
19068
|
-
odp: "application/vnd.oasis.opendocument.presentation",
|
|
19069
|
-
eml: "message/rfc822",
|
|
19070
|
-
msg: "application/vnd.ms-outlook",
|
|
19071
|
-
epub: "application/epub+zip",
|
|
19072
|
-
pdf: "application/pdf",
|
|
19073
|
-
png: "image/png",
|
|
19074
|
-
jpg: "image/jpeg",
|
|
19075
|
-
jpeg: "image/jpeg",
|
|
19076
|
-
webp: "image/webp",
|
|
19077
|
-
tiff: "image/tiff",
|
|
19078
|
-
tif: "image/tiff",
|
|
19079
|
-
gif: "image/gif",
|
|
19080
|
-
bmp: "image/bmp",
|
|
19081
|
-
svg: "image/svg+xml",
|
|
19082
|
-
txt: "text/plain",
|
|
19083
|
-
md: "text/markdown",
|
|
19084
|
-
markdown: "text/markdown",
|
|
19085
|
-
csv: "text/csv",
|
|
19086
|
-
tsv: "text/tab-separated-values",
|
|
19087
|
-
html: "text/html",
|
|
19088
|
-
htm: "text/html",
|
|
19089
|
-
xml: "text/xml",
|
|
19090
|
-
json: "application/json",
|
|
19091
|
-
yaml: "application/x-yaml",
|
|
19092
|
-
yml: "application/x-yaml",
|
|
19093
|
-
toml: "application/toml",
|
|
19094
|
-
rst: "text/x-rst",
|
|
19095
|
-
org: "text/x-org",
|
|
19096
|
-
tex: "application/x-latex",
|
|
19097
|
-
latex: "application/x-latex",
|
|
19098
|
-
ipynb: "application/x-ipynb+json",
|
|
19099
|
-
bib: "application/x-bibtex",
|
|
19100
|
-
dbk: "application/docbook+xml",
|
|
19101
|
-
docbook: "application/docbook+xml",
|
|
19102
|
-
fb2: "application/x-fictionbook+xml"
|
|
19103
|
-
};
|
|
19104
|
-
MIME_TO_LABEL = {
|
|
19105
|
-
"application/vnd.openxmlformats-officedocument.wordprocessingml.document": "DOCX",
|
|
19106
|
-
"application/msword": "DOC",
|
|
19107
|
-
"application/vnd.oasis.opendocument.text": "ODT",
|
|
19108
|
-
"application/rtf": "RTF",
|
|
19109
|
-
"text/rtf": "RTF",
|
|
19110
|
-
"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet": "XLSX",
|
|
19111
|
-
"application/vnd.ms-excel": "XLS",
|
|
19112
|
-
"application/vnd.ms-excel.sheet.macroenabled.12": "XLSM",
|
|
19113
|
-
"application/vnd.ms-excel.sheet.binary.macroenabled.12": "XLSB",
|
|
19114
|
-
"application/vnd.oasis.opendocument.spreadsheet": "ODS",
|
|
19115
|
-
"application/vnd.openxmlformats-officedocument.presentationml.presentation": "PPTX",
|
|
19116
|
-
"application/vnd.openxmlformats-officedocument.presentationml.slideshow": "PPSX",
|
|
19117
|
-
"application/vnd.ms-powerpoint.presentation.macroenabled.12": "PPTM",
|
|
19118
|
-
"application/vnd.ms-powerpoint": "PPT",
|
|
19119
|
-
"application/vnd.oasis.opendocument.presentation": "ODP",
|
|
19120
|
-
"message/rfc822": "EML",
|
|
19121
|
-
"application/vnd.ms-outlook": "MSG",
|
|
19122
|
-
"application/epub+zip": "EPUB",
|
|
19123
|
-
"application/pdf": "PDF",
|
|
19124
|
-
"image/png": "PNG",
|
|
19125
|
-
"image/jpeg": "JPEG",
|
|
19126
|
-
"image/webp": "WebP",
|
|
19127
|
-
"image/tiff": "TIFF",
|
|
19128
|
-
"image/gif": "GIF",
|
|
19129
|
-
"image/bmp": "BMP",
|
|
19130
|
-
"image/svg+xml": "SVG",
|
|
19131
|
-
"text/plain": "TXT",
|
|
19132
|
-
"text/markdown": "Markdown",
|
|
19133
|
-
"text/csv": "CSV",
|
|
19134
|
-
"text/tab-separated-values": "TSV",
|
|
19135
|
-
"text/html": "HTML",
|
|
19136
|
-
"text/xml": "XML",
|
|
19137
|
-
"application/json": "JSON",
|
|
19138
|
-
"application/x-yaml": "YAML",
|
|
19139
|
-
"application/toml": "TOML",
|
|
19140
|
-
"text/x-rst": "RST",
|
|
19141
|
-
"text/x-org": "Org",
|
|
19142
|
-
"application/x-latex": "LaTeX",
|
|
19143
|
-
"application/x-ipynb+json": "Jupyter",
|
|
19144
|
-
"application/x-bibtex": "BibTeX",
|
|
19145
|
-
"application/docbook+xml": "DocBook",
|
|
19146
|
-
"application/x-fictionbook+xml": "FB2"
|
|
19147
|
-
};
|
|
19148
|
-
});
|
|
19149
|
-
|
|
19150
|
-
// ../types/src/processor/configs/document-parser.ts
|
|
19151
|
-
function isFilePathDescriptor(input) {
|
|
19152
|
-
return FilePathDescriptorSchema.safeParse(input).success;
|
|
19153
|
-
}
|
|
19154
|
-
var FileIdInputSchema, LocalFileRefSchema, S3FileRefSchema, InlineFileRefSchema, FilePathDescriptorSchema, DocumentParserInputSchema, DocumentParserOutputSchema, DocumentParserConfigSchema;
|
|
19155
|
-
var init_document_parser = __esm(() => {
|
|
19156
|
-
init_zod();
|
|
19157
|
-
init_parser();
|
|
19158
|
-
FileIdInputSchema = exports_external.object({
|
|
19159
|
-
fileId: exports_external.string().describe("File ID from files table"),
|
|
19160
|
-
filename: exports_external.string().optional().describe("Original filename (for inline files)"),
|
|
19161
|
-
mimeType: exports_external.string().optional().describe("MIME type (for inline files)")
|
|
19162
|
-
});
|
|
19163
|
-
LocalFileRefSchema = exports_external.object({
|
|
19164
|
-
kind: exports_external.literal("local"),
|
|
19165
|
-
path: exports_external.string().describe("Absolute path to a file on disk"),
|
|
19166
|
-
filename: exports_external.string().describe("Original filename"),
|
|
19167
|
-
mimeType: exports_external.string().describe("MIME type of the file")
|
|
19168
|
-
});
|
|
19169
|
-
S3FileRefSchema = exports_external.object({
|
|
19170
|
-
kind: exports_external.literal("s3"),
|
|
19171
|
-
ref: exports_external.string().describe("Storage key (suffix-only, prefix added by adapter)"),
|
|
19172
|
-
filename: exports_external.string().describe("Original filename"),
|
|
19173
|
-
mimeType: exports_external.string().describe("MIME type of the file")
|
|
19174
|
-
});
|
|
19175
|
-
InlineFileRefSchema = exports_external.object({
|
|
19176
|
-
kind: exports_external.literal("inline"),
|
|
19177
|
-
base64: exports_external.string().describe("Base64-encoded file bytes"),
|
|
19178
|
-
filename: exports_external.string().describe("Original filename"),
|
|
19179
|
-
mimeType: exports_external.string().describe("MIME type of the file")
|
|
19180
|
-
});
|
|
19181
|
-
FilePathDescriptorSchema = exports_external.discriminatedUnion("kind", [
|
|
19182
|
-
LocalFileRefSchema,
|
|
19183
|
-
S3FileRefSchema,
|
|
19184
|
-
InlineFileRefSchema
|
|
19185
|
-
]);
|
|
19186
|
-
DocumentParserInputSchema = exports_external.union([FileIdInputSchema, FilePathDescriptorSchema]);
|
|
19187
|
-
DocumentParserOutputSchema = ParseResultSchema;
|
|
19188
|
-
DocumentParserConfigSchema = exports_external.object({
|
|
19189
|
-
ocrModel: exports_external.string().optional().describe("OCR provider ID for PDF/image parsing"),
|
|
19190
|
-
llmModel: exports_external.string().optional().describe("LLM provider ID for vision-based parsing"),
|
|
19191
|
-
maxConcurrency: exports_external.number().min(1).max(10).default(3).describe("Max concurrent VLM batch requests"),
|
|
19192
|
-
pagesPerBatch: exports_external.number().min(1).max(20).default(5).describe("Number of page images per VLM request"),
|
|
19193
|
-
prompt: exports_external.string().optional().describe("Custom extraction prompt"),
|
|
19194
|
-
nativeText: exports_external.boolean().default(false).optional().describe("Use native text extraction for PDFs with embedded text (no OCR/VLM)"),
|
|
19195
|
-
languages: exports_external.array(exports_external.string()).optional().describe('OCR language hints (e.g., ["en", "de"])'),
|
|
19196
|
-
outputFormat: exports_external.enum(["plain", "markdown", "djot", "html"]).default("markdown").optional().describe("Format for extracted text. Only the native (Kreuzberg) parser uses this — OCR/VLM always emit markdown.")
|
|
19197
|
-
}).prefault({});
|
|
19198
|
-
});
|
|
19199
|
-
|
|
19200
|
-
// ../types/src/processor/configs/extract.ts
|
|
19201
|
-
var ExtractInputSchema, ExtractOutputSchema, ExtractConfigSchema;
|
|
19202
|
-
var init_extract = __esm(() => {
|
|
19203
|
-
init_zod();
|
|
19204
|
-
ExtractInputSchema = exports_external.object({
|
|
19205
|
-
content: exports_external.string().optional().describe("Text content to extract from"),
|
|
19206
|
-
text: exports_external.string().optional().describe("Text content (alternative to content, e.g., from document parser)"),
|
|
19207
|
-
contentType: exports_external.enum(["text", "image"]).default("text"),
|
|
19208
|
-
imageData: exports_external.string().optional(),
|
|
19209
|
-
imageMimeType: exports_external.string().optional()
|
|
19210
|
-
}).refine((data) => data.content || data.text, {
|
|
19211
|
-
message: "Either content or text must be provided"
|
|
19212
|
-
});
|
|
19213
|
-
ExtractOutputSchema = exports_external.record(exports_external.string(), exports_external.unknown()).describe("Extracted structured data matching the provided schema");
|
|
19214
|
-
ExtractConfigSchema = exports_external.object({
|
|
19215
|
-
schema: exports_external.record(exports_external.string(), exports_external.unknown()).describe("JSON Schema defining the structure to extract"),
|
|
19216
|
-
prompt: exports_external.string().optional().describe("Custom prompt template for extraction"),
|
|
19217
|
-
provider: exports_external.string().optional().describe('Provider ID to use (e.g., "openai-gpt4o", "anthropic-claude")'),
|
|
19218
|
-
model: exports_external.string().optional().describe("Model to use (overrides provider default)"),
|
|
19219
|
-
maxInputTokens: exports_external.number().int().optional().describe("Max input tokens. Truncates input text and logs a warning when exceeded. Omit for no limit.")
|
|
19220
|
-
});
|
|
19221
|
-
});
|
|
19222
|
-
|
|
19223
|
-
// ../types/src/processor/configs/merge.ts
|
|
19224
|
-
var MergeConfigSchema, MergeInputSchema, MergeOutputSchema;
|
|
19225
|
-
var init_merge = __esm(() => {
|
|
19226
|
-
init_zod();
|
|
19227
|
-
MergeConfigSchema = exports_external.object({
|
|
19228
|
-
preservePortNames: exports_external.boolean().default(true),
|
|
19229
|
-
outputKey: exports_external.string().optional()
|
|
19230
|
-
});
|
|
19231
|
-
MergeInputSchema = exports_external.record(exports_external.string(), exports_external.unknown());
|
|
19232
|
-
MergeOutputSchema = exports_external.object({
|
|
19233
|
-
items: exports_external.array(exports_external.unknown()),
|
|
19234
|
-
count: exports_external.number(),
|
|
19235
|
-
merged: exports_external.record(exports_external.string(), exports_external.unknown()).optional()
|
|
19236
|
-
});
|
|
19237
|
-
});
|
|
19238
|
-
|
|
19239
|
-
// ../types/src/processor/configs/pdf-embedder.ts
|
|
19240
|
-
var PdfEmbedderInputSchema, PdfEmbedderOutputSchema, PdfEmbedderConfigSchema;
|
|
19241
|
-
var init_pdf_embedder = __esm(() => {
|
|
19242
|
-
init_zod();
|
|
19243
|
-
init_parser();
|
|
19244
|
-
PdfEmbedderInputSchema = exports_external.object({
|
|
19245
|
-
fileId: exports_external.string().describe("File ID from files table"),
|
|
19246
|
-
parseResult: exports_external.object({
|
|
19247
|
-
pages: exports_external.array(PageResultSchema),
|
|
19248
|
-
text: exports_external.string().optional()
|
|
19249
|
-
}).describe("Parse result from ai.parse step (must include word positions)")
|
|
19250
|
-
});
|
|
19251
|
-
PdfEmbedderOutputSchema = exports_external.object({
|
|
19252
|
-
fileId: exports_external.string().describe("File ID from files table"),
|
|
19253
|
-
pageCount: exports_external.number().describe("Number of pages in the output PDF"),
|
|
19254
|
-
wordCount: exports_external.number().describe("Number of words embedded"),
|
|
19255
|
-
text: exports_external.string().describe("Extracted text (from parse step)")
|
|
19256
|
-
});
|
|
19257
|
-
PdfEmbedderConfigSchema = exports_external.object({
|
|
19258
|
-
outputFilename: exports_external.string().optional().describe('Output filename - supports LiquidJS syntax e.g. "{{filename}}-searchable.pdf"'),
|
|
19259
|
-
confidenceThreshold: exports_external.number().min(0).max(1).default(0.7).describe("Minimum OCR confidence (0-1) to include a word. Lower = more words but more errors")
|
|
19260
|
-
}).prefault({});
|
|
19261
|
-
});
|
|
19262
|
-
|
|
19263
|
-
// ../types/src/processor/configs/split.ts
|
|
19264
|
-
var SplitInputSchema, SplitConfigSchema, ConfidenceLevelSchema, SplitOutputSchema;
|
|
19265
|
-
var init_split = __esm(() => {
|
|
19266
|
-
init_zod();
|
|
19267
|
-
SplitInputSchema = exports_external.object({
|
|
19268
|
-
pages: exports_external.array(exports_external.object({
|
|
19269
|
-
pageIndex: exports_external.number().describe("0-based page index"),
|
|
19270
|
-
text: exports_external.string().describe("Extracted text for this page"),
|
|
19271
|
-
pageName: exports_external.string().optional()
|
|
19272
|
-
})).min(1).describe("Per-page parsed content from a document parser")
|
|
19273
|
-
}).passthrough().describe("Document-parser-shaped input. Pass {{ steps.parse.output }} directly — extra fields like text/metadata are ignored.");
|
|
19274
|
-
SplitConfigSchema = exports_external.object({
|
|
19275
|
-
sections: exports_external.array(exports_external.object({
|
|
19276
|
-
name: exports_external.string().min(1).describe("Stable id for the section"),
|
|
19277
|
-
description: exports_external.string().min(1).describe("What this section looks like in the document. Use the document's own terminology (e.g. 'Príloha 2 / Anlage 2') and visual cues."),
|
|
19278
|
-
required: exports_external.boolean().optional().describe('If true, log a warn when this section is not found, and lean the LLM toward expecting it. Default: false (Reducto-style "may be absent").'),
|
|
19279
|
-
endHints: exports_external.array(exports_external.string()).optional().describe('Natural-language hints fed to the LLM about what marks the END of this section (e.g. ["PRÍPAD PORUŠENIA ZMLUVY", "*Koniec prílohy*", "the next chapter heading"]). The LLM uses these as guidance — not a regex match — so casing variants, missing diacritics, and multilingual phrasings still close the section correctly. The LLM emits a structured end_anchor per section it judges closed; deterministic merge applies it.')
|
|
19280
|
-
})).min(1),
|
|
19281
|
-
rules: exports_external.string().optional().describe("Optional natural-language rules appended to the system prompt"),
|
|
19282
|
-
provider: exports_external.string().optional().describe('Provider ID from eigenpal.config.yaml (e.g. "openai-gpt5.4-mini"). Falls back to the tenant default LLM provider when omitted.'),
|
|
19283
|
-
windowTokenBudget: exports_external.number().int().positive().optional().describe("Per-window token ceiling. Defaults to env SPLIT_WINDOW_TOKEN_BUDGET or 20000. Smaller windows give sharper anchors on contract-style documents (less competing context for the LLM to mis-anchor on); 50k–100k when sections routinely exceed per-window page count.")
|
|
19284
|
-
});
|
|
19285
|
-
ConfidenceLevelSchema = exports_external.enum(["low", "medium", "high"]).describe("LLM confidence as a coarse enum. Numeric (0..1) confidences cluster at 0.85–0.95 and gradations are noise; low/medium/high is reliable.");
|
|
19286
|
-
SplitOutputSchema = exports_external.object({
|
|
19287
|
-
splits: exports_external.array(exports_external.object({
|
|
19288
|
-
name: exports_external.string(),
|
|
19289
|
-
page_range: exports_external.tuple([exports_external.number().int(), exports_external.number().int()]),
|
|
19290
|
-
confidence: ConfidenceLevelSchema.describe("LLM confidence at the start anchor: low | medium | high."),
|
|
19291
|
-
notes: exports_external.string(),
|
|
19292
|
-
evidence: exports_external.object({
|
|
19293
|
-
start_heading_text: exports_external.string().nullable().optional().describe("Verbatim heading text the LLM cited as the section start"),
|
|
19294
|
-
start_page: exports_external.number().int().nullable().optional().describe("Page where start_heading_text appears")
|
|
19295
|
-
}).optional().describe("Structured start-anchor evidence the LLM cited — for downstream parsing without regex over `notes`."),
|
|
19296
|
-
end_evidence: exports_external.object({
|
|
19297
|
-
end_page: exports_external.number().int().describe("LAST page of the section (inclusive)"),
|
|
19298
|
-
confidence: ConfidenceLevelSchema,
|
|
19299
|
-
notes: exports_external.string().describe("LLM justification for the end. Pairs with start-anchor `notes` so a reconciliation pass can judge whether the section is correctly bounded.")
|
|
19300
|
-
}).optional().describe("Set when the LLM flagged a section close (matched against `endHints` or detected end-of-section markers). Absent when the section was closed by deterministic continuity-fill (next section start - 1)."),
|
|
19301
|
-
text: exports_external.string().describe("Joined per-page text for this section, ready for ai.extract"),
|
|
19302
|
-
pages: exports_external.array(exports_external.object({
|
|
19303
|
-
pageIndex: exports_external.number().int(),
|
|
19304
|
-
text: exports_external.string(),
|
|
19305
|
-
pageName: exports_external.string().optional(),
|
|
19306
|
-
source: exports_external.enum(["anchored", "inferred"]).describe("Whether this page was the LLM anchor (direct evidence) or filled in by continuity")
|
|
19307
|
-
})).describe("Raw per-page records covered by this split (in page order). Use when downstream needs to iterate page-by-page rather than treating the section as one blob."),
|
|
19308
|
-
pages_anchored: exports_external.array(exports_external.number().int()),
|
|
19309
|
-
pages_inferred: exports_external.array(exports_external.number().int())
|
|
19310
|
-
}))
|
|
19311
|
-
});
|
|
19312
|
-
});
|
|
19313
|
-
|
|
19314
|
-
// ../types/src/processor/configs/template.ts
|
|
19315
|
-
var TemplateInputSchema, TemplateOutputSchema, TemplateConfigSchema;
|
|
19316
|
-
var init_template = __esm(() => {
|
|
19317
|
-
init_zod();
|
|
19318
|
-
TemplateInputSchema = exports_external.object({
|
|
19319
|
-
data: exports_external.record(exports_external.string(), exports_external.unknown()).describe("Data to merge into the template")
|
|
19320
|
-
});
|
|
19321
|
-
TemplateOutputSchema = exports_external.object({
|
|
19322
|
-
fileId: exports_external.string().describe("File ID from files table")
|
|
19323
|
-
});
|
|
19324
|
-
TemplateConfigSchema = exports_external.object({
|
|
19325
|
-
templateId: exports_external.string().describe("ID of the template from templates table"),
|
|
19326
|
-
outputFilename: exports_external.string().optional().describe('Output filename - supports LiquidJS syntax e.g. "{{invoice_id}}-report.docx"'),
|
|
19327
|
-
highlightNotFound: exports_external.boolean().default(true).optional().describe("Highlight missing variables with red-colored text in the output document"),
|
|
19328
|
-
notFoundText: exports_external.string().default("NOT FOUND").optional().describe("Text to display for missing variables when highlightNotFound is enabled")
|
|
19329
|
-
});
|
|
19330
|
-
});
|
|
19331
|
-
|
|
19332
|
-
// ../types/src/processor/configs/xlsx-to-json.ts
|
|
19333
|
-
var XlsxToJsonInputSchema, XlsxToJsonOutputSchema, XlsxToJsonConfigSchema;
|
|
19334
|
-
var init_xlsx_to_json = __esm(() => {
|
|
19335
|
-
init_zod();
|
|
19336
|
-
init_document_parser();
|
|
19337
|
-
XlsxToJsonInputSchema = exports_external.union([FileIdInputSchema, FilePathDescriptorSchema]);
|
|
19338
|
-
XlsxToJsonOutputSchema = exports_external.object({
|
|
19339
|
-
rows: exports_external.array(exports_external.record(exports_external.string(), exports_external.unknown())).describe("Array of row objects (header row = keys)"),
|
|
19340
|
-
fileId: exports_external.string().optional().describe("File ID of stored CSV when outputCsv is true")
|
|
19341
|
-
});
|
|
19342
|
-
XlsxToJsonConfigSchema = exports_external.object({
|
|
19343
|
-
sheet: exports_external.union([exports_external.number().int().min(0), exports_external.string()]).optional().describe("Sheet to read: 0-based index or sheet name"),
|
|
19344
|
-
outputCsv: exports_external.boolean().default(false).optional(),
|
|
19345
|
-
outputFilename: exports_external.string().optional().describe("Output CSV filename when outputCsv is true")
|
|
19346
|
-
});
|
|
19347
|
-
});
|
|
19348
|
-
|
|
19349
|
-
// ../types/src/processor/configs/react-hook-form.ts
|
|
19350
|
-
function extractFieldMetadata(schema) {
|
|
19351
|
-
const fields = [];
|
|
19352
|
-
let inner = schema;
|
|
19353
|
-
while (inner instanceof exports_external.ZodDefault || inner instanceof exports_external.ZodPrefault) {
|
|
19354
|
-
inner = inner.unwrap();
|
|
19355
|
-
}
|
|
19356
|
-
if (inner instanceof exports_external.ZodObject) {
|
|
19357
|
-
for (const [name, fieldSchema] of Object.entries(inner.shape)) {
|
|
19358
|
-
fields.push(extractSingleFieldMetadata(name, fieldSchema));
|
|
19359
|
-
}
|
|
19360
|
-
}
|
|
19361
|
-
return fields;
|
|
19362
|
-
}
|
|
19363
|
-
function extractSingleFieldMetadata(name, schema) {
|
|
19364
|
-
let current = schema;
|
|
19365
|
-
let required2 = true;
|
|
19366
|
-
let defaultValue = undefined;
|
|
19367
|
-
let description = current.description;
|
|
19368
|
-
while (true) {
|
|
19369
|
-
if (current instanceof exports_external.ZodOptional) {
|
|
19370
|
-
required2 = false;
|
|
19371
|
-
current = current.unwrap();
|
|
19372
|
-
} else if (current instanceof exports_external.ZodDefault || current instanceof exports_external.ZodPrefault) {
|
|
19373
|
-
defaultValue = current._def.defaultValue;
|
|
19374
|
-
current = current.unwrap();
|
|
19375
|
-
} else {
|
|
19376
|
-
break;
|
|
19377
|
-
}
|
|
19378
|
-
description ??= current.description;
|
|
19379
|
-
}
|
|
19380
|
-
const base = { name, type: "unknown", required: required2, description, defaultValue };
|
|
19381
|
-
if (current instanceof exports_external.ZodString)
|
|
19382
|
-
return { ...base, type: "string" };
|
|
19383
|
-
if (current instanceof exports_external.ZodNumber) {
|
|
19384
|
-
let min;
|
|
19385
|
-
let max;
|
|
19386
|
-
for (const c of current._def.checks ?? []) {
|
|
19387
|
-
const def = c._zod.def;
|
|
19388
|
-
if (def.check === "greater_than")
|
|
19389
|
-
min = def.value;
|
|
19390
|
-
if (def.check === "less_than")
|
|
19391
|
-
max = def.value;
|
|
19392
|
-
}
|
|
19393
|
-
return { ...base, type: "number", min, max };
|
|
19394
|
-
}
|
|
19395
|
-
if (current instanceof exports_external.ZodBoolean)
|
|
19396
|
-
return { ...base, type: "boolean" };
|
|
19397
|
-
if (current instanceof exports_external.ZodEnum) {
|
|
19398
|
-
return { ...base, type: "enum", enumValues: current.options };
|
|
19399
|
-
}
|
|
19400
|
-
if (current instanceof exports_external.ZodArray)
|
|
19401
|
-
return { ...base, type: "array" };
|
|
19402
|
-
if (current instanceof exports_external.ZodObject || current instanceof exports_external.ZodRecord) {
|
|
19403
|
-
return { ...base, type: "object" };
|
|
19404
|
-
}
|
|
19405
|
-
return base;
|
|
19406
|
-
}
|
|
19407
|
-
function getConfigFieldMetadata(processorId) {
|
|
19408
|
-
const schema = getConfigSchema(processorId);
|
|
19409
|
-
if (!schema)
|
|
19410
|
-
return;
|
|
19411
|
-
return extractFieldMetadata(schema);
|
|
19412
|
-
}
|
|
19413
|
-
function getConfigDefaults(processorId) {
|
|
19414
|
-
const schema = PROCESSOR_SCHEMAS[processorId]?.configSchema;
|
|
19415
|
-
if (!schema)
|
|
19416
|
-
return {};
|
|
19417
|
-
try {
|
|
19418
|
-
const result = schema.safeParse({});
|
|
19419
|
-
if (result.success) {
|
|
19420
|
-
return result.data;
|
|
19421
|
-
}
|
|
19422
|
-
} catch {}
|
|
19423
|
-
const fields = extractFieldMetadata(schema);
|
|
19424
|
-
const defaults = {};
|
|
19425
|
-
for (const field of fields) {
|
|
19426
|
-
if (field.defaultValue !== undefined) {
|
|
19427
|
-
defaults[field.name] = field.defaultValue;
|
|
19428
|
-
}
|
|
19429
|
-
}
|
|
19430
|
-
return defaults;
|
|
19431
|
-
}
|
|
19432
|
-
function validateConfig(processorId, config2) {
|
|
19433
|
-
const schema = getConfigSchema(processorId);
|
|
19434
|
-
if (!schema) {
|
|
19435
|
-
return { valid: true, errors: {} };
|
|
19436
|
-
}
|
|
19437
|
-
const result = schema.safeParse(config2);
|
|
19438
|
-
if (result.success) {
|
|
19439
|
-
return { valid: true, errors: {} };
|
|
19440
|
-
}
|
|
19441
|
-
const errors3 = {};
|
|
19442
|
-
for (const issue2 of result.error.issues) {
|
|
19443
|
-
const path = issue2.path.join(".");
|
|
19444
|
-
errors3[path] = issue2.message;
|
|
19445
|
-
}
|
|
19446
|
-
return { valid: false, errors: errors3 };
|
|
19447
|
-
}
|
|
19448
|
-
var init_react_hook_form = __esm(() => {
|
|
19449
|
-
init_zod();
|
|
19450
|
-
init_configs();
|
|
19451
|
-
});
|
|
19452
|
-
|
|
19453
|
-
// ../types/src/processor/configs/index.ts
|
|
19454
|
-
function getProcessorSchemas(processorId) {
|
|
19455
|
-
return PROCESSOR_SCHEMAS[processorId];
|
|
19456
|
-
}
|
|
19457
|
-
function getConfigSchema(processorId) {
|
|
19458
|
-
return PROCESSOR_SCHEMAS[processorId]?.configSchema;
|
|
19459
|
-
}
|
|
19460
|
-
function getAllProcessorJsonSchemas() {
|
|
19461
|
-
return Object.values(PROCESSOR_SCHEMAS).map((p) => ({
|
|
19462
|
-
id: p.id,
|
|
19463
|
-
inputSchema: toJsonSchema(p.inputSchema),
|
|
19464
|
-
outputSchema: toJsonSchema(p.outputSchema),
|
|
19465
|
-
configSchema: toJsonSchema(p.configSchema)
|
|
19466
|
-
}));
|
|
19467
|
-
}
|
|
19468
|
-
function listProcessorIds() {
|
|
19469
|
-
return Object.keys(PROCESSOR_SCHEMAS);
|
|
19470
|
-
}
|
|
19471
|
-
var PROCESSOR_SCHEMAS;
|
|
19472
|
-
var init_configs = __esm(() => {
|
|
19473
|
-
init_common();
|
|
19474
|
-
init_ids();
|
|
19475
|
-
init_classify();
|
|
19476
|
-
init_document_parser();
|
|
19477
|
-
init_extract();
|
|
19478
|
-
init_merge();
|
|
19479
|
-
init_pdf_embedder();
|
|
19480
|
-
init_split();
|
|
19481
|
-
init_template();
|
|
19482
|
-
init_xlsx_to_json();
|
|
19483
|
-
init_react_hook_form();
|
|
19484
|
-
init_classify();
|
|
19485
|
-
init_document_parser();
|
|
19486
|
-
init_extract();
|
|
19487
|
-
init_merge();
|
|
19488
|
-
init_pdf_embedder();
|
|
19489
|
-
init_split();
|
|
19490
|
-
init_template();
|
|
19491
|
-
init_xlsx_to_json();
|
|
19492
|
-
PROCESSOR_SCHEMAS = {
|
|
19493
|
-
[PROCESSOR_IDS.EXTRACT]: {
|
|
19494
|
-
id: PROCESSOR_IDS.EXTRACT,
|
|
19495
|
-
inputSchema: ExtractInputSchema,
|
|
19496
|
-
outputSchema: ExtractOutputSchema,
|
|
19497
|
-
configSchema: ExtractConfigSchema
|
|
19498
|
-
},
|
|
19499
|
-
[PROCESSOR_IDS.DOCUMENT_PARSER]: {
|
|
19500
|
-
id: PROCESSOR_IDS.DOCUMENT_PARSER,
|
|
19501
|
-
inputSchema: DocumentParserInputSchema,
|
|
19502
|
-
outputSchema: DocumentParserOutputSchema,
|
|
19503
|
-
configSchema: DocumentParserConfigSchema
|
|
19504
|
-
},
|
|
19505
|
-
[PROCESSOR_IDS.MERGE]: {
|
|
19506
|
-
id: PROCESSOR_IDS.MERGE,
|
|
19507
|
-
inputSchema: MergeInputSchema,
|
|
19508
|
-
outputSchema: MergeOutputSchema,
|
|
19509
|
-
configSchema: MergeConfigSchema
|
|
19510
|
-
},
|
|
19511
|
-
[PROCESSOR_IDS.TEMPLATE]: {
|
|
19512
|
-
id: PROCESSOR_IDS.TEMPLATE,
|
|
19513
|
-
inputSchema: TemplateInputSchema,
|
|
19514
|
-
outputSchema: TemplateOutputSchema,
|
|
19515
|
-
configSchema: TemplateConfigSchema
|
|
19516
|
-
},
|
|
19517
|
-
[PROCESSOR_IDS.PDF_EMBEDDER]: {
|
|
19518
|
-
id: PROCESSOR_IDS.PDF_EMBEDDER,
|
|
19519
|
-
inputSchema: PdfEmbedderInputSchema,
|
|
19520
|
-
outputSchema: PdfEmbedderOutputSchema,
|
|
19521
|
-
configSchema: PdfEmbedderConfigSchema
|
|
19522
|
-
},
|
|
19523
|
-
[PROCESSOR_IDS.SPLIT]: {
|
|
19524
|
-
id: PROCESSOR_IDS.SPLIT,
|
|
19525
|
-
inputSchema: SplitInputSchema,
|
|
19526
|
-
outputSchema: SplitOutputSchema,
|
|
19527
|
-
configSchema: SplitConfigSchema
|
|
19528
|
-
},
|
|
19529
|
-
[PROCESSOR_IDS.CLASSIFY]: {
|
|
19530
|
-
id: PROCESSOR_IDS.CLASSIFY,
|
|
19531
|
-
inputSchema: ClassifyInputSchema,
|
|
19532
|
-
outputSchema: ClassifyOutputSchema,
|
|
19533
|
-
configSchema: ClassifyConfigSchema
|
|
19534
|
-
},
|
|
19535
|
-
[PROCESSOR_IDS.XLSX_TO_JSON]: {
|
|
19536
|
-
id: PROCESSOR_IDS.XLSX_TO_JSON,
|
|
19537
|
-
inputSchema: XlsxToJsonInputSchema,
|
|
19538
|
-
outputSchema: XlsxToJsonOutputSchema,
|
|
19539
|
-
configSchema: XlsxToJsonConfigSchema
|
|
19540
|
-
}
|
|
19541
|
-
};
|
|
19542
|
-
});
|
|
17084
|
+
var init_core3 = () => {};
|
|
19543
17085
|
|
|
19544
17086
|
// ../types/src/processor/index.ts
|
|
19545
|
-
var
|
|
19546
|
-
init_processor();
|
|
19547
|
-
init_execution();
|
|
19548
|
-
init_configs();
|
|
19549
|
-
});
|
|
17087
|
+
var init_processor = () => {};
|
|
19550
17088
|
|
|
19551
17089
|
// ../types/src/parser/index.ts
|
|
19552
|
-
var
|
|
19553
|
-
init_parser();
|
|
19554
|
-
});
|
|
17090
|
+
var init_parser = () => {};
|
|
19555
17091
|
|
|
19556
17092
|
// ../types/src/otel/semantic-conventions.ts
|
|
19557
17093
|
function mapLLMAttributes(attrs) {
|
|
@@ -22871,7 +20407,7 @@ var require_data = __commonJS((exports, module) => {
|
|
|
22871
20407
|
});
|
|
22872
20408
|
|
|
22873
20409
|
// ../../node_modules/fast-uri/lib/utils.js
|
|
22874
|
-
var
|
|
20410
|
+
var require_utils = __commonJS((exports, module) => {
|
|
22875
20411
|
var isUUID = RegExp.prototype.test.bind(/^[\da-f]{8}-[\da-f]{4}-[\da-f]{4}-[\da-f]{4}-[\da-f]{12}$/iu);
|
|
22876
20412
|
var isIPv4 = RegExp.prototype.test.bind(/^(?:(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)\.){3}(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)$/u);
|
|
22877
20413
|
function stringArrayToHexStripped(input) {
|
|
@@ -23127,7 +20663,7 @@ var require_utils3 = __commonJS((exports, module) => {
|
|
|
23127
20663
|
|
|
23128
20664
|
// ../../node_modules/fast-uri/lib/schemes.js
|
|
23129
20665
|
var require_schemes = __commonJS((exports, module) => {
|
|
23130
|
-
var { isUUID } =
|
|
20666
|
+
var { isUUID } = require_utils();
|
|
23131
20667
|
var URN_REG = /([\da-z][\d\-a-z]{0,31}):((?:[\w!$'()*+,\-.:;=@]|%[\da-f]{2})+)/iu;
|
|
23132
20668
|
var supportedSchemeNames = [
|
|
23133
20669
|
"http",
|
|
@@ -23301,7 +20837,7 @@ var require_schemes = __commonJS((exports, module) => {
|
|
|
23301
20837
|
|
|
23302
20838
|
// ../../node_modules/fast-uri/index.js
|
|
23303
20839
|
var require_fast_uri = __commonJS((exports, module) => {
|
|
23304
|
-
var { normalizeIPv6, removeDotSegments, recomposeAuthority, normalizeComponentEncoding, isIPv4, nonSimpleDomain } =
|
|
20840
|
+
var { normalizeIPv6, removeDotSegments, recomposeAuthority, normalizeComponentEncoding, isIPv4, nonSimpleDomain } = require_utils();
|
|
23305
20841
|
var { SCHEMES, getSchemeHandler } = require_schemes();
|
|
23306
20842
|
function normalize(uri, options) {
|
|
23307
20843
|
if (typeof uri === "string") {
|
|
@@ -25711,7 +23247,7 @@ var require_draft7 = __commonJS((exports) => {
|
|
|
25711
23247
|
});
|
|
25712
23248
|
|
|
25713
23249
|
// ../../node_modules/ajv/dist/vocabularies/discriminator/types.js
|
|
25714
|
-
var
|
|
23250
|
+
var require_types = __commonJS((exports) => {
|
|
25715
23251
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
25716
23252
|
exports.DiscrError = undefined;
|
|
25717
23253
|
var DiscrError;
|
|
@@ -25725,7 +23261,7 @@ var require_types2 = __commonJS((exports) => {
|
|
|
25725
23261
|
var require_discriminator = __commonJS((exports) => {
|
|
25726
23262
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
25727
23263
|
var codegen_1 = require_codegen();
|
|
25728
|
-
var types_1 =
|
|
23264
|
+
var types_1 = require_types();
|
|
25729
23265
|
var compile_1 = require_compile();
|
|
25730
23266
|
var ref_error_1 = require_ref_error();
|
|
25731
23267
|
var util_1 = require_util();
|
|
@@ -26658,6 +24194,24 @@ var init_validation = __esm(() => {
|
|
|
26658
24194
|
init_workspace_schema();
|
|
26659
24195
|
});
|
|
26660
24196
|
|
|
24197
|
+
// ../types/src/core/common.ts
|
|
24198
|
+
function toJsonSchema2(schema) {
|
|
24199
|
+
return exports_external.toJSONSchema(schema, { target: "draft-7" });
|
|
24200
|
+
}
|
|
24201
|
+
var TimestampSchema2, JsonSchemaSchema2, BaseEntitySchema2;
|
|
24202
|
+
var init_common = __esm(() => {
|
|
24203
|
+
init_zod();
|
|
24204
|
+
TimestampSchema2 = exports_external.union([exports_external.date(), exports_external.string().datetime()]).transform((val) => {
|
|
24205
|
+
return typeof val === "string" ? new Date(val) : val;
|
|
24206
|
+
});
|
|
24207
|
+
JsonSchemaSchema2 = exports_external.record(exports_external.string(), exports_external.unknown());
|
|
24208
|
+
BaseEntitySchema2 = exports_external.object({
|
|
24209
|
+
id: exports_external.string(),
|
|
24210
|
+
createdAt: TimestampSchema2.optional(),
|
|
24211
|
+
updatedAt: TimestampSchema2.optional()
|
|
24212
|
+
});
|
|
24213
|
+
});
|
|
24214
|
+
|
|
26661
24215
|
// ../../node_modules/@babel/parser/lib/index.js
|
|
26662
24216
|
var require_lib = __commonJS((exports) => {
|
|
26663
24217
|
Object.defineProperty(exports, "__esModule", {
|
|
@@ -27071,12 +24625,12 @@ var require_lib = __commonJS((exports) => {
|
|
|
27071
24625
|
}
|
|
27072
24626
|
const ParseErrorConstructors = {};
|
|
27073
24627
|
for (const reasonCode of Object.keys(argument)) {
|
|
27074
|
-
const
|
|
27075
|
-
const _ref = typeof
|
|
27076
|
-
message: () =>
|
|
27077
|
-
} : typeof
|
|
27078
|
-
message:
|
|
27079
|
-
} :
|
|
24628
|
+
const template = argument[reasonCode];
|
|
24629
|
+
const _ref = typeof template === "string" ? {
|
|
24630
|
+
message: () => template
|
|
24631
|
+
} : typeof template === "function" ? {
|
|
24632
|
+
message: template
|
|
24633
|
+
} : template, {
|
|
27080
24634
|
message
|
|
27081
24635
|
} = _ref, rest = _objectWithoutPropertiesLoose(_ref, _excluded);
|
|
27082
24636
|
const toMessage = typeof message === "string" ? () => message : message;
|
|
@@ -41549,7 +39103,7 @@ var require_keywords = __commonJS((exports) => {
|
|
|
41549
39103
|
});
|
|
41550
39104
|
|
|
41551
39105
|
// ../../node_modules/sucrase/dist/parser/tokenizer/types.js
|
|
41552
|
-
var
|
|
39106
|
+
var require_types2 = __commonJS((exports) => {
|
|
41553
39107
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
41554
39108
|
var TokenType;
|
|
41555
39109
|
(function(TokenType2) {
|
|
@@ -41613,8 +39167,8 @@ var require_types3 = __commonJS((exports) => {
|
|
|
41613
39167
|
TokenType2[TokenType2["questionDot"] = questionDot] = "questionDot";
|
|
41614
39168
|
const arrow = 22528;
|
|
41615
39169
|
TokenType2[TokenType2["arrow"] = arrow] = "arrow";
|
|
41616
|
-
const
|
|
41617
|
-
TokenType2[TokenType2["template"] =
|
|
39170
|
+
const template = 23552;
|
|
39171
|
+
TokenType2[TokenType2["template"] = template] = "template";
|
|
41618
39172
|
const ellipsis = 24576;
|
|
41619
39173
|
TokenType2[TokenType2["ellipsis"] = ellipsis] = "ellipsis";
|
|
41620
39174
|
const backQuote = 25600;
|
|
@@ -42033,7 +39587,7 @@ var require_types3 = __commonJS((exports) => {
|
|
|
42033
39587
|
var require_state = __commonJS((exports) => {
|
|
42034
39588
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
42035
39589
|
var _keywords = require_keywords();
|
|
42036
|
-
var _types =
|
|
39590
|
+
var _types = require_types2();
|
|
42037
39591
|
|
|
42038
39592
|
class Scope {
|
|
42039
39593
|
constructor(startTokenIndex, endTokenIndex, isFunctionScope) {
|
|
@@ -42419,7 +39973,7 @@ var require_base = __commonJS((exports) => {
|
|
|
42419
39973
|
var require_util2 = __commonJS((exports) => {
|
|
42420
39974
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
42421
39975
|
var _index = require_tokenizer();
|
|
42422
|
-
var _types =
|
|
39976
|
+
var _types = require_types2();
|
|
42423
39977
|
var _charcodes = require_charcodes();
|
|
42424
39978
|
var _base = require_base();
|
|
42425
39979
|
function isContextual(contextualKeyword) {
|
|
@@ -42581,7 +40135,7 @@ var require_identifier = __commonJS((exports) => {
|
|
|
42581
40135
|
var require_readWordTree = __commonJS((exports) => {
|
|
42582
40136
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
42583
40137
|
var _keywords = require_keywords();
|
|
42584
|
-
var _types =
|
|
40138
|
+
var _types = require_types2();
|
|
42585
40139
|
var READ_WORD_TREE = new Int32Array([
|
|
42586
40140
|
-1,
|
|
42587
40141
|
27,
|
|
@@ -51559,7 +49113,7 @@ var require_readWord = __commonJS((exports) => {
|
|
|
51559
49113
|
var _identifier = require_identifier();
|
|
51560
49114
|
var _index = require_tokenizer();
|
|
51561
49115
|
var _readWordTree = require_readWordTree();
|
|
51562
|
-
var _types =
|
|
49116
|
+
var _types = require_types2();
|
|
51563
49117
|
function readWord() {
|
|
51564
49118
|
let treePos = 0;
|
|
51565
49119
|
let code = 0;
|
|
@@ -51625,7 +49179,7 @@ var require_tokenizer = __commonJS((exports) => {
|
|
|
51625
49179
|
var _keywords = require_keywords();
|
|
51626
49180
|
var _readWord = require_readWord();
|
|
51627
49181
|
var _readWord2 = _interopRequireDefault(_readWord);
|
|
51628
|
-
var _types =
|
|
49182
|
+
var _types = require_types2();
|
|
51629
49183
|
var IdentifierRole;
|
|
51630
49184
|
(function(IdentifierRole2) {
|
|
51631
49185
|
const Access = 0;
|
|
@@ -52342,7 +49896,7 @@ var require_tokenizer = __commonJS((exports) => {
|
|
|
52342
49896
|
// ../../node_modules/sucrase/dist/util/getImportExportSpecifierInfo.js
|
|
52343
49897
|
var require_getImportExportSpecifierInfo = __commonJS((exports) => {
|
|
52344
49898
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
52345
|
-
var _types =
|
|
49899
|
+
var _types = require_types2();
|
|
52346
49900
|
function getImportExportSpecifierInfo(tokens, index = tokens.currentIndex()) {
|
|
52347
49901
|
let endIndex = index + 1;
|
|
52348
49902
|
if (isSpecifierEnd(tokens, endIndex)) {
|
|
@@ -52695,7 +50249,7 @@ var require_JSXTransformer = __commonJS((exports) => {
|
|
|
52695
50249
|
var _xhtml = require_xhtml();
|
|
52696
50250
|
var _xhtml2 = _interopRequireDefault(_xhtml);
|
|
52697
50251
|
var _tokenizer = require_tokenizer();
|
|
52698
|
-
var _types =
|
|
50252
|
+
var _types = require_types2();
|
|
52699
50253
|
var _charcodes = require_charcodes();
|
|
52700
50254
|
var _getJSXPragmaInfo = require_getJSXPragmaInfo();
|
|
52701
50255
|
var _getJSXPragmaInfo2 = _interopRequireDefault(_getJSXPragmaInfo);
|
|
@@ -53199,7 +50753,7 @@ var require_getNonTypeIdentifiers = __commonJS((exports) => {
|
|
|
53199
50753
|
return obj && obj.__esModule ? obj : { default: obj };
|
|
53200
50754
|
}
|
|
53201
50755
|
var _tokenizer = require_tokenizer();
|
|
53202
|
-
var _types =
|
|
50756
|
+
var _types = require_types2();
|
|
53203
50757
|
var _JSXTransformer = require_JSXTransformer();
|
|
53204
50758
|
var _getJSXPragmaInfo = require_getJSXPragmaInfo();
|
|
53205
50759
|
var _getJSXPragmaInfo2 = _interopRequireDefault(_getJSXPragmaInfo);
|
|
@@ -53238,7 +50792,7 @@ var require_CJSImportProcessor = __commonJS((exports) => {
|
|
|
53238
50792
|
}
|
|
53239
50793
|
var _tokenizer = require_tokenizer();
|
|
53240
50794
|
var _keywords = require_keywords();
|
|
53241
|
-
var _types =
|
|
50795
|
+
var _types = require_types2();
|
|
53242
50796
|
var _getImportExportSpecifierInfo = require_getImportExportSpecifierInfo();
|
|
53243
50797
|
var _getImportExportSpecifierInfo2 = _interopRequireDefault(_getImportExportSpecifierInfo);
|
|
53244
50798
|
var _getNonTypeIdentifiers = require_getNonTypeIdentifiers();
|
|
@@ -55273,7 +52827,7 @@ var require_HelperManager = __commonJS((exports) => {
|
|
|
55273
52827
|
var require_identifyShadowedGlobals = __commonJS((exports) => {
|
|
55274
52828
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
55275
52829
|
var _tokenizer = require_tokenizer();
|
|
55276
|
-
var _types =
|
|
52830
|
+
var _types = require_types2();
|
|
55277
52831
|
function identifyShadowedGlobals(tokens, scopes, globalNames) {
|
|
55278
52832
|
if (!hasShadowedGlobals(tokens, globalNames)) {
|
|
55279
52833
|
return;
|
|
@@ -55338,7 +52892,7 @@ var require_identifyShadowedGlobals = __commonJS((exports) => {
|
|
|
55338
52892
|
// ../../node_modules/sucrase/dist/util/getIdentifierNames.js
|
|
55339
52893
|
var require_getIdentifierNames = __commonJS((exports) => {
|
|
55340
52894
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
55341
|
-
var _types =
|
|
52895
|
+
var _types = require_types2();
|
|
55342
52896
|
function getIdentifierNames(code, tokens) {
|
|
55343
52897
|
const names = [];
|
|
55344
52898
|
for (const token of tokens) {
|
|
@@ -55514,7 +53068,7 @@ var require_util3 = __commonJS((exports) => {
|
|
|
55514
53068
|
});
|
|
55515
53069
|
|
|
55516
53070
|
// ../../node_modules/ts-interface-checker/dist/types.js
|
|
55517
|
-
var
|
|
53071
|
+
var require_types3 = __commonJS((exports) => {
|
|
55518
53072
|
var __extends = exports && exports.__extends || function() {
|
|
55519
53073
|
var extendStatics = function(d, b) {
|
|
55520
53074
|
extendStatics = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(d2, b2) {
|
|
@@ -56114,9 +53668,9 @@ var require_dist2 = __commonJS((exports) => {
|
|
|
56114
53668
|
};
|
|
56115
53669
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
56116
53670
|
exports.Checker = exports.createCheckers = undefined;
|
|
56117
|
-
var types_1 =
|
|
53671
|
+
var types_1 = require_types3();
|
|
56118
53672
|
var util_1 = require_util3();
|
|
56119
|
-
var types_2 =
|
|
53673
|
+
var types_2 = require_types3();
|
|
56120
53674
|
Object.defineProperty(exports, "TArray", { enumerable: true, get: function() {
|
|
56121
53675
|
return types_2.TArray;
|
|
56122
53676
|
} });
|
|
@@ -56398,7 +53952,7 @@ var require_lval = __commonJS((exports) => {
|
|
|
56398
53952
|
var _typescript = require_typescript();
|
|
56399
53953
|
var _index = require_tokenizer();
|
|
56400
53954
|
var _keywords = require_keywords();
|
|
56401
|
-
var _types =
|
|
53955
|
+
var _types = require_types2();
|
|
56402
53956
|
var _base = require_base();
|
|
56403
53957
|
var _expression = require_expression();
|
|
56404
53958
|
var _util = require_util2();
|
|
@@ -56530,7 +54084,7 @@ var require_typescript = __commonJS((exports) => {
|
|
|
56530
54084
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
56531
54085
|
var _index = require_tokenizer();
|
|
56532
54086
|
var _keywords = require_keywords();
|
|
56533
|
-
var _types =
|
|
54087
|
+
var _types = require_types2();
|
|
56534
54088
|
var _base = require_base();
|
|
56535
54089
|
var _expression = require_expression();
|
|
56536
54090
|
var _lval = require_lval();
|
|
@@ -57792,7 +55346,7 @@ var require_typescript = __commonJS((exports) => {
|
|
|
57792
55346
|
var require_jsx = __commonJS((exports) => {
|
|
57793
55347
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
57794
55348
|
var _index = require_tokenizer();
|
|
57795
|
-
var _types =
|
|
55349
|
+
var _types = require_types2();
|
|
57796
55350
|
var _base = require_base();
|
|
57797
55351
|
var _expression = require_expression();
|
|
57798
55352
|
var _util = require_util2();
|
|
@@ -58055,10 +55609,10 @@ var require_jsx = __commonJS((exports) => {
|
|
|
58055
55609
|
});
|
|
58056
55610
|
|
|
58057
55611
|
// ../../node_modules/sucrase/dist/parser/plugins/types.js
|
|
58058
|
-
var
|
|
55612
|
+
var require_types4 = __commonJS((exports) => {
|
|
58059
55613
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
58060
55614
|
var _index = require_tokenizer();
|
|
58061
|
-
var _types =
|
|
55615
|
+
var _types = require_types2();
|
|
58062
55616
|
var _base = require_base();
|
|
58063
55617
|
var _expression = require_expression();
|
|
58064
55618
|
var _flow = require_flow();
|
|
@@ -58091,12 +55645,12 @@ var require_expression = __commonJS((exports) => {
|
|
|
58091
55645
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
58092
55646
|
var _flow = require_flow();
|
|
58093
55647
|
var _index = require_jsx();
|
|
58094
|
-
var _types =
|
|
55648
|
+
var _types = require_types4();
|
|
58095
55649
|
var _typescript = require_typescript();
|
|
58096
55650
|
var _index3 = require_tokenizer();
|
|
58097
55651
|
var _keywords = require_keywords();
|
|
58098
55652
|
var _state = require_state();
|
|
58099
|
-
var _types3 =
|
|
55653
|
+
var _types3 = require_types2();
|
|
58100
55654
|
var _charcodes = require_charcodes();
|
|
58101
55655
|
var _identifier = require_identifier();
|
|
58102
55656
|
var _base = require_base();
|
|
@@ -58812,7 +56366,7 @@ var require_flow = __commonJS((exports) => {
|
|
|
58812
56366
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
58813
56367
|
var _index = require_tokenizer();
|
|
58814
56368
|
var _keywords = require_keywords();
|
|
58815
|
-
var _types =
|
|
56369
|
+
var _types = require_types2();
|
|
58816
56370
|
var _base = require_base();
|
|
58817
56371
|
var _expression = require_expression();
|
|
58818
56372
|
var _statement = require_statement();
|
|
@@ -59687,7 +57241,7 @@ var require_statement = __commonJS((exports) => {
|
|
|
59687
57241
|
var _tokenizer = require_tokenizer();
|
|
59688
57242
|
var _keywords = require_keywords();
|
|
59689
57243
|
var _state = require_state();
|
|
59690
|
-
var _types =
|
|
57244
|
+
var _types = require_types2();
|
|
59691
57245
|
var _charcodes = require_charcodes();
|
|
59692
57246
|
var _base = require_base();
|
|
59693
57247
|
var _expression = require_expression();
|
|
@@ -60722,7 +58276,7 @@ var require_TokenProcessor = __commonJS((exports) => {
|
|
|
60722
58276
|
function _interopRequireDefault(obj) {
|
|
60723
58277
|
return obj && obj.__esModule ? obj : { default: obj };
|
|
60724
58278
|
}
|
|
60725
|
-
var _types =
|
|
58279
|
+
var _types = require_types2();
|
|
60726
58280
|
var _isAsyncOperation = require_isAsyncOperation();
|
|
60727
58281
|
var _isAsyncOperation2 = _interopRequireDefault(_isAsyncOperation);
|
|
60728
58282
|
|
|
@@ -60980,7 +58534,7 @@ var require_TokenProcessor = __commonJS((exports) => {
|
|
|
60980
58534
|
var require_getClassInfo = __commonJS((exports) => {
|
|
60981
58535
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
60982
58536
|
var _keywords = require_keywords();
|
|
60983
|
-
var _types =
|
|
58537
|
+
var _types = require_types2();
|
|
60984
58538
|
function getClassInfo(rootTransformer, tokens, nameManager, disableESTransforms) {
|
|
60985
58539
|
const snapshot = tokens.snapshot();
|
|
60986
58540
|
const headerInfo = processClassHeader(tokens);
|
|
@@ -61218,7 +58772,7 @@ var require_getClassInfo = __commonJS((exports) => {
|
|
|
61218
58772
|
// ../../node_modules/sucrase/dist/util/elideImportEquals.js
|
|
61219
58773
|
var require_elideImportEquals = __commonJS((exports) => {
|
|
61220
58774
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
61221
|
-
var _types =
|
|
58775
|
+
var _types = require_types2();
|
|
61222
58776
|
function elideImportEquals(tokens) {
|
|
61223
58777
|
tokens.removeInitialToken();
|
|
61224
58778
|
tokens.removeToken();
|
|
@@ -61242,7 +58796,7 @@ var require_elideImportEquals = __commonJS((exports) => {
|
|
|
61242
58796
|
var require_getDeclarationInfo = __commonJS((exports) => {
|
|
61243
58797
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
61244
58798
|
var _tokenizer = require_tokenizer();
|
|
61245
|
-
var _types =
|
|
58799
|
+
var _types = require_types2();
|
|
61246
58800
|
var EMPTY_DECLARATION_INFO = {
|
|
61247
58801
|
typeDeclarations: new Set,
|
|
61248
58802
|
valueDeclarations: new Set
|
|
@@ -61270,7 +58824,7 @@ var require_getDeclarationInfo = __commonJS((exports) => {
|
|
|
61270
58824
|
var require_isExportFrom = __commonJS((exports) => {
|
|
61271
58825
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
61272
58826
|
var _keywords = require_keywords();
|
|
61273
|
-
var _types =
|
|
58827
|
+
var _types = require_types2();
|
|
61274
58828
|
function isExportFrom(tokens) {
|
|
61275
58829
|
let closeBraceIndex = tokens.currentIndex();
|
|
61276
58830
|
while (!tokens.matches1AtIndex(closeBraceIndex, _types.TokenType.braceR)) {
|
|
@@ -61285,7 +58839,7 @@ var require_isExportFrom = __commonJS((exports) => {
|
|
|
61285
58839
|
var require_removeMaybeImportAttributes = __commonJS((exports) => {
|
|
61286
58840
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
61287
58841
|
var _keywords = require_keywords();
|
|
61288
|
-
var _types =
|
|
58842
|
+
var _types = require_types2();
|
|
61289
58843
|
function removeMaybeImportAttributes(tokens) {
|
|
61290
58844
|
if (tokens.matches2(_types.TokenType._with, _types.TokenType.braceL) || tokens.matches2(_types.TokenType.name, _types.TokenType.braceL) && tokens.matchesContextual(_keywords.ContextualKeyword._assert)) {
|
|
61291
58845
|
tokens.removeToken();
|
|
@@ -61300,7 +58854,7 @@ var require_removeMaybeImportAttributes = __commonJS((exports) => {
|
|
|
61300
58854
|
// ../../node_modules/sucrase/dist/util/shouldElideDefaultExport.js
|
|
61301
58855
|
var require_shouldElideDefaultExport = __commonJS((exports) => {
|
|
61302
58856
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
61303
|
-
var _types =
|
|
58857
|
+
var _types = require_types2();
|
|
61304
58858
|
function shouldElideDefaultExport(isTypeScriptTransformEnabled, keepUnusedImports, tokens, declarationInfo) {
|
|
61305
58859
|
if (!isTypeScriptTransformEnabled || keepUnusedImports) {
|
|
61306
58860
|
return false;
|
|
@@ -61331,7 +58885,7 @@ var require_CJSImportTransformer = __commonJS((exports) => {
|
|
|
61331
58885
|
}
|
|
61332
58886
|
var _tokenizer = require_tokenizer();
|
|
61333
58887
|
var _keywords = require_keywords();
|
|
61334
|
-
var _types =
|
|
58888
|
+
var _types = require_types2();
|
|
61335
58889
|
var _elideImportEquals = require_elideImportEquals();
|
|
61336
58890
|
var _elideImportEquals2 = _interopRequireDefault(_elideImportEquals);
|
|
61337
58891
|
var _getDeclarationInfo = require_getDeclarationInfo();
|
|
@@ -61973,7 +59527,7 @@ var require_ESMImportTransformer = __commonJS((exports) => {
|
|
|
61973
59527
|
return obj && obj.__esModule ? obj : { default: obj };
|
|
61974
59528
|
}
|
|
61975
59529
|
var _keywords = require_keywords();
|
|
61976
|
-
var _types =
|
|
59530
|
+
var _types = require_types2();
|
|
61977
59531
|
var _elideImportEquals = require_elideImportEquals();
|
|
61978
59532
|
var _elideImportEquals2 = _interopRequireDefault(_elideImportEquals);
|
|
61979
59533
|
var _getDeclarationInfo = require_getDeclarationInfo();
|
|
@@ -62243,7 +59797,7 @@ var require_FlowTransformer = __commonJS((exports) => {
|
|
|
62243
59797
|
return obj && obj.__esModule ? obj : { default: obj };
|
|
62244
59798
|
}
|
|
62245
59799
|
var _keywords = require_keywords();
|
|
62246
|
-
var _types =
|
|
59800
|
+
var _types = require_types2();
|
|
62247
59801
|
var _Transformer = require_Transformer();
|
|
62248
59802
|
var _Transformer2 = _interopRequireDefault(_Transformer);
|
|
62249
59803
|
|
|
@@ -62363,7 +59917,7 @@ var require_JestHoistTransformer = __commonJS((exports) => {
|
|
|
62363
59917
|
}
|
|
62364
59918
|
return value;
|
|
62365
59919
|
}
|
|
62366
|
-
var _types =
|
|
59920
|
+
var _types = require_types2();
|
|
62367
59921
|
var _Transformer = require_Transformer();
|
|
62368
59922
|
var _Transformer2 = _interopRequireDefault(_Transformer);
|
|
62369
59923
|
var JEST_GLOBAL_NAME = "jest";
|
|
@@ -62437,7 +59991,7 @@ var require_NumericSeparatorTransformer = __commonJS((exports) => {
|
|
|
62437
59991
|
function _interopRequireDefault(obj) {
|
|
62438
59992
|
return obj && obj.__esModule ? obj : { default: obj };
|
|
62439
59993
|
}
|
|
62440
|
-
var _types =
|
|
59994
|
+
var _types = require_types2();
|
|
62441
59995
|
var _Transformer = require_Transformer();
|
|
62442
59996
|
var _Transformer2 = _interopRequireDefault(_Transformer);
|
|
62443
59997
|
|
|
@@ -62466,7 +60020,7 @@ var require_OptionalCatchBindingTransformer = __commonJS((exports) => {
|
|
|
62466
60020
|
function _interopRequireDefault(obj) {
|
|
62467
60021
|
return obj && obj.__esModule ? obj : { default: obj };
|
|
62468
60022
|
}
|
|
62469
|
-
var _types =
|
|
60023
|
+
var _types = require_types2();
|
|
62470
60024
|
var _Transformer = require_Transformer();
|
|
62471
60025
|
var _Transformer2 = _interopRequireDefault(_Transformer);
|
|
62472
60026
|
|
|
@@ -62494,7 +60048,7 @@ var require_OptionalChainingNullishTransformer = __commonJS((exports) => {
|
|
|
62494
60048
|
function _interopRequireDefault(obj) {
|
|
62495
60049
|
return obj && obj.__esModule ? obj : { default: obj };
|
|
62496
60050
|
}
|
|
62497
|
-
var _types =
|
|
60051
|
+
var _types = require_types2();
|
|
62498
60052
|
var _Transformer = require_Transformer();
|
|
62499
60053
|
var _Transformer2 = _interopRequireDefault(_Transformer);
|
|
62500
60054
|
|
|
@@ -62610,7 +60164,7 @@ var require_ReactDisplayNameTransformer = __commonJS((exports) => {
|
|
|
62610
60164
|
return obj && obj.__esModule ? obj : { default: obj };
|
|
62611
60165
|
}
|
|
62612
60166
|
var _tokenizer = require_tokenizer();
|
|
62613
|
-
var _types =
|
|
60167
|
+
var _types = require_types2();
|
|
62614
60168
|
var _Transformer = require_Transformer();
|
|
62615
60169
|
var _Transformer2 = _interopRequireDefault(_Transformer);
|
|
62616
60170
|
|
|
@@ -62861,7 +60415,7 @@ var require_TypeScriptTransformer = __commonJS((exports) => {
|
|
|
62861
60415
|
function _interopRequireDefault(obj) {
|
|
62862
60416
|
return obj && obj.__esModule ? obj : { default: obj };
|
|
62863
60417
|
}
|
|
62864
|
-
var _types =
|
|
60418
|
+
var _types = require_types2();
|
|
62865
60419
|
var _isIdentifier = require_isIdentifier();
|
|
62866
60420
|
var _isIdentifier2 = _interopRequireDefault(_isIdentifier);
|
|
62867
60421
|
var _Transformer = require_Transformer();
|
|
@@ -63007,7 +60561,7 @@ var require_RootTransformer = __commonJS((exports) => {
|
|
|
63007
60561
|
return obj && obj.__esModule ? obj : { default: obj };
|
|
63008
60562
|
}
|
|
63009
60563
|
var _keywords = require_keywords();
|
|
63010
|
-
var _types =
|
|
60564
|
+
var _types = require_types2();
|
|
63011
60565
|
var _getClassInfo = require_getClassInfo();
|
|
63012
60566
|
var _getClassInfo2 = _interopRequireDefault(_getClassInfo);
|
|
63013
60567
|
var _CJSImportTransformer = require_CJSImportTransformer();
|
|
@@ -63406,7 +60960,7 @@ var require_formatTokens = __commonJS((exports) => {
|
|
|
63406
60960
|
}
|
|
63407
60961
|
var _linesandcolumns = require_build();
|
|
63408
60962
|
var _linesandcolumns2 = _interopRequireDefault(_linesandcolumns);
|
|
63409
|
-
var _types =
|
|
60963
|
+
var _types = require_types2();
|
|
63410
60964
|
function formatTokens(code, tokens) {
|
|
63411
60965
|
if (tokens.length === 0) {
|
|
63412
60966
|
return "";
|
|
@@ -63471,7 +61025,7 @@ var require_getTSImportedNames = __commonJS((exports) => {
|
|
|
63471
61025
|
function _interopRequireDefault(obj) {
|
|
63472
61026
|
return obj && obj.__esModule ? obj : { default: obj };
|
|
63473
61027
|
}
|
|
63474
|
-
var _types =
|
|
61028
|
+
var _types = require_types2();
|
|
63475
61029
|
var _getImportExportSpecifierInfo = require_getImportExportSpecifierInfo();
|
|
63476
61030
|
var _getImportExportSpecifierInfo2 = _interopRequireDefault(_getImportExportSpecifierInfo);
|
|
63477
61031
|
function getTSImportedNames(tokens) {
|
|
@@ -63856,7 +61410,7 @@ function describeUnsupportedType(nodeType) {
|
|
|
63856
61410
|
function compileTypedScript(opts) {
|
|
63857
61411
|
let ast;
|
|
63858
61412
|
try {
|
|
63859
|
-
ast =
|
|
61413
|
+
ast = import_parser2.parse(opts.source, {
|
|
63860
61414
|
sourceType: "script",
|
|
63861
61415
|
plugins: ["typescript"],
|
|
63862
61416
|
ranges: true
|
|
@@ -64108,9 +61662,9 @@ function stripCommentsAndStrings(s) {
|
|
|
64108
61662
|
out = out.replace(/`(\\.|[^`\\])*`/g, "``");
|
|
64109
61663
|
return out;
|
|
64110
61664
|
}
|
|
64111
|
-
var
|
|
61665
|
+
var import_parser2, import_sucrase, EVALUATOR_FN_NAME = "scoreScript", EVALUATOR_PARAM_NAMES, TRANSFORM_FN_NAME = "script";
|
|
64112
61666
|
var init_compile = __esm(() => {
|
|
64113
|
-
|
|
61667
|
+
import_parser2 = __toESM(require_lib(), 1);
|
|
64114
61668
|
import_sucrase = __toESM(require_dist3(), 1);
|
|
64115
61669
|
EVALUATOR_PARAM_NAMES = ["expected", "actual"];
|
|
64116
61670
|
});
|
|
@@ -64324,8 +61878,8 @@ function getAllStepJsonSchemas() {
|
|
|
64324
61878
|
category: def.category,
|
|
64325
61879
|
name: def.name,
|
|
64326
61880
|
description: def.description,
|
|
64327
|
-
configSchema:
|
|
64328
|
-
outputSchema:
|
|
61881
|
+
configSchema: toJsonSchema2(def.configSchema),
|
|
61882
|
+
outputSchema: toJsonSchema2(def.outputSchema),
|
|
64329
61883
|
configInWith: def.configInWith
|
|
64330
61884
|
}));
|
|
64331
61885
|
}
|
|
@@ -64971,6 +62525,81 @@ var init_actions = __esm(() => {
|
|
|
64971
62525
|
ACTION_TYPES = ActionTypeSchema.options;
|
|
64972
62526
|
});
|
|
64973
62527
|
|
|
62528
|
+
// ../types/src/processor/execution.ts
|
|
62529
|
+
function asTuple(values) {
|
|
62530
|
+
return values;
|
|
62531
|
+
}
|
|
62532
|
+
var WorkflowExecutionStatusValue2, WorkflowExecutionStatusSchema2, StepExecutionStatusValue2, StepExecutionStatusSchema2, TriggerTypeValue2, TriggerTypeSchema2, ExecutionTypeValue2, ExecutionTypeSchema2, WORKFLOW_EXECUTION_STATUSES2, STEP_EXECUTION_STATUSES2, TRIGGER_TYPES2, EXECUTION_TYPES2;
|
|
62533
|
+
var init_execution = __esm(() => {
|
|
62534
|
+
init_zod();
|
|
62535
|
+
WorkflowExecutionStatusValue2 = {
|
|
62536
|
+
CREATED: "created",
|
|
62537
|
+
PENDING: "pending",
|
|
62538
|
+
RUNNING: "running",
|
|
62539
|
+
WAITING: "waiting",
|
|
62540
|
+
COMPLETED: "completed",
|
|
62541
|
+
FAILED: "failed",
|
|
62542
|
+
CANCELLED: "cancelled"
|
|
62543
|
+
};
|
|
62544
|
+
WorkflowExecutionStatusSchema2 = exports_external.enum([
|
|
62545
|
+
WorkflowExecutionStatusValue2.CREATED,
|
|
62546
|
+
WorkflowExecutionStatusValue2.PENDING,
|
|
62547
|
+
WorkflowExecutionStatusValue2.RUNNING,
|
|
62548
|
+
WorkflowExecutionStatusValue2.WAITING,
|
|
62549
|
+
WorkflowExecutionStatusValue2.COMPLETED,
|
|
62550
|
+
WorkflowExecutionStatusValue2.FAILED,
|
|
62551
|
+
WorkflowExecutionStatusValue2.CANCELLED
|
|
62552
|
+
]);
|
|
62553
|
+
StepExecutionStatusValue2 = {
|
|
62554
|
+
PENDING: "pending",
|
|
62555
|
+
RUNNING: "running",
|
|
62556
|
+
SUCCESS: "success",
|
|
62557
|
+
FAILURE: "failure",
|
|
62558
|
+
WAITING: "waiting",
|
|
62559
|
+
SKIPPED: "skipped"
|
|
62560
|
+
};
|
|
62561
|
+
StepExecutionStatusSchema2 = exports_external.enum([
|
|
62562
|
+
StepExecutionStatusValue2.PENDING,
|
|
62563
|
+
StepExecutionStatusValue2.RUNNING,
|
|
62564
|
+
StepExecutionStatusValue2.SUCCESS,
|
|
62565
|
+
StepExecutionStatusValue2.FAILURE,
|
|
62566
|
+
StepExecutionStatusValue2.WAITING,
|
|
62567
|
+
StepExecutionStatusValue2.SKIPPED
|
|
62568
|
+
]);
|
|
62569
|
+
TriggerTypeValue2 = {
|
|
62570
|
+
MANUAL: "manual",
|
|
62571
|
+
API: "api",
|
|
62572
|
+
WEBHOOK: "webhook",
|
|
62573
|
+
SCHEDULE: "schedule",
|
|
62574
|
+
EMAIL: "email",
|
|
62575
|
+
EVAL: "eval",
|
|
62576
|
+
CLI: "cli"
|
|
62577
|
+
};
|
|
62578
|
+
TriggerTypeSchema2 = exports_external.enum([
|
|
62579
|
+
TriggerTypeValue2.MANUAL,
|
|
62580
|
+
TriggerTypeValue2.API,
|
|
62581
|
+
TriggerTypeValue2.WEBHOOK,
|
|
62582
|
+
TriggerTypeValue2.SCHEDULE,
|
|
62583
|
+
TriggerTypeValue2.EMAIL,
|
|
62584
|
+
TriggerTypeValue2.EVAL,
|
|
62585
|
+
TriggerTypeValue2.CLI
|
|
62586
|
+
]);
|
|
62587
|
+
ExecutionTypeValue2 = {
|
|
62588
|
+
PROD: "prod",
|
|
62589
|
+
EVAL: "eval",
|
|
62590
|
+
PLAYGROUND: "playground"
|
|
62591
|
+
};
|
|
62592
|
+
ExecutionTypeSchema2 = exports_external.enum([
|
|
62593
|
+
ExecutionTypeValue2.PROD,
|
|
62594
|
+
ExecutionTypeValue2.EVAL,
|
|
62595
|
+
ExecutionTypeValue2.PLAYGROUND
|
|
62596
|
+
]);
|
|
62597
|
+
WORKFLOW_EXECUTION_STATUSES2 = asTuple(WorkflowExecutionStatusSchema2.options);
|
|
62598
|
+
STEP_EXECUTION_STATUSES2 = asTuple(StepExecutionStatusSchema2.options);
|
|
62599
|
+
TRIGGER_TYPES2 = TriggerTypeSchema2.options;
|
|
62600
|
+
EXECUTION_TYPES2 = ExecutionTypeSchema2.options;
|
|
62601
|
+
});
|
|
62602
|
+
|
|
64974
62603
|
// ../types/src/workflow/workflow.ts
|
|
64975
62604
|
function suggestWorkflowName(raw) {
|
|
64976
62605
|
return raw.toLowerCase().replace(/[^a-z0-9_-]+/g, "-").replace(/^[_-]+|[_-]+$/g, "").slice(0, 64);
|
|
@@ -65006,11 +62635,11 @@ var init_workflow = __esm(() => {
|
|
|
65006
62635
|
});
|
|
65007
62636
|
ManualTriggerMethodSchema = exports_external.object({
|
|
65008
62637
|
type: exports_external.literal("manual"),
|
|
65009
|
-
inputSchema:
|
|
62638
|
+
inputSchema: JsonSchemaSchema2.optional()
|
|
65010
62639
|
});
|
|
65011
62640
|
ApiTriggerMethodSchema = exports_external.object({
|
|
65012
62641
|
type: exports_external.literal("api"),
|
|
65013
|
-
inputSchema:
|
|
62642
|
+
inputSchema: JsonSchemaSchema2.optional()
|
|
65014
62643
|
});
|
|
65015
62644
|
EmailTriggerMethodSchema = exports_external.object({
|
|
65016
62645
|
type: exports_external.literal("email"),
|
|
@@ -65049,8 +62678,8 @@ var init_workflow = __esm(() => {
|
|
|
65049
62678
|
yamlContent: exports_external.string(),
|
|
65050
62679
|
definition: WorkflowDefinitionSchema,
|
|
65051
62680
|
isCurrent: exports_external.boolean().default(true),
|
|
65052
|
-
createdAt:
|
|
65053
|
-
updatedAt:
|
|
62681
|
+
createdAt: TimestampSchema2,
|
|
62682
|
+
updatedAt: TimestampSchema2.optional(),
|
|
65054
62683
|
createdBy: exports_external.string()
|
|
65055
62684
|
});
|
|
65056
62685
|
CreateWorkflowDefinitionSchema = exports_external.object({
|
|
@@ -65232,14 +62861,14 @@ function isFileOutput(value) {
|
|
|
65232
62861
|
function isWorkflowResult(value) {
|
|
65233
62862
|
return value != null && typeof value === "object" && "files" in value && Array.isArray(value.files);
|
|
65234
62863
|
}
|
|
65235
|
-
var
|
|
62864
|
+
var WorkflowExecutionStatusSchema3, StepExecutionStatusSchema3, ScopeEntryTypeSchema, ScopeEntrySchema, ScopeStackSchema, StepResultSchema, ExecutionContextSchema, StepInputReferenceSchema, WorkflowExecutionSchema, StepExecutionSchema, ConnectorSchema, WorkflowFileOutputSchema, WorkflowResultSchema;
|
|
65236
62865
|
var init_execution2 = __esm(() => {
|
|
65237
62866
|
init_zod();
|
|
65238
62867
|
init_common();
|
|
65239
62868
|
init_execution();
|
|
65240
62869
|
init_workflow();
|
|
65241
|
-
|
|
65242
|
-
|
|
62870
|
+
WorkflowExecutionStatusSchema3 = WorkflowExecutionStatusSchema2;
|
|
62871
|
+
StepExecutionStatusSchema3 = StepExecutionStatusSchema2;
|
|
65243
62872
|
ScopeEntryTypeSchema = exports_external.enum([
|
|
65244
62873
|
"root",
|
|
65245
62874
|
"if-then",
|
|
@@ -65261,7 +62890,7 @@ var init_execution2 = __esm(() => {
|
|
|
65261
62890
|
ScopeStackSchema = exports_external.array(ScopeEntrySchema);
|
|
65262
62891
|
StepResultSchema = exports_external.object({
|
|
65263
62892
|
output: exports_external.unknown(),
|
|
65264
|
-
status:
|
|
62893
|
+
status: StepExecutionStatusSchema3
|
|
65265
62894
|
});
|
|
65266
62895
|
ExecutionContextSchema = exports_external.object({
|
|
65267
62896
|
input: exports_external.record(exports_external.string(), exports_external.unknown()),
|
|
@@ -65289,7 +62918,7 @@ var init_execution2 = __esm(() => {
|
|
|
65289
62918
|
triggerType: exports_external.string(),
|
|
65290
62919
|
triggerInput: exports_external.record(exports_external.string(), exports_external.unknown()).nullable(),
|
|
65291
62920
|
overrides: exports_external.object({ steps: exports_external.record(exports_external.string(), exports_external.record(exports_external.string(), exports_external.unknown())).optional() }).nullable().optional(),
|
|
65292
|
-
status:
|
|
62921
|
+
status: WorkflowExecutionStatusSchema3,
|
|
65293
62922
|
scopeStack: ScopeStackSchema,
|
|
65294
62923
|
currentStepIndex: exports_external.number(),
|
|
65295
62924
|
stepResults: exports_external.record(exports_external.string(), StepResultSchema).optional(),
|
|
@@ -65297,15 +62926,15 @@ var init_execution2 = __esm(() => {
|
|
|
65297
62926
|
error: exports_external.string().nullable(),
|
|
65298
62927
|
priority: exports_external.number().default(50),
|
|
65299
62928
|
leaseId: exports_external.string().nullable(),
|
|
65300
|
-
leaseExpiresAt:
|
|
62929
|
+
leaseExpiresAt: TimestampSchema2.nullable(),
|
|
65301
62930
|
workerId: exports_external.string().nullable(),
|
|
65302
62931
|
maxRetries: exports_external.number().default(0),
|
|
65303
62932
|
originalExecutionId: exports_external.string().nullable().optional(),
|
|
65304
62933
|
previousExecutionId: exports_external.string().nullable().optional(),
|
|
65305
62934
|
retryNumber: exports_external.number().default(0),
|
|
65306
|
-
createdAt:
|
|
65307
|
-
startedAt:
|
|
65308
|
-
completedAt:
|
|
62935
|
+
createdAt: TimestampSchema2,
|
|
62936
|
+
startedAt: TimestampSchema2.nullable(),
|
|
62937
|
+
completedAt: TimestampSchema2.nullable(),
|
|
65309
62938
|
createdBy: exports_external.string().nullable()
|
|
65310
62939
|
});
|
|
65311
62940
|
StepExecutionSchema = exports_external.object({
|
|
@@ -65322,12 +62951,12 @@ var init_execution2 = __esm(() => {
|
|
|
65322
62951
|
stepAttempt: exports_external.number().default(0),
|
|
65323
62952
|
inputData: exports_external.unknown().nullable(),
|
|
65324
62953
|
outputData: exports_external.unknown().nullable(),
|
|
65325
|
-
status:
|
|
62954
|
+
status: StepExecutionStatusSchema3,
|
|
65326
62955
|
error: exports_external.string().nullable(),
|
|
65327
62956
|
overrideMode: exports_external.enum(["skipped", "partial"]).nullable().optional(),
|
|
65328
62957
|
durationMs: exports_external.number().nullable(),
|
|
65329
|
-
startedAt:
|
|
65330
|
-
completedAt:
|
|
62958
|
+
startedAt: TimestampSchema2.nullable(),
|
|
62959
|
+
completedAt: TimestampSchema2.nullable()
|
|
65331
62960
|
});
|
|
65332
62961
|
ConnectorSchema = exports_external.object({
|
|
65333
62962
|
id: exports_external.string(),
|
|
@@ -65338,8 +62967,8 @@ var init_execution2 = __esm(() => {
|
|
|
65338
62967
|
config: exports_external.record(exports_external.string(), exports_external.unknown()),
|
|
65339
62968
|
inputSchema: exports_external.unknown().optional(),
|
|
65340
62969
|
outputSchema: exports_external.unknown().optional(),
|
|
65341
|
-
createdAt:
|
|
65342
|
-
updatedAt:
|
|
62970
|
+
createdAt: TimestampSchema2,
|
|
62971
|
+
updatedAt: TimestampSchema2.optional(),
|
|
65343
62972
|
createdBy: exports_external.string()
|
|
65344
62973
|
});
|
|
65345
62974
|
WorkflowFileOutputSchema = exports_external.object({
|
|
@@ -66894,11 +64523,11 @@ function walkGrammar(node, parts) {
|
|
|
66894
64523
|
}
|
|
66895
64524
|
return current;
|
|
66896
64525
|
}
|
|
66897
|
-
function normalizeTemplate(
|
|
66898
|
-
return
|
|
64526
|
+
function normalizeTemplate(template) {
|
|
64527
|
+
return template.endsWith("/") ? template.slice(0, -1) : template;
|
|
66899
64528
|
}
|
|
66900
|
-
function renderTemplate(
|
|
66901
|
-
return normalizeTemplate(
|
|
64529
|
+
function renderTemplate(template, params) {
|
|
64530
|
+
return normalizeTemplate(template).split("/").flatMap((part) => {
|
|
66902
64531
|
if (!part.startsWith(":")) {
|
|
66903
64532
|
return [part];
|
|
66904
64533
|
}
|
|
@@ -66913,15 +64542,15 @@ function renderTemplate(template2, params) {
|
|
|
66913
64542
|
return [assertSegment(String(name), value)];
|
|
66914
64543
|
});
|
|
66915
64544
|
}
|
|
66916
|
-
function buildS3Path(tenantId,
|
|
64545
|
+
function buildS3Path(tenantId, template, params) {
|
|
66917
64546
|
const tenant = assertSegment("tenantId", tenantId);
|
|
66918
|
-
const parts = renderTemplate(
|
|
64547
|
+
const parts = renderTemplate(template, params);
|
|
66919
64548
|
const node = walkGrammar(S3_PATH_GRAMMAR, parts);
|
|
66920
|
-
if (
|
|
66921
|
-
throw new Error(`S3 path leaf cannot have a trailing slash: ${JSON.stringify(
|
|
64549
|
+
if (template.endsWith("/") && node === PATH_LEAF) {
|
|
64550
|
+
throw new Error(`S3 path leaf cannot have a trailing slash: ${JSON.stringify(template)}`);
|
|
66922
64551
|
}
|
|
66923
64552
|
const path = ["tenants", tenant, ...parts].join("/");
|
|
66924
|
-
return
|
|
64553
|
+
return template.endsWith("/") ? `${path}/` : path;
|
|
66925
64554
|
}
|
|
66926
64555
|
function createBuilder(grammarNode, prefixSegments, boundTenantId) {
|
|
66927
64556
|
const resolveTenantId = (params) => {
|
|
@@ -66931,23 +64560,23 @@ function createBuilder(grammarNode, prefixSegments, boundTenantId) {
|
|
|
66931
64560
|
}
|
|
66932
64561
|
return assertSegment("tenantId", tenantId);
|
|
66933
64562
|
};
|
|
66934
|
-
const build = (
|
|
64563
|
+
const build = (template, params) => {
|
|
66935
64564
|
const tenant = resolveTenantId(params);
|
|
66936
|
-
const parts = renderTemplate(
|
|
64565
|
+
const parts = renderTemplate(template, params ?? {});
|
|
66937
64566
|
const node = walkGrammar(grammarNode, parts);
|
|
66938
|
-
if (
|
|
66939
|
-
throw new Error(`S3 path leaf cannot have a trailing slash: ${JSON.stringify(
|
|
64567
|
+
if (template.endsWith("/") && node === PATH_LEAF) {
|
|
64568
|
+
throw new Error(`S3 path leaf cannot have a trailing slash: ${JSON.stringify(template)}`);
|
|
66940
64569
|
}
|
|
66941
64570
|
const path = ["tenants", tenant, ...prefixSegments, ...parts].join("/");
|
|
66942
|
-
return
|
|
64571
|
+
return template.endsWith("/") ? `${path}/` : path;
|
|
66943
64572
|
};
|
|
66944
64573
|
const builder = build;
|
|
66945
|
-
builder.at = (
|
|
64574
|
+
builder.at = (template, params) => {
|
|
66946
64575
|
const tenant = resolveTenantId(params);
|
|
66947
|
-
const parts = renderTemplate(
|
|
64576
|
+
const parts = renderTemplate(template, params ?? {});
|
|
66948
64577
|
const nextNode = walkGrammar(grammarNode, parts);
|
|
66949
|
-
if (
|
|
66950
|
-
throw new Error(`S3 path leaf cannot have a trailing slash: ${JSON.stringify(
|
|
64578
|
+
if (template.endsWith("/") && nextNode === PATH_LEAF) {
|
|
64579
|
+
throw new Error(`S3 path leaf cannot have a trailing slash: ${JSON.stringify(template)}`);
|
|
66951
64580
|
}
|
|
66952
64581
|
return createBuilder(nextNode, [...prefixSegments, ...parts], tenant);
|
|
66953
64582
|
};
|
|
@@ -67248,7 +64877,7 @@ __export(exports_src, {
|
|
|
67248
64877
|
SplitConfigSchema: () => SplitConfigSchema,
|
|
67249
64878
|
SpanTypes: () => SpanTypes,
|
|
67250
64879
|
SpanKindMap: () => SpanKindMap,
|
|
67251
|
-
SpanKind: () =>
|
|
64880
|
+
SpanKind: () => SpanKind,
|
|
67252
64881
|
SourceVersionRefSchema: () => SourceVersionRefSchema,
|
|
67253
64882
|
SourceSecretsFileSchema: () => SourceSecretsFileSchema,
|
|
67254
64883
|
SourcePackageTypeSchema: () => SourcePackageTypeSchema,
|
|
@@ -67450,8 +65079,8 @@ __export(exports_src, {
|
|
|
67450
65079
|
});
|
|
67451
65080
|
var init_src = __esm(() => {
|
|
67452
65081
|
init_core3();
|
|
67453
|
-
|
|
67454
|
-
|
|
65082
|
+
init_processor();
|
|
65083
|
+
init_parser();
|
|
67455
65084
|
init_otel();
|
|
67456
65085
|
init_execution_row();
|
|
67457
65086
|
init_run_expand();
|
|
@@ -68363,7 +65992,7 @@ var require_foldFlowLines = __commonJS((exports) => {
|
|
|
68363
65992
|
else
|
|
68364
65993
|
end = lineWidth - indentAtStart;
|
|
68365
65994
|
}
|
|
68366
|
-
let
|
|
65995
|
+
let split = undefined;
|
|
68367
65996
|
let prev = undefined;
|
|
68368
65997
|
let overflow = false;
|
|
68369
65998
|
let i = -1;
|
|
@@ -68397,20 +66026,20 @@ var require_foldFlowLines = __commonJS((exports) => {
|
|
|
68397
66026
|
if (mode === FOLD_BLOCK)
|
|
68398
66027
|
i = consumeMoreIndentedLines(text, i, indent.length);
|
|
68399
66028
|
end = i + indent.length + endStep;
|
|
68400
|
-
|
|
66029
|
+
split = undefined;
|
|
68401
66030
|
} else {
|
|
68402
66031
|
if (ch === " " && prev && prev !== " " && prev !== `
|
|
68403
66032
|
` && prev !== "\t") {
|
|
68404
66033
|
const next = text[i + 1];
|
|
68405
66034
|
if (next && next !== " " && next !== `
|
|
68406
66035
|
` && next !== "\t")
|
|
68407
|
-
|
|
66036
|
+
split = i;
|
|
68408
66037
|
}
|
|
68409
66038
|
if (i >= end) {
|
|
68410
|
-
if (
|
|
68411
|
-
folds.push(
|
|
68412
|
-
end =
|
|
68413
|
-
|
|
66039
|
+
if (split) {
|
|
66040
|
+
folds.push(split);
|
|
66041
|
+
end = split + endStep;
|
|
66042
|
+
split = undefined;
|
|
68414
66043
|
} else if (mode === FOLD_QUOTED) {
|
|
68415
66044
|
while (prev === " " || prev === "\t") {
|
|
68416
66045
|
prev = ch;
|
|
@@ -68423,7 +66052,7 @@ var require_foldFlowLines = __commonJS((exports) => {
|
|
|
68423
66052
|
folds.push(j);
|
|
68424
66053
|
escapedFolds[j] = true;
|
|
68425
66054
|
end = j + endStep;
|
|
68426
|
-
|
|
66055
|
+
split = undefined;
|
|
68427
66056
|
} else {
|
|
68428
66057
|
overflow = true;
|
|
68429
66058
|
}
|
|
@@ -69057,7 +66686,7 @@ var require_merge = __commonJS((exports) => {
|
|
|
69057
66686
|
var identity = require_identity();
|
|
69058
66687
|
var Scalar = require_Scalar();
|
|
69059
66688
|
var MERGE_KEY = "<<";
|
|
69060
|
-
var
|
|
66689
|
+
var merge2 = {
|
|
69061
66690
|
identify: (value) => value === MERGE_KEY || typeof value === "symbol" && value.description === MERGE_KEY,
|
|
69062
66691
|
default: "key",
|
|
69063
66692
|
tag: "tag:yaml.org,2002:merge",
|
|
@@ -69067,7 +66696,7 @@ var require_merge = __commonJS((exports) => {
|
|
|
69067
66696
|
}),
|
|
69068
66697
|
stringify: () => MERGE_KEY
|
|
69069
66698
|
};
|
|
69070
|
-
var isMergeKey = (ctx, key) => (
|
|
66699
|
+
var isMergeKey = (ctx, key) => (merge2.identify(key) || identity.isScalar(key) && (!key.type || key.type === Scalar.Scalar.PLAIN) && merge2.identify(key.value)) && ctx?.doc.schema.tags.some((tag) => tag.tag === merge2.tag && tag.default);
|
|
69071
66700
|
function addMergeToJSMap(ctx, map2, value) {
|
|
69072
66701
|
const source = resolveAliasValue(ctx, value);
|
|
69073
66702
|
if (identity.isSeq(source))
|
|
@@ -69106,21 +66735,21 @@ var require_merge = __commonJS((exports) => {
|
|
|
69106
66735
|
}
|
|
69107
66736
|
exports.addMergeToJSMap = addMergeToJSMap;
|
|
69108
66737
|
exports.isMergeKey = isMergeKey;
|
|
69109
|
-
exports.merge =
|
|
66738
|
+
exports.merge = merge2;
|
|
69110
66739
|
});
|
|
69111
66740
|
|
|
69112
66741
|
// node_modules/yaml/dist/nodes/addPairToJSMap.js
|
|
69113
66742
|
var require_addPairToJSMap = __commonJS((exports) => {
|
|
69114
66743
|
var log = require_log();
|
|
69115
|
-
var
|
|
66744
|
+
var merge2 = require_merge();
|
|
69116
66745
|
var stringify = require_stringify();
|
|
69117
66746
|
var identity = require_identity();
|
|
69118
66747
|
var toJS = require_toJS();
|
|
69119
66748
|
function addPairToJSMap(ctx, map2, { key, value }) {
|
|
69120
66749
|
if (identity.isNode(key) && key.addToJSMap)
|
|
69121
66750
|
key.addToJSMap(ctx, map2, value);
|
|
69122
|
-
else if (
|
|
69123
|
-
|
|
66751
|
+
else if (merge2.isMergeKey(ctx, key))
|
|
66752
|
+
merge2.addMergeToJSMap(ctx, map2, value);
|
|
69124
66753
|
else {
|
|
69125
66754
|
const jsKey = toJS.toJS(key, "", ctx);
|
|
69126
66755
|
if (map2 instanceof Map) {
|
|
@@ -70396,7 +68025,7 @@ var require_schema3 = __commonJS((exports) => {
|
|
|
70396
68025
|
var bool = require_bool2();
|
|
70397
68026
|
var float = require_float2();
|
|
70398
68027
|
var int2 = require_int2();
|
|
70399
|
-
var
|
|
68028
|
+
var merge2 = require_merge();
|
|
70400
68029
|
var omap = require_omap();
|
|
70401
68030
|
var pairs = require_pairs();
|
|
70402
68031
|
var set2 = require_set();
|
|
@@ -70416,7 +68045,7 @@ var require_schema3 = __commonJS((exports) => {
|
|
|
70416
68045
|
float.floatExp,
|
|
70417
68046
|
float.float,
|
|
70418
68047
|
binary.binary,
|
|
70419
|
-
|
|
68048
|
+
merge2.merge,
|
|
70420
68049
|
omap.omap,
|
|
70421
68050
|
pairs.pairs,
|
|
70422
68051
|
set2.set,
|
|
@@ -70439,7 +68068,7 @@ var require_tags = __commonJS((exports) => {
|
|
|
70439
68068
|
var schema = require_schema();
|
|
70440
68069
|
var schema$1 = require_schema2();
|
|
70441
68070
|
var binary = require_binary();
|
|
70442
|
-
var
|
|
68071
|
+
var merge2 = require_merge();
|
|
70443
68072
|
var omap = require_omap();
|
|
70444
68073
|
var pairs = require_pairs();
|
|
70445
68074
|
var schema$2 = require_schema3();
|
|
@@ -70464,7 +68093,7 @@ var require_tags = __commonJS((exports) => {
|
|
|
70464
68093
|
intOct: int2.intOct,
|
|
70465
68094
|
intTime: timestamp.intTime,
|
|
70466
68095
|
map: map2.map,
|
|
70467
|
-
merge:
|
|
68096
|
+
merge: merge2.merge,
|
|
70468
68097
|
null: _null4.nullTag,
|
|
70469
68098
|
omap: omap.omap,
|
|
70470
68099
|
pairs: pairs.pairs,
|
|
@@ -70474,7 +68103,7 @@ var require_tags = __commonJS((exports) => {
|
|
|
70474
68103
|
};
|
|
70475
68104
|
var coreKnownTags = {
|
|
70476
68105
|
"tag:yaml.org,2002:binary": binary.binary,
|
|
70477
|
-
"tag:yaml.org,2002:merge":
|
|
68106
|
+
"tag:yaml.org,2002:merge": merge2.merge,
|
|
70478
68107
|
"tag:yaml.org,2002:omap": omap.omap,
|
|
70479
68108
|
"tag:yaml.org,2002:pairs": pairs.pairs,
|
|
70480
68109
|
"tag:yaml.org,2002:set": set2.set,
|
|
@@ -70483,7 +68112,7 @@ var require_tags = __commonJS((exports) => {
|
|
|
70483
68112
|
function getTags(customTags, schemaName, addMergeTag) {
|
|
70484
68113
|
const schemaTags = schemas3.get(schemaName);
|
|
70485
68114
|
if (schemaTags && !customTags) {
|
|
70486
|
-
return addMergeTag && !schemaTags.includes(
|
|
68115
|
+
return addMergeTag && !schemaTags.includes(merge2.merge) ? schemaTags.concat(merge2.merge) : schemaTags.slice();
|
|
70487
68116
|
}
|
|
70488
68117
|
let tags = schemaTags;
|
|
70489
68118
|
if (!tags) {
|
|
@@ -70501,7 +68130,7 @@ var require_tags = __commonJS((exports) => {
|
|
|
70501
68130
|
tags = customTags(tags.slice());
|
|
70502
68131
|
}
|
|
70503
68132
|
if (addMergeTag)
|
|
70504
|
-
tags = tags.concat(
|
|
68133
|
+
tags = tags.concat(merge2.merge);
|
|
70505
68134
|
return tags.reduce((tags2, tag) => {
|
|
70506
68135
|
const tagObj = typeof tag === "string" ? tagsByName[tag] : tag;
|
|
70507
68136
|
if (!tagObj) {
|
|
@@ -70528,11 +68157,11 @@ var require_Schema = __commonJS((exports) => {
|
|
|
70528
68157
|
var sortMapEntriesByKey = (a, b) => a.key < b.key ? -1 : a.key > b.key ? 1 : 0;
|
|
70529
68158
|
|
|
70530
68159
|
class Schema {
|
|
70531
|
-
constructor({ compat: compat2, customTags, merge:
|
|
68160
|
+
constructor({ compat: compat2, customTags, merge: merge2, resolveKnownTags, schema, sortMapEntries, toStringDefaults }) {
|
|
70532
68161
|
this.compat = Array.isArray(compat2) ? tags.getTags(compat2, "compat") : compat2 ? tags.getTags(null, compat2) : null;
|
|
70533
68162
|
this.name = typeof schema === "string" && schema || "core";
|
|
70534
68163
|
this.knownTags = resolveKnownTags ? tags.coreKnownTags : {};
|
|
70535
|
-
this.tags = tags.getTags(customTags, this.name,
|
|
68164
|
+
this.tags = tags.getTags(customTags, this.name, merge2);
|
|
70536
68165
|
this.toStringOptions = toStringDefaults ?? null;
|
|
70537
68166
|
Object.defineProperty(this, identity.MAP, { value: map2.map });
|
|
70538
68167
|
Object.defineProperty(this, identity.SCALAR, { value: string4.string });
|
|
@@ -71755,13 +69384,13 @@ var require_resolve_block_scalar = __commonJS((exports) => {
|
|
|
71755
69384
|
return { mode, indent, chomp, comment, length };
|
|
71756
69385
|
}
|
|
71757
69386
|
function splitLines(source) {
|
|
71758
|
-
const
|
|
71759
|
-
const first =
|
|
69387
|
+
const split = source.split(/\n( *)/);
|
|
69388
|
+
const first = split[0];
|
|
71760
69389
|
const m = first.match(/^( *)/);
|
|
71761
69390
|
const line0 = m?.[1] ? [m[1], first.slice(m[1].length)] : ["", first];
|
|
71762
69391
|
const lines = [line0];
|
|
71763
|
-
for (let i = 1;i <
|
|
71764
|
-
lines.push([
|
|
69392
|
+
for (let i = 1;i < split.length; i += 2)
|
|
69393
|
+
lines.push([split[i], split[i + 1]]);
|
|
71765
69394
|
return lines;
|
|
71766
69395
|
}
|
|
71767
69396
|
exports.resolveBlockScalar = resolveBlockScalar;
|
|
@@ -74775,7 +72404,7 @@ var init_main = __esm(() => {
|
|
|
74775
72404
|
});
|
|
74776
72405
|
|
|
74777
72406
|
// ../../node_modules/sisteransi/src/index.js
|
|
74778
|
-
var
|
|
72407
|
+
var require_src = __commonJS((exports, module) => {
|
|
74779
72408
|
var ESC2 = "\x1B";
|
|
74780
72409
|
var CSI2 = `${ESC2}[`;
|
|
74781
72410
|
var beep = "\x07";
|
|
@@ -75118,7 +72747,7 @@ var import_sisteransi, G, K, h, Y, k, A = (r) => ("columns" in r) && typeof r.co
|
|
|
75118
72747
|
}, Q, X, Z, et, it, rt, nt, ot, ut, at, ht;
|
|
75119
72748
|
var init_dist3 = __esm(() => {
|
|
75120
72749
|
init_main();
|
|
75121
|
-
import_sisteransi = __toESM(
|
|
72750
|
+
import_sisteransi = __toESM(require_src(), 1);
|
|
75122
72751
|
G = ["up", "down", "left", "right", "space", "enter", "cancel"];
|
|
75123
72752
|
K = ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"];
|
|
75124
72753
|
h = { actions: new Set(G), aliases: new Map([["k", "up"], ["j", "down"], ["h", "left"], ["l", "right"], ["\x03", "cancel"], ["escape", "cancel"]]), messages: { cancel: "Canceled", error: "Something went wrong" }, withGuide: true, date: { monthNames: [...K], messages: { required: "Please enter a valid date", invalidMonth: "There are only 12 months in a year", invalidDay: (r, t) => `There are only ${r} days in ${t}`, afterMin: (r) => `Date must be on or after ${r.toISOString().slice(0, 10)}`, beforeMax: (r) => `Date must be on or before ${r.toISOString().slice(0, 10)}` } } };
|
|
@@ -76461,7 +74090,7 @@ var init_dist4 = __esm(() => {
|
|
|
76461
74090
|
init_dist3();
|
|
76462
74091
|
init_main();
|
|
76463
74092
|
init_dist2();
|
|
76464
|
-
import_sisteransi2 = __toESM(
|
|
74093
|
+
import_sisteransi2 = __toESM(require_src(), 1);
|
|
76465
74094
|
tt2 = te();
|
|
76466
74095
|
_t = w2("◆", "*");
|
|
76467
74096
|
ot2 = w2("■", "x");
|
|
@@ -169953,7 +167582,7 @@ var require2, __filename2, __dirname2, __create2, __defProp3, __getOwnPropDesc,
|
|
|
169953
167582
|
__defProp3(to5, key2, { get: () => from[key2], enumerable: !(desc = __getOwnPropDesc(from, key2)) || desc.enumerable });
|
|
169954
167583
|
}
|
|
169955
167584
|
return to5;
|
|
169956
|
-
}, __toESM2 = (mod, isNodeMode, target) => (target = mod != null ? __create2(__getProtoOf2(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp3(target, "default", { value: mod, enumerable: true }) : target, mod)), require_array, require_errno, require_fs, require_path, require_is_extglob, require_is_glob, require_glob_parent,
|
|
167585
|
+
}, __toESM2 = (mod, isNodeMode, target) => (target = mod != null ? __create2(__getProtoOf2(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp3(target, "default", { value: mod, enumerable: true }) : target, mod)), require_array, require_errno, require_fs, require_path, require_is_extglob, require_is_glob, require_glob_parent, require_utils2, require_stringify2, require_is_number, require_to_regex_range, require_fill_range, require_compile2, require_expand, require_constants, require_parse, require_braces, require_constants2, require_utils22, require_scan, require_parse2, require_picomatch, require_picomatch2, require_micromatch, require_pattern2, require_merge2, require_stream, require_string2, require_utils3, require_tasks, require_async, require_sync, require_fs2, require_settings, require_out, require_queue_microtask, require_run_parallel, require_constants3, require_fs3, require_utils4, require_common, require_async2, require_sync2, require_fs4, require_settings2, require_out2, require_reusify, require_queue, require_common2, require_reader, require_async3, require_async4, require_stream2, require_sync3, require_sync4, require_settings3, require_out3, require_reader2, require_stream3, require_async5, require_matcher, require_partial, require_deep, require_entry, require_error2, require_entry2, require_provider, require_async6, require_stream4, require_sync5, require_sync6, require_settings4, require_out4, require_picocolors2, require_debug, require_constants4, require_re, require_parse_options, require_identifiers, require_semver, require_compare, require_gte, require_pseudomap, require_map2, require_yallist, require_lru_cache, require_sigmund, require_fnmatch, require_ini, require_package, require_src2, require_js_tokens, require_readlines, require_ignore, index_exports, Diff = class {
|
|
169957
167586
|
diff(oldStr, newStr, options8 = {}) {
|
|
169958
167587
|
let callback;
|
|
169959
167588
|
if (typeof options8 === "function") {
|
|
@@ -170975,7 +168604,7 @@ var init_prettier = __esm(() => {
|
|
|
170975
168604
|
};
|
|
170976
168605
|
}
|
|
170977
168606
|
});
|
|
170978
|
-
|
|
168607
|
+
require_utils2 = __commonJS2({
|
|
170979
168608
|
"node_modules/braces/lib/utils.js"(exports) {
|
|
170980
168609
|
exports.isInteger = (num) => {
|
|
170981
168610
|
if (typeof num === "number") {
|
|
@@ -171064,7 +168693,7 @@ var init_prettier = __esm(() => {
|
|
|
171064
168693
|
});
|
|
171065
168694
|
require_stringify2 = __commonJS2({
|
|
171066
168695
|
"node_modules/braces/lib/stringify.js"(exports, module) {
|
|
171067
|
-
var utils2 =
|
|
168696
|
+
var utils2 = require_utils2();
|
|
171068
168697
|
module.exports = (ast, options8 = {}) => {
|
|
171069
168698
|
const stringify2 = (node, parent = {}) => {
|
|
171070
168699
|
const invalidBlock = options8.escapeInvalid && utils2.isInvalidBrace(parent);
|
|
@@ -171518,7 +169147,7 @@ var init_prettier = __esm(() => {
|
|
|
171518
169147
|
require_compile2 = __commonJS2({
|
|
171519
169148
|
"node_modules/braces/lib/compile.js"(exports, module) {
|
|
171520
169149
|
var fill2 = require_fill_range();
|
|
171521
|
-
var utils2 =
|
|
169150
|
+
var utils2 = require_utils2();
|
|
171522
169151
|
var compile = (ast, options8 = {}) => {
|
|
171523
169152
|
const walk2 = (node, parent = {}) => {
|
|
171524
169153
|
const invalidBlock = utils2.isInvalidBrace(parent);
|
|
@@ -171568,7 +169197,7 @@ var init_prettier = __esm(() => {
|
|
|
171568
169197
|
"node_modules/braces/lib/expand.js"(exports, module) {
|
|
171569
169198
|
var fill2 = require_fill_range();
|
|
171570
169199
|
var stringify2 = require_stringify2();
|
|
171571
|
-
var utils2 =
|
|
169200
|
+
var utils2 = require_utils2();
|
|
171572
169201
|
var append = (queue = "", stash = "", enclose = false) => {
|
|
171573
169202
|
const result = [];
|
|
171574
169203
|
queue = [].concat(queue);
|
|
@@ -173767,8 +171396,8 @@ var init_prettier = __esm(() => {
|
|
|
173767
171396
|
var Stream = __require2("stream");
|
|
173768
171397
|
var PassThrough = Stream.PassThrough;
|
|
173769
171398
|
var slice = Array.prototype.slice;
|
|
173770
|
-
module.exports =
|
|
173771
|
-
function
|
|
171399
|
+
module.exports = merge2;
|
|
171400
|
+
function merge2() {
|
|
173772
171401
|
const streamsQueue = [];
|
|
173773
171402
|
const args = slice.call(arguments);
|
|
173774
171403
|
let merging = false;
|
|
@@ -173882,9 +171511,9 @@ var init_prettier = __esm(() => {
|
|
|
173882
171511
|
"node_modules/fast-glob/out/utils/stream.js"(exports) {
|
|
173883
171512
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
173884
171513
|
exports.merge = undefined;
|
|
173885
|
-
var
|
|
171514
|
+
var merge2 = require_merge2();
|
|
173886
171515
|
function merge3(streams) {
|
|
173887
|
-
const mergedStream =
|
|
171516
|
+
const mergedStream = merge2(streams);
|
|
173888
171517
|
streams.forEach((stream) => {
|
|
173889
171518
|
stream.once("error", (error52) => mergedStream.emit("error", error52));
|
|
173890
171519
|
});
|
|
@@ -173912,7 +171541,7 @@ var init_prettier = __esm(() => {
|
|
|
173912
171541
|
exports.isEmpty = isEmpty;
|
|
173913
171542
|
}
|
|
173914
171543
|
});
|
|
173915
|
-
|
|
171544
|
+
require_utils3 = __commonJS2({
|
|
173916
171545
|
"node_modules/fast-glob/out/utils/index.js"(exports) {
|
|
173917
171546
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
173918
171547
|
exports.string = exports.stream = exports.pattern = exports.path = exports.fs = exports.errno = exports.array = undefined;
|
|
@@ -173936,7 +171565,7 @@ var init_prettier = __esm(() => {
|
|
|
173936
171565
|
"node_modules/fast-glob/out/managers/tasks.js"(exports) {
|
|
173937
171566
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
173938
171567
|
exports.convertPatternGroupToTask = exports.convertPatternGroupsToTasks = exports.groupPatternsByBaseDirectory = exports.getNegativePatternsAsPositive = exports.getPositivePatterns = exports.convertPatternsToTasks = exports.generate = undefined;
|
|
173939
|
-
var utils2 =
|
|
171568
|
+
var utils2 = require_utils3();
|
|
173940
171569
|
function generate(input, settings) {
|
|
173941
171570
|
const patterns = processPatterns(input, settings);
|
|
173942
171571
|
const ignore = processPatterns(settings.ignore, settings);
|
|
@@ -174245,7 +171874,7 @@ var init_prettier = __esm(() => {
|
|
|
174245
171874
|
exports.createDirentFromStats = createDirentFromStats;
|
|
174246
171875
|
}
|
|
174247
171876
|
});
|
|
174248
|
-
|
|
171877
|
+
require_utils4 = __commonJS2({
|
|
174249
171878
|
"node_modules/@nodelib/fs.scandir/out/utils/index.js"(exports) {
|
|
174250
171879
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
174251
171880
|
exports.fs = undefined;
|
|
@@ -174273,7 +171902,7 @@ var init_prettier = __esm(() => {
|
|
|
174273
171902
|
var fsStat = require_out();
|
|
174274
171903
|
var rpl = require_run_parallel();
|
|
174275
171904
|
var constants_1 = require_constants3();
|
|
174276
|
-
var utils2 =
|
|
171905
|
+
var utils2 = require_utils4();
|
|
174277
171906
|
var common = require_common();
|
|
174278
171907
|
function read3(directory, settings, callback) {
|
|
174279
171908
|
if (!settings.stats && constants_1.IS_SUPPORT_READDIR_WITH_FILE_TYPES) {
|
|
@@ -174379,7 +172008,7 @@ var init_prettier = __esm(() => {
|
|
|
174379
172008
|
exports.readdir = exports.readdirWithFileTypes = exports.read = undefined;
|
|
174380
172009
|
var fsStat = require_out();
|
|
174381
172010
|
var constants_1 = require_constants3();
|
|
174382
|
-
var utils2 =
|
|
172011
|
+
var utils2 = require_utils4();
|
|
174383
172012
|
var common = require_common();
|
|
174384
172013
|
function read3(directory, settings) {
|
|
174385
172014
|
if (!settings.stats && constants_1.IS_SUPPORT_READDIR_WITH_FILE_TYPES) {
|
|
@@ -175159,7 +172788,7 @@ var init_prettier = __esm(() => {
|
|
|
175159
172788
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
175160
172789
|
var path15 = __require2("path");
|
|
175161
172790
|
var fsStat = require_out();
|
|
175162
|
-
var utils2 =
|
|
172791
|
+
var utils2 = require_utils3();
|
|
175163
172792
|
var Reader = class {
|
|
175164
172793
|
constructor(_settings) {
|
|
175165
172794
|
this._settings = _settings;
|
|
@@ -175283,7 +172912,7 @@ var init_prettier = __esm(() => {
|
|
|
175283
172912
|
require_matcher = __commonJS2({
|
|
175284
172913
|
"node_modules/fast-glob/out/providers/matchers/matcher.js"(exports) {
|
|
175285
172914
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
175286
|
-
var utils2 =
|
|
172915
|
+
var utils2 = require_utils3();
|
|
175287
172916
|
var Matcher = class {
|
|
175288
172917
|
constructor(_patterns, _settings, _micromatchOptions) {
|
|
175289
172918
|
this._patterns = _patterns;
|
|
@@ -175365,7 +172994,7 @@ var init_prettier = __esm(() => {
|
|
|
175365
172994
|
require_deep = __commonJS2({
|
|
175366
172995
|
"node_modules/fast-glob/out/providers/filters/deep.js"(exports) {
|
|
175367
172996
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
175368
|
-
var utils2 =
|
|
172997
|
+
var utils2 = require_utils3();
|
|
175369
172998
|
var partial_1 = require_partial();
|
|
175370
172999
|
var DeepFilter = class {
|
|
175371
173000
|
constructor(_settings, _micromatchOptions) {
|
|
@@ -175427,7 +173056,7 @@ var init_prettier = __esm(() => {
|
|
|
175427
173056
|
require_entry = __commonJS2({
|
|
175428
173057
|
"node_modules/fast-glob/out/providers/filters/entry.js"(exports) {
|
|
175429
173058
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
175430
|
-
var utils2 =
|
|
173059
|
+
var utils2 = require_utils3();
|
|
175431
173060
|
var EntryFilter = class {
|
|
175432
173061
|
constructor(_settings, _micromatchOptions) {
|
|
175433
173062
|
this._settings = _settings;
|
|
@@ -175512,7 +173141,7 @@ var init_prettier = __esm(() => {
|
|
|
175512
173141
|
require_error2 = __commonJS2({
|
|
175513
173142
|
"node_modules/fast-glob/out/providers/filters/error.js"(exports) {
|
|
175514
173143
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
175515
|
-
var utils2 =
|
|
173144
|
+
var utils2 = require_utils3();
|
|
175516
173145
|
var ErrorFilter = class {
|
|
175517
173146
|
constructor(_settings) {
|
|
175518
173147
|
this._settings = _settings;
|
|
@@ -175530,7 +173159,7 @@ var init_prettier = __esm(() => {
|
|
|
175530
173159
|
require_entry2 = __commonJS2({
|
|
175531
173160
|
"node_modules/fast-glob/out/providers/transformers/entry.js"(exports) {
|
|
175532
173161
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
175533
|
-
var utils2 =
|
|
173162
|
+
var utils2 = require_utils3();
|
|
175534
173163
|
var EntryTransformer = class {
|
|
175535
173164
|
constructor(_settings) {
|
|
175536
173165
|
this._settings = _settings;
|
|
@@ -175798,7 +173427,7 @@ var init_prettier = __esm(() => {
|
|
|
175798
173427
|
var stream_1 = require_stream4();
|
|
175799
173428
|
var sync_1 = require_sync6();
|
|
175800
173429
|
var settings_1 = require_settings4();
|
|
175801
|
-
var utils2 =
|
|
173430
|
+
var utils2 = require_utils3();
|
|
175802
173431
|
async function FastGlob(source2, options8) {
|
|
175803
173432
|
assertPatternsInput(source2);
|
|
175804
173433
|
const works = getWorks(source2, async_1.default, options8);
|
|
@@ -176116,7 +173745,7 @@ var init_prettier = __esm(() => {
|
|
|
176116
173745
|
};
|
|
176117
173746
|
}
|
|
176118
173747
|
});
|
|
176119
|
-
|
|
173748
|
+
require_semver = __commonJS2({
|
|
176120
173749
|
"node_modules/semver/classes/semver.js"(exports, module) {
|
|
176121
173750
|
var debug = require_debug();
|
|
176122
173751
|
var { MAX_LENGTH, MAX_SAFE_INTEGER } = require_constants4();
|
|
@@ -176386,7 +174015,7 @@ var init_prettier = __esm(() => {
|
|
|
176386
174015
|
});
|
|
176387
174016
|
require_compare = __commonJS2({
|
|
176388
174017
|
"node_modules/semver/functions/compare.js"(exports, module) {
|
|
176389
|
-
var SemVer =
|
|
174018
|
+
var SemVer = require_semver();
|
|
176390
174019
|
var compare = (a5, b8, loose) => new SemVer(a5, loose).compare(new SemVer(b8, loose));
|
|
176391
174020
|
module.exports = compare;
|
|
176392
174021
|
}
|
|
@@ -178119,7 +175748,7 @@ globstar while`, file2, fr10, pattern, pr8, swallowee);
|
|
|
178119
175748
|
};
|
|
178120
175749
|
}
|
|
178121
175750
|
});
|
|
178122
|
-
|
|
175751
|
+
require_src2 = __commonJS2({
|
|
178123
175752
|
"node_modules/editorconfig/src/index.js"(exports) {
|
|
178124
175753
|
var __awaiter = exports && exports.__awaiter || function(thisArg, _arguments, P9, generator) {
|
|
178125
175754
|
return new (P9 || (P9 = Promise))(function(resolve32, reject) {
|
|
@@ -179582,7 +177211,7 @@ globstar while`, file2, fr10, pattern, pr8, swallowee);
|
|
|
179582
177211
|
mockable_default = mockable.mocked;
|
|
179583
177212
|
import_micromatch = __toESM2(require_micromatch(), 1);
|
|
179584
177213
|
partition_default = partition2;
|
|
179585
|
-
import_editorconfig = __toESM2(
|
|
177214
|
+
import_editorconfig = __toESM2(require_src2(), 1);
|
|
179586
177215
|
iterate_directory_up_default = iterateDirectoryUp;
|
|
179587
177216
|
FileSearcher = class extends Searcher {
|
|
179588
177217
|
findInDirectory = findFile;
|
|
@@ -183053,7 +180682,7 @@ var require_foldFlowLines2 = __commonJS((exports) => {
|
|
|
183053
180682
|
else
|
|
183054
180683
|
end = lineWidth - indentAtStart;
|
|
183055
180684
|
}
|
|
183056
|
-
let
|
|
180685
|
+
let split = undefined;
|
|
183057
180686
|
let prev = undefined;
|
|
183058
180687
|
let overflow = false;
|
|
183059
180688
|
let i5 = -1;
|
|
@@ -183087,20 +180716,20 @@ var require_foldFlowLines2 = __commonJS((exports) => {
|
|
|
183087
180716
|
if (mode === FOLD_BLOCK)
|
|
183088
180717
|
i5 = consumeMoreIndentedLines(text, i5, indent3.length);
|
|
183089
180718
|
end = i5 + indent3.length + endStep;
|
|
183090
|
-
|
|
180719
|
+
split = undefined;
|
|
183091
180720
|
} else {
|
|
183092
180721
|
if (ch2 === " " && prev && prev !== " " && prev !== `
|
|
183093
180722
|
` && prev !== "\t") {
|
|
183094
180723
|
const next = text[i5 + 1];
|
|
183095
180724
|
if (next && next !== " " && next !== `
|
|
183096
180725
|
` && next !== "\t")
|
|
183097
|
-
|
|
180726
|
+
split = i5;
|
|
183098
180727
|
}
|
|
183099
180728
|
if (i5 >= end) {
|
|
183100
|
-
if (
|
|
183101
|
-
folds.push(
|
|
183102
|
-
end =
|
|
183103
|
-
|
|
180729
|
+
if (split) {
|
|
180730
|
+
folds.push(split);
|
|
180731
|
+
end = split + endStep;
|
|
180732
|
+
split = undefined;
|
|
183104
180733
|
} else if (mode === FOLD_QUOTED) {
|
|
183105
180734
|
while (prev === " " || prev === "\t") {
|
|
183106
180735
|
prev = ch2;
|
|
@@ -183113,7 +180742,7 @@ var require_foldFlowLines2 = __commonJS((exports) => {
|
|
|
183113
180742
|
folds.push(j11);
|
|
183114
180743
|
escapedFolds[j11] = true;
|
|
183115
180744
|
end = j11 + endStep;
|
|
183116
|
-
|
|
180745
|
+
split = undefined;
|
|
183117
180746
|
} else {
|
|
183118
180747
|
overflow = true;
|
|
183119
180748
|
}
|
|
@@ -183747,7 +181376,7 @@ var require_merge3 = __commonJS((exports) => {
|
|
|
183747
181376
|
var identity = require_identity2();
|
|
183748
181377
|
var Scalar = require_Scalar2();
|
|
183749
181378
|
var MERGE_KEY = "<<";
|
|
183750
|
-
var
|
|
181379
|
+
var merge2 = {
|
|
183751
181380
|
identify: (value) => value === MERGE_KEY || typeof value === "symbol" && value.description === MERGE_KEY,
|
|
183752
181381
|
default: "key",
|
|
183753
181382
|
tag: "tag:yaml.org,2002:merge",
|
|
@@ -183757,7 +181386,7 @@ var require_merge3 = __commonJS((exports) => {
|
|
|
183757
181386
|
}),
|
|
183758
181387
|
stringify: () => MERGE_KEY
|
|
183759
181388
|
};
|
|
183760
|
-
var isMergeKey = (ctx, key2) => (
|
|
181389
|
+
var isMergeKey = (ctx, key2) => (merge2.identify(key2) || identity.isScalar(key2) && (!key2.type || key2.type === Scalar.Scalar.PLAIN) && merge2.identify(key2.value)) && ctx?.doc.schema.tags.some((tag) => tag.tag === merge2.tag && tag.default);
|
|
183761
181390
|
function addMergeToJSMap(ctx, map2, value) {
|
|
183762
181391
|
const source2 = resolveAliasValue(ctx, value);
|
|
183763
181392
|
if (identity.isSeq(source2))
|
|
@@ -183796,21 +181425,21 @@ var require_merge3 = __commonJS((exports) => {
|
|
|
183796
181425
|
}
|
|
183797
181426
|
exports.addMergeToJSMap = addMergeToJSMap;
|
|
183798
181427
|
exports.isMergeKey = isMergeKey;
|
|
183799
|
-
exports.merge =
|
|
181428
|
+
exports.merge = merge2;
|
|
183800
181429
|
});
|
|
183801
181430
|
|
|
183802
181431
|
// ../workflow-yaml/node_modules/yaml/dist/nodes/addPairToJSMap.js
|
|
183803
181432
|
var require_addPairToJSMap2 = __commonJS((exports) => {
|
|
183804
181433
|
var log = require_log2();
|
|
183805
|
-
var
|
|
181434
|
+
var merge2 = require_merge3();
|
|
183806
181435
|
var stringify = require_stringify3();
|
|
183807
181436
|
var identity = require_identity2();
|
|
183808
181437
|
var toJS = require_toJS2();
|
|
183809
181438
|
function addPairToJSMap(ctx, map2, { key: key2, value }) {
|
|
183810
181439
|
if (identity.isNode(key2) && key2.addToJSMap)
|
|
183811
181440
|
key2.addToJSMap(ctx, map2, value);
|
|
183812
|
-
else if (
|
|
183813
|
-
|
|
181441
|
+
else if (merge2.isMergeKey(ctx, key2))
|
|
181442
|
+
merge2.addMergeToJSMap(ctx, map2, value);
|
|
183814
181443
|
else {
|
|
183815
181444
|
const jsKey = toJS.toJS(key2, "", ctx);
|
|
183816
181445
|
if (map2 instanceof Map) {
|
|
@@ -185086,7 +182715,7 @@ var require_schema6 = __commonJS((exports) => {
|
|
|
185086
182715
|
var bool = require_bool4();
|
|
185087
182716
|
var float = require_float4();
|
|
185088
182717
|
var int2 = require_int4();
|
|
185089
|
-
var
|
|
182718
|
+
var merge2 = require_merge3();
|
|
185090
182719
|
var omap = require_omap2();
|
|
185091
182720
|
var pairs = require_pairs2();
|
|
185092
182721
|
var set2 = require_set2();
|
|
@@ -185106,7 +182735,7 @@ var require_schema6 = __commonJS((exports) => {
|
|
|
185106
182735
|
float.floatExp,
|
|
185107
182736
|
float.float,
|
|
185108
182737
|
binary.binary,
|
|
185109
|
-
|
|
182738
|
+
merge2.merge,
|
|
185110
182739
|
omap.omap,
|
|
185111
182740
|
pairs.pairs,
|
|
185112
182741
|
set2.set,
|
|
@@ -185129,7 +182758,7 @@ var require_tags2 = __commonJS((exports) => {
|
|
|
185129
182758
|
var schema = require_schema4();
|
|
185130
182759
|
var schema$1 = require_schema5();
|
|
185131
182760
|
var binary = require_binary2();
|
|
185132
|
-
var
|
|
182761
|
+
var merge2 = require_merge3();
|
|
185133
182762
|
var omap = require_omap2();
|
|
185134
182763
|
var pairs = require_pairs2();
|
|
185135
182764
|
var schema$2 = require_schema6();
|
|
@@ -185154,7 +182783,7 @@ var require_tags2 = __commonJS((exports) => {
|
|
|
185154
182783
|
intOct: int2.intOct,
|
|
185155
182784
|
intTime: timestamp.intTime,
|
|
185156
182785
|
map: map2.map,
|
|
185157
|
-
merge:
|
|
182786
|
+
merge: merge2.merge,
|
|
185158
182787
|
null: _null4.nullTag,
|
|
185159
182788
|
omap: omap.omap,
|
|
185160
182789
|
pairs: pairs.pairs,
|
|
@@ -185164,7 +182793,7 @@ var require_tags2 = __commonJS((exports) => {
|
|
|
185164
182793
|
};
|
|
185165
182794
|
var coreKnownTags = {
|
|
185166
182795
|
"tag:yaml.org,2002:binary": binary.binary,
|
|
185167
|
-
"tag:yaml.org,2002:merge":
|
|
182796
|
+
"tag:yaml.org,2002:merge": merge2.merge,
|
|
185168
182797
|
"tag:yaml.org,2002:omap": omap.omap,
|
|
185169
182798
|
"tag:yaml.org,2002:pairs": pairs.pairs,
|
|
185170
182799
|
"tag:yaml.org,2002:set": set2.set,
|
|
@@ -185173,7 +182802,7 @@ var require_tags2 = __commonJS((exports) => {
|
|
|
185173
182802
|
function getTags(customTags, schemaName, addMergeTag) {
|
|
185174
182803
|
const schemaTags = schemas3.get(schemaName);
|
|
185175
182804
|
if (schemaTags && !customTags) {
|
|
185176
|
-
return addMergeTag && !schemaTags.includes(
|
|
182805
|
+
return addMergeTag && !schemaTags.includes(merge2.merge) ? schemaTags.concat(merge2.merge) : schemaTags.slice();
|
|
185177
182806
|
}
|
|
185178
182807
|
let tags = schemaTags;
|
|
185179
182808
|
if (!tags) {
|
|
@@ -185191,7 +182820,7 @@ var require_tags2 = __commonJS((exports) => {
|
|
|
185191
182820
|
tags = customTags(tags.slice());
|
|
185192
182821
|
}
|
|
185193
182822
|
if (addMergeTag)
|
|
185194
|
-
tags = tags.concat(
|
|
182823
|
+
tags = tags.concat(merge2.merge);
|
|
185195
182824
|
return tags.reduce((tags2, tag) => {
|
|
185196
182825
|
const tagObj = typeof tag === "string" ? tagsByName[tag] : tag;
|
|
185197
182826
|
if (!tagObj) {
|
|
@@ -185218,11 +182847,11 @@ var require_Schema2 = __commonJS((exports) => {
|
|
|
185218
182847
|
var sortMapEntriesByKey = (a5, b8) => a5.key < b8.key ? -1 : a5.key > b8.key ? 1 : 0;
|
|
185219
182848
|
|
|
185220
182849
|
class Schema2 {
|
|
185221
|
-
constructor({ compat: compat2, customTags, merge:
|
|
182850
|
+
constructor({ compat: compat2, customTags, merge: merge2, resolveKnownTags, schema, sortMapEntries, toStringDefaults }) {
|
|
185222
182851
|
this.compat = Array.isArray(compat2) ? tags.getTags(compat2, "compat") : compat2 ? tags.getTags(null, compat2) : null;
|
|
185223
182852
|
this.name = typeof schema === "string" && schema || "core";
|
|
185224
182853
|
this.knownTags = resolveKnownTags ? tags.coreKnownTags : {};
|
|
185225
|
-
this.tags = tags.getTags(customTags, this.name,
|
|
182854
|
+
this.tags = tags.getTags(customTags, this.name, merge2);
|
|
185226
182855
|
this.toStringOptions = toStringDefaults ?? null;
|
|
185227
182856
|
Object.defineProperty(this, identity.MAP, { value: map2.map });
|
|
185228
182857
|
Object.defineProperty(this, identity.SCALAR, { value: string4.string });
|
|
@@ -186445,13 +184074,13 @@ var require_resolve_block_scalar2 = __commonJS((exports) => {
|
|
|
186445
184074
|
return { mode, indent: indent3, chomp, comment, length };
|
|
186446
184075
|
}
|
|
186447
184076
|
function splitLines2(source2) {
|
|
186448
|
-
const
|
|
186449
|
-
const first =
|
|
184077
|
+
const split = source2.split(/\n( *)/);
|
|
184078
|
+
const first = split[0];
|
|
186450
184079
|
const m7 = first.match(/^( *)/);
|
|
186451
184080
|
const line0 = m7?.[1] ? [m7[1], first.slice(m7[1].length)] : ["", first];
|
|
186452
184081
|
const lines = [line0];
|
|
186453
|
-
for (let i5 = 1;i5 <
|
|
186454
|
-
lines.push([
|
|
184082
|
+
for (let i5 = 1;i5 < split.length; i5 += 2)
|
|
184083
|
+
lines.push([split[i5], split[i5 + 1]]);
|
|
186455
184084
|
return lines;
|
|
186456
184085
|
}
|
|
186457
184086
|
exports.resolveBlockScalar = resolveBlockScalar;
|
|
@@ -189099,7 +186728,7 @@ import { fileURLToPath as fileURLToPath8 } from "url";
|
|
|
189099
186728
|
// package.json
|
|
189100
186729
|
var package_default = {
|
|
189101
186730
|
name: "@eigenpal/cli",
|
|
189102
|
-
version: "0.7.
|
|
186731
|
+
version: "0.7.2",
|
|
189103
186732
|
description: "Eigenpal CLI — author and run document workflows from your terminal. Agent-ready.",
|
|
189104
186733
|
keywords: [
|
|
189105
186734
|
"eigenpal",
|
|
@@ -190598,7 +188227,7 @@ async function pushCurrentBranch(input) {
|
|
|
190598
188227
|
function slugifyPackageSegment(value) {
|
|
190599
188228
|
return value.trim().toLowerCase().replace(/[^a-z0-9_-]+/g, "-").replace(/^-+|-+$/g, "");
|
|
190600
188229
|
}
|
|
190601
|
-
function packagePathForTemplate(
|
|
188230
|
+
function packagePathForTemplate(template, name) {
|
|
190602
188231
|
const slug = slugifyPackageSegment(name);
|
|
190603
188232
|
if (!slug)
|
|
190604
188233
|
throw new Error("Package name must include at least one letter or number.");
|
|
@@ -190610,7 +188239,7 @@ function packagePathForTemplate(template2, name) {
|
|
|
190610
188239
|
knowledge: "resources/knowledge",
|
|
190611
188240
|
evaluator: "evaluators"
|
|
190612
188241
|
};
|
|
190613
|
-
const root = rootByTemplate[
|
|
188242
|
+
const root = rootByTemplate[template];
|
|
190614
188243
|
if (!root)
|
|
190615
188244
|
throw new Error("Template must be agent, workflow, skill, rule, knowledge, or evaluator.");
|
|
190616
188245
|
return SourcePackagePathSchema.parse(`${root}/${slug}`);
|
|
@@ -191019,12 +188648,12 @@ function archivePackage(input) {
|
|
|
191019
188648
|
runGit(["archive", "--format=tar", `--output=${tarPath}`, input.ref, input.packagePath], {
|
|
191020
188649
|
cwd: input.gitRoot
|
|
191021
188650
|
});
|
|
191022
|
-
const
|
|
188651
|
+
const extract = spawnSync3("tar", ["-xf", tarPath, "--strip-components", String(input.packagePath.split("/").length)], {
|
|
191023
188652
|
cwd: input.outDir,
|
|
191024
188653
|
encoding: "utf8"
|
|
191025
188654
|
});
|
|
191026
|
-
if (
|
|
191027
|
-
throw new Error(
|
|
188655
|
+
if (extract.status !== 0)
|
|
188656
|
+
throw new Error(extract.stderr.trim() || "tar extraction failed");
|
|
191028
188657
|
} finally {
|
|
191029
188658
|
rmSync(path5.dirname(tarPath), { recursive: true, force: true });
|
|
191030
188659
|
}
|
|
@@ -191053,12 +188682,12 @@ async function tryHostedArchive(input) {
|
|
|
191053
188682
|
const tarPath = path5.join(mkdtempSyncCompat("eigenpal-hosted-source-"), "package.tar");
|
|
191054
188683
|
try {
|
|
191055
188684
|
writeFileSync4(tarPath, Buffer.from(await response.arrayBuffer()));
|
|
191056
|
-
const
|
|
188685
|
+
const extract = spawnSync3("tar", ["-xf", tarPath, "--strip-components", String(input.packagePath.split("/").length)], {
|
|
191057
188686
|
cwd: input.outDir,
|
|
191058
188687
|
encoding: "utf8"
|
|
191059
188688
|
});
|
|
191060
|
-
if (
|
|
191061
|
-
throw new Error(
|
|
188689
|
+
if (extract.status !== 0)
|
|
188690
|
+
throw new Error(extract.stderr.trim() || "tar extraction failed");
|
|
191062
188691
|
return true;
|
|
191063
188692
|
} finally {
|
|
191064
188693
|
rmSync(path5.dirname(tarPath), { recursive: true, force: true });
|
|
@@ -194400,18 +192029,18 @@ async function init(name, opts) {
|
|
|
194400
192029
|
if (existsSync10(target) && readdirSync2(target).length > 0) {
|
|
194401
192030
|
throw new Error(`Target directory ${relative(process.cwd(), target)} exists and is not empty.`);
|
|
194402
192031
|
}
|
|
194403
|
-
let
|
|
192032
|
+
let template;
|
|
194404
192033
|
if (opts.template) {
|
|
194405
192034
|
if (!isTemplateName(opts.template)) {
|
|
194406
192035
|
throw new Error(`Unknown template "${opts.template}". Available: ${TEMPLATE_NAMES.join(", ")}.`);
|
|
194407
192036
|
}
|
|
194408
|
-
|
|
192037
|
+
template = opts.template;
|
|
194409
192038
|
} else if (opts.yes || !process.stdin.isTTY) {
|
|
194410
|
-
|
|
192039
|
+
template = "blank";
|
|
194411
192040
|
} else {
|
|
194412
|
-
|
|
192041
|
+
template = await promptForTemplate();
|
|
194413
192042
|
}
|
|
194414
|
-
const sourceRoot = join2(resolveTemplatesRoot(),
|
|
192043
|
+
const sourceRoot = join2(resolveTemplatesRoot(), template);
|
|
194415
192044
|
if (!existsSync10(sourceRoot)) {
|
|
194416
192045
|
throw new Error(`Template directory missing on disk: ${sourceRoot}`);
|
|
194417
192046
|
}
|