@uipath/api-workflow-tool 1.197.0-preview.65 → 1.197.0-preview.67
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/tool.js +1722 -42
- package/package.json +2 -2
package/dist/tool.js
CHANGED
|
@@ -25206,6 +25206,177 @@ function getOutputFormat2() {
|
|
|
25206
25206
|
function getOutputFilter2() {
|
|
25207
25207
|
return filterSlot2.get();
|
|
25208
25208
|
}
|
|
25209
|
+
function isRecord2(value) {
|
|
25210
|
+
return value !== null && typeof value === "object";
|
|
25211
|
+
}
|
|
25212
|
+
function stringField2(value, field) {
|
|
25213
|
+
if (!isRecord2(value)) {
|
|
25214
|
+
return;
|
|
25215
|
+
}
|
|
25216
|
+
const raw = value[field];
|
|
25217
|
+
return typeof raw === "string" ? raw : undefined;
|
|
25218
|
+
}
|
|
25219
|
+
function numberField2(value, field) {
|
|
25220
|
+
if (!isRecord2(value)) {
|
|
25221
|
+
return;
|
|
25222
|
+
}
|
|
25223
|
+
const raw = value[field];
|
|
25224
|
+
return typeof raw === "number" ? raw : undefined;
|
|
25225
|
+
}
|
|
25226
|
+
function findStringInCauseChain2(error, field) {
|
|
25227
|
+
let current = error;
|
|
25228
|
+
for (let depth = 0;depth < 5 && current !== null && typeof current === "object"; depth++) {
|
|
25229
|
+
const value = stringField2(current, field);
|
|
25230
|
+
if (value) {
|
|
25231
|
+
return value;
|
|
25232
|
+
}
|
|
25233
|
+
current = current.cause;
|
|
25234
|
+
}
|
|
25235
|
+
return;
|
|
25236
|
+
}
|
|
25237
|
+
function findCodeInCauseChain2(error) {
|
|
25238
|
+
return findStringInCauseChain2(error, "code");
|
|
25239
|
+
}
|
|
25240
|
+
function isSpawnEnoent2(error) {
|
|
25241
|
+
const code = findCodeInCauseChain2(error);
|
|
25242
|
+
if (code !== "ENOENT") {
|
|
25243
|
+
return false;
|
|
25244
|
+
}
|
|
25245
|
+
const syscall = findStringInCauseChain2(error, "syscall");
|
|
25246
|
+
return syscall?.startsWith("spawn") === true;
|
|
25247
|
+
}
|
|
25248
|
+
function isCancellationError2(error, exitCode, pollSignal) {
|
|
25249
|
+
if (exitCode === 130) {
|
|
25250
|
+
return true;
|
|
25251
|
+
}
|
|
25252
|
+
if (!isRecord2(error)) {
|
|
25253
|
+
return false;
|
|
25254
|
+
}
|
|
25255
|
+
if (numberField2(error, "exitCode") === 130) {
|
|
25256
|
+
return true;
|
|
25257
|
+
}
|
|
25258
|
+
const name = stringField2(error, "name");
|
|
25259
|
+
if (name === "ExitPromptError") {
|
|
25260
|
+
return true;
|
|
25261
|
+
}
|
|
25262
|
+
if (name === "AbortError" && pollSignal?.aborted) {
|
|
25263
|
+
return true;
|
|
25264
|
+
}
|
|
25265
|
+
const message = stringField2(error, "message");
|
|
25266
|
+
return message?.includes("SIGINT") === true;
|
|
25267
|
+
}
|
|
25268
|
+
function terminalSignalFor2(input, outcome) {
|
|
25269
|
+
if (input.recordedFailure?.terminalSignal) {
|
|
25270
|
+
return input.recordedFailure.terminalSignal;
|
|
25271
|
+
}
|
|
25272
|
+
const explicit = findStringInCauseChain2(input.error, "terminalSignal") ?? findStringInCauseChain2(input.error, "signal");
|
|
25273
|
+
if (explicit) {
|
|
25274
|
+
return explicit;
|
|
25275
|
+
}
|
|
25276
|
+
return outcome === "cancelled" ? "SIGINT" : undefined;
|
|
25277
|
+
}
|
|
25278
|
+
function classifyHttpStatus2(status) {
|
|
25279
|
+
if (status === 401 || status === 403) {
|
|
25280
|
+
return "auth";
|
|
25281
|
+
}
|
|
25282
|
+
if (status === 400 || status === 409 || status === 422) {
|
|
25283
|
+
return "validation";
|
|
25284
|
+
}
|
|
25285
|
+
if (status === 408) {
|
|
25286
|
+
return "timeout";
|
|
25287
|
+
}
|
|
25288
|
+
return "network_http";
|
|
25289
|
+
}
|
|
25290
|
+
function classifyFromResult2(result) {
|
|
25291
|
+
switch (result) {
|
|
25292
|
+
case "AuthenticationError":
|
|
25293
|
+
return "auth";
|
|
25294
|
+
case "ValidationError":
|
|
25295
|
+
return "validation";
|
|
25296
|
+
case "TimeoutError":
|
|
25297
|
+
return "timeout";
|
|
25298
|
+
default:
|
|
25299
|
+
return;
|
|
25300
|
+
}
|
|
25301
|
+
}
|
|
25302
|
+
function classifyFromErrorCode2(errorCode2) {
|
|
25303
|
+
if (!errorCode2) {
|
|
25304
|
+
return;
|
|
25305
|
+
}
|
|
25306
|
+
if (AUTH_ERROR_CODES2.has(errorCode2)) {
|
|
25307
|
+
return "auth";
|
|
25308
|
+
}
|
|
25309
|
+
if (VALIDATION_ERROR_CODES2.has(errorCode2)) {
|
|
25310
|
+
return "validation";
|
|
25311
|
+
}
|
|
25312
|
+
if (TIMEOUT_ERROR_CODES2.has(errorCode2)) {
|
|
25313
|
+
return "timeout";
|
|
25314
|
+
}
|
|
25315
|
+
if (NETWORK_HTTP_ERROR_CODES2.has(errorCode2)) {
|
|
25316
|
+
return "network_http";
|
|
25317
|
+
}
|
|
25318
|
+
return;
|
|
25319
|
+
}
|
|
25320
|
+
function classifyFromError2(error) {
|
|
25321
|
+
const code = findCodeInCauseChain2(error);
|
|
25322
|
+
if (code) {
|
|
25323
|
+
if (code.startsWith("commander.")) {
|
|
25324
|
+
return "validation";
|
|
25325
|
+
}
|
|
25326
|
+
if (NETWORK_OS_ERROR_CODES2.has(code) || TLS_ERROR_CODES22.has(code)) {
|
|
25327
|
+
return "network_http";
|
|
25328
|
+
}
|
|
25329
|
+
if (TIMEOUT_OS_ERROR_CODES2.has(code)) {
|
|
25330
|
+
return "timeout";
|
|
25331
|
+
}
|
|
25332
|
+
if (MISSING_DEPENDENCY_CODES2.has(code) || isSpawnEnoent2(error)) {
|
|
25333
|
+
return "missing_dependency";
|
|
25334
|
+
}
|
|
25335
|
+
}
|
|
25336
|
+
const message = stringField2(error, "message");
|
|
25337
|
+
if (message?.includes("fetch failed") === true) {
|
|
25338
|
+
return "network_http";
|
|
25339
|
+
}
|
|
25340
|
+
const name = stringField2(error, "name");
|
|
25341
|
+
if (name && INTERNAL_ERROR_NAMES2.has(name)) {
|
|
25342
|
+
return "internal";
|
|
25343
|
+
}
|
|
25344
|
+
return;
|
|
25345
|
+
}
|
|
25346
|
+
function classifyError2(input) {
|
|
25347
|
+
const recorded = input.recordedFailure;
|
|
25348
|
+
if (recorded?.errorClass) {
|
|
25349
|
+
return recorded.errorClass;
|
|
25350
|
+
}
|
|
25351
|
+
const status = recorded?.context?.httpStatus;
|
|
25352
|
+
if (status !== undefined) {
|
|
25353
|
+
return classifyHttpStatus2(status);
|
|
25354
|
+
}
|
|
25355
|
+
return classifyFromResult2(recorded?.result) ?? classifyFromErrorCode2(recorded?.errorCode) ?? classifyFromError2(input.error) ?? "unknown";
|
|
25356
|
+
}
|
|
25357
|
+
function recordCommandFailureTelemetry2(failure) {
|
|
25358
|
+
recordedFailureSlot2.set(failure);
|
|
25359
|
+
}
|
|
25360
|
+
function clearRecordedCommandFailureTelemetry2() {
|
|
25361
|
+
recordedFailureSlot2.clear();
|
|
25362
|
+
}
|
|
25363
|
+
function takeRecordedCommandFailureTelemetry2() {
|
|
25364
|
+
const failure = recordedFailureSlot2.get();
|
|
25365
|
+
recordedFailureSlot2.clear();
|
|
25366
|
+
return failure;
|
|
25367
|
+
}
|
|
25368
|
+
function buildCommandTerminalTelemetryProperties2(input) {
|
|
25369
|
+
const cancelled = isCancellationError2(input.error, input.exitCode, input.pollSignal);
|
|
25370
|
+
const outcome = input.recordedFailure?.terminalOutcome ?? (input.exitCode === 0 ? "success" : cancelled ? "cancelled" : "failure");
|
|
25371
|
+
const errorClass = outcome === "success" || outcome === "no_op" ? undefined : outcome === "cancelled" ? "user_cancelled" : classifyError2(input);
|
|
25372
|
+
const terminalSignal = terminalSignalFor2(input, outcome);
|
|
25373
|
+
return {
|
|
25374
|
+
exit_code: input.exitCode,
|
|
25375
|
+
terminal_outcome: outcome,
|
|
25376
|
+
...errorClass ? { error_class: errorClass } : {},
|
|
25377
|
+
...terminalSignal ? { terminal_signal: terminalSignal } : {}
|
|
25378
|
+
};
|
|
25379
|
+
}
|
|
25209
25380
|
function readRegistryValue2(keyPath, valueName) {
|
|
25210
25381
|
if (process.platform !== "win32") {
|
|
25211
25382
|
return "";
|
|
@@ -25267,6 +25438,69 @@ function formatMessage2(category, name, properties) {
|
|
|
25267
25438
|
}
|
|
25268
25439
|
return message;
|
|
25269
25440
|
}
|
|
25441
|
+
function detectAgentFromEnv2(env) {
|
|
25442
|
+
for (const agent of KNOWN_AGENTS2) {
|
|
25443
|
+
const envValue = env[agent.envVar];
|
|
25444
|
+
if (agent.value !== undefined) {
|
|
25445
|
+
if (envValue === agent.value)
|
|
25446
|
+
return agent.id;
|
|
25447
|
+
} else {
|
|
25448
|
+
if (envValue)
|
|
25449
|
+
return agent.id;
|
|
25450
|
+
}
|
|
25451
|
+
}
|
|
25452
|
+
const agentEnv = env.AGENT;
|
|
25453
|
+
if (agentEnv) {
|
|
25454
|
+
if (agentEnv === "1" || agentEnv === "true")
|
|
25455
|
+
return "unknown";
|
|
25456
|
+
if (agentEnv.length <= 32)
|
|
25457
|
+
return agentEnv.toLowerCase();
|
|
25458
|
+
}
|
|
25459
|
+
return;
|
|
25460
|
+
}
|
|
25461
|
+
function currentEnv2() {
|
|
25462
|
+
return typeof process === "undefined" ? {} : process.env;
|
|
25463
|
+
}
|
|
25464
|
+
function currentTtyState2() {
|
|
25465
|
+
if (typeof process === "undefined")
|
|
25466
|
+
return false;
|
|
25467
|
+
return Boolean(process.stdout?.isTTY || process.stdin?.isTTY || process.stderr?.isTTY);
|
|
25468
|
+
}
|
|
25469
|
+
function detectCi2(env) {
|
|
25470
|
+
const signature = CI_SIGNATURES2.find((candidate) => candidate.matches(env));
|
|
25471
|
+
if (!signature)
|
|
25472
|
+
return;
|
|
25473
|
+
return {
|
|
25474
|
+
executionContext: signature.isScheduler?.(env) ? "scheduler" : "ci",
|
|
25475
|
+
ciProvider: signature.provider
|
|
25476
|
+
};
|
|
25477
|
+
}
|
|
25478
|
+
function detectExecutionContext2(options = {}) {
|
|
25479
|
+
const env = options.env ?? currentEnv2();
|
|
25480
|
+
const ci = detectCi2(env);
|
|
25481
|
+
if (ci)
|
|
25482
|
+
return ci;
|
|
25483
|
+
const agent = options.agent ?? detectAgentFromEnv2(env);
|
|
25484
|
+
if (agent) {
|
|
25485
|
+
return { executionContext: "agent" };
|
|
25486
|
+
}
|
|
25487
|
+
const authSignal = options.authSignal ?? authSignalSlot2.get();
|
|
25488
|
+
if (authSignal === "service_account") {
|
|
25489
|
+
return { executionContext: "service_account" };
|
|
25490
|
+
}
|
|
25491
|
+
const isTty = options.isTty ?? currentTtyState2();
|
|
25492
|
+
if (isTty) {
|
|
25493
|
+
return { executionContext: "manual" };
|
|
25494
|
+
}
|
|
25495
|
+
return { executionContext: "unknown" };
|
|
25496
|
+
}
|
|
25497
|
+
function getExecutionContextTelemetryProperties2() {
|
|
25498
|
+
const detected = detectExecutionContext2();
|
|
25499
|
+
return {
|
|
25500
|
+
execution_context: detected.executionContext,
|
|
25501
|
+
...detected.ciProvider ? { ci_provider: detected.ciProvider } : {}
|
|
25502
|
+
};
|
|
25503
|
+
}
|
|
25270
25504
|
|
|
25271
25505
|
class NodeContextStorage2 {
|
|
25272
25506
|
storage = new AsyncLocalStorage2;
|
|
@@ -25277,6 +25511,22 @@ class NodeContextStorage2 {
|
|
|
25277
25511
|
return this.storage.getStore();
|
|
25278
25512
|
}
|
|
25279
25513
|
}
|
|
25514
|
+
function getProcessEnv2() {
|
|
25515
|
+
return globalThis.process?.env;
|
|
25516
|
+
}
|
|
25517
|
+
function normalizeSessionId2(value) {
|
|
25518
|
+
if (typeof value !== "string" && typeof value !== "number" && typeof value !== "boolean") {
|
|
25519
|
+
return;
|
|
25520
|
+
}
|
|
25521
|
+
const trimmed = String(value).trim();
|
|
25522
|
+
return trimmed || undefined;
|
|
25523
|
+
}
|
|
25524
|
+
function getConfiguredTelemetrySessionId2() {
|
|
25525
|
+
return normalizeSessionId2(getProcessEnv2()?.[TELEMETRY_SESSION_ID_ENV2]);
|
|
25526
|
+
}
|
|
25527
|
+
function resolveTelemetrySessionId2(existingSessionId) {
|
|
25528
|
+
return getConfiguredTelemetrySessionId2() ?? normalizeSessionId2(existingSessionId);
|
|
25529
|
+
}
|
|
25280
25530
|
function getGlobalTelemetryProperties2() {
|
|
25281
25531
|
return telemetryPropsSlot2.get();
|
|
25282
25532
|
}
|
|
@@ -25358,12 +25608,22 @@ class TelemetryService2 {
|
|
|
25358
25608
|
return this.contextStorage.getContext();
|
|
25359
25609
|
}
|
|
25360
25610
|
enrichPropertiesWithContext(properties, context) {
|
|
25361
|
-
|
|
25362
|
-
|
|
25611
|
+
const globalProperties = getGlobalTelemetryProperties2();
|
|
25612
|
+
const existingSessionId = properties?.[TELEMETRY_SESSION_ID_PROPERTY2] ?? this.defaultProperties?.[TELEMETRY_SESSION_ID_PROPERTY2] ?? globalProperties?.[TELEMETRY_SESSION_ID_PROPERTY2];
|
|
25613
|
+
const sessionId = resolveTelemetrySessionId2(existingSessionId);
|
|
25614
|
+
const enriched = {
|
|
25615
|
+
...getExecutionContextTelemetryProperties2(),
|
|
25616
|
+
...globalProperties,
|
|
25363
25617
|
...this.defaultProperties,
|
|
25364
25618
|
...properties,
|
|
25365
25619
|
...context
|
|
25366
25620
|
};
|
|
25621
|
+
if (sessionId === undefined) {
|
|
25622
|
+
delete enriched[TELEMETRY_SESSION_ID_PROPERTY2];
|
|
25623
|
+
} else {
|
|
25624
|
+
enriched[TELEMETRY_SESSION_ID_PROPERTY2] = sessionId;
|
|
25625
|
+
}
|
|
25626
|
+
return enriched;
|
|
25367
25627
|
}
|
|
25368
25628
|
generateId() {
|
|
25369
25629
|
return crypto.randomUUID().replaceAll("-", "");
|
|
@@ -25745,6 +26005,81 @@ function defaultRetryForErrorCode2(errorCode2) {
|
|
|
25745
26005
|
return "RetryWillNotFix";
|
|
25746
26006
|
}
|
|
25747
26007
|
}
|
|
26008
|
+
function productMode2(productArea, mode) {
|
|
26009
|
+
return { product_area: productArea, mode };
|
|
26010
|
+
}
|
|
26011
|
+
function attributionRecord2(groups) {
|
|
26012
|
+
const record = {};
|
|
26013
|
+
for (const [productArea, mode, names] of groups) {
|
|
26014
|
+
const attribution = productMode2(productArea, mode);
|
|
26015
|
+
for (const name of names) {
|
|
26016
|
+
record[name] = attribution;
|
|
26017
|
+
}
|
|
26018
|
+
}
|
|
26019
|
+
return record;
|
|
26020
|
+
}
|
|
26021
|
+
function commandAttribution2(groups) {
|
|
26022
|
+
const entries = [];
|
|
26023
|
+
for (const [productArea, mode, prefixes] of groups) {
|
|
26024
|
+
const attribution = productMode2(productArea, mode);
|
|
26025
|
+
for (const prefix of prefixes) {
|
|
26026
|
+
entries.push({ prefix, attribution });
|
|
26027
|
+
}
|
|
26028
|
+
}
|
|
26029
|
+
return entries;
|
|
26030
|
+
}
|
|
26031
|
+
function normalizeCommandPath2(value) {
|
|
26032
|
+
if (typeof value !== "string") {
|
|
26033
|
+
return;
|
|
26034
|
+
}
|
|
26035
|
+
const trimmed = value.trim().toLowerCase();
|
|
26036
|
+
if (!trimmed) {
|
|
26037
|
+
return;
|
|
26038
|
+
}
|
|
26039
|
+
const tokens = trimmed.includes(" ") ? trimmed.split(/\s+/).filter((token) => token.length > 0).filter((token) => !token.startsWith("-")) : trimmed.split(".").filter((token) => token.length > 0);
|
|
26040
|
+
if (tokens.length === 0) {
|
|
26041
|
+
return;
|
|
26042
|
+
}
|
|
26043
|
+
const commandTokens = tokens[0] === "uip" ? tokens : ["uip", ...tokens];
|
|
26044
|
+
return commandTokens.join(".");
|
|
26045
|
+
}
|
|
26046
|
+
function getCommandProductModeAttribution2(commandPath) {
|
|
26047
|
+
const normalized = normalizeCommandPath2(commandPath);
|
|
26048
|
+
if (!normalized) {
|
|
26049
|
+
return;
|
|
26050
|
+
}
|
|
26051
|
+
return COMMAND_ATTRIBUTION2.find(({ prefix }) => normalized === prefix || normalized.startsWith(`${prefix}.`))?.attribution;
|
|
26052
|
+
}
|
|
26053
|
+
function normalizeSkillNameWithOptions2(value, options) {
|
|
26054
|
+
if (typeof value !== "string") {
|
|
26055
|
+
return;
|
|
26056
|
+
}
|
|
26057
|
+
const normalized = value.trim().toLowerCase();
|
|
26058
|
+
if (!normalized) {
|
|
26059
|
+
return;
|
|
26060
|
+
}
|
|
26061
|
+
const hasLegacyNamespace = normalized.startsWith(LEGACY_SKILL_NAMESPACE2);
|
|
26062
|
+
if (hasLegacyNamespace && !options.allowLegacyNamespace) {
|
|
26063
|
+
return;
|
|
26064
|
+
}
|
|
26065
|
+
const skillName = hasLegacyNamespace ? normalized.slice(LEGACY_SKILL_NAMESPACE2.length) : normalized;
|
|
26066
|
+
if (skillName.length > MAX_SKILL_NAME_LENGTH2 || !SKILL_NAME_PATTERN2.test(skillName) || !KNOWN_SKILL_NAMES2.has(skillName)) {
|
|
26067
|
+
return;
|
|
26068
|
+
}
|
|
26069
|
+
return skillName;
|
|
26070
|
+
}
|
|
26071
|
+
function normalizeSkillName2(value) {
|
|
26072
|
+
return normalizeSkillNameWithOptions2(value, {
|
|
26073
|
+
allowLegacyNamespace: false
|
|
26074
|
+
});
|
|
26075
|
+
}
|
|
26076
|
+
function buildCommandTelemetryAttribution2(commandPath, skillSource) {
|
|
26077
|
+
const skillName = normalizeSkillName2(skillSource);
|
|
26078
|
+
return {
|
|
26079
|
+
...skillName ? { skill_name: skillName } : {},
|
|
26080
|
+
...getCommandProductModeAttribution2(commandPath)
|
|
26081
|
+
};
|
|
26082
|
+
}
|
|
25748
26083
|
function shortHash2(input) {
|
|
25749
26084
|
let hash = 2166136261;
|
|
25750
26085
|
for (let i2 = 0;i2 < input.length; i2++) {
|
|
@@ -25871,6 +26206,12 @@ function commandHelpHint2(commandPath) {
|
|
|
25871
26206
|
const command = commandPath.replace(/\./g, " ");
|
|
25872
26207
|
return `An unexpected error occurred. Run '${command} --help' to verify command syntax, or run with --log-level debug for details.`;
|
|
25873
26208
|
}
|
|
26209
|
+
function isPromptCancellation2(error) {
|
|
26210
|
+
return error instanceof Error && error.name === "ExitPromptError";
|
|
26211
|
+
}
|
|
26212
|
+
function exitCodeFromProcess2(fallback) {
|
|
26213
|
+
return typeof process.exitCode === "number" ? process.exitCode : fallback;
|
|
26214
|
+
}
|
|
25874
26215
|
function isPreviewBuild2() {
|
|
25875
26216
|
return previewSlot2.get(false) ?? false;
|
|
25876
26217
|
}
|
|
@@ -26234,7 +26575,7 @@ var __create3, __getProtoOf3, __defProp3, __getOwnPropNames3, __hasOwnProp3, __t
|
|
|
26234
26575
|
...options,
|
|
26235
26576
|
target
|
|
26236
26577
|
});
|
|
26237
|
-
}, apps2, open_default2, LOCK_HEARTBEAT_MS2 = 5000, LOCK_STALE_MS2 = 15000, LOCK_MAX_WAIT_MS2 = 20000, LOCK_MAX_HOLD_MS2 = 60000, LOCK_RETRY_MIN_MS2 = 100, LOCK_RETRY_JITTER_MS2 = 200, fsInstance2, getFileSystem2 = () => fsInstance2, NETWORK_ERROR_CODES2,
|
|
26578
|
+
}, apps2, open_default2, LOCK_HEARTBEAT_MS2 = 5000, LOCK_STALE_MS2 = 15000, LOCK_MAX_WAIT_MS2 = 20000, LOCK_MAX_HOLD_MS2 = 60000, LOCK_RETRY_MIN_MS2 = 100, LOCK_RETRY_JITTER_MS2 = 200, fsInstance2, getFileSystem2 = () => fsInstance2, NETWORK_ERROR_CODES2, TLS_ERROR_CODES3, TLS_INSTRUCTIONS2, NETWORK_INSTRUCTIONS2, import__3, program2, createCommand2, createArgument2, createOption2, CommanderError2, InvalidArgumentError2, InvalidOptionArgumentError2, Command2, Argument2, Option2, Help2, examplesByCommand2, PREFIX2 = "@uipath/common/", _g2, storageSingleton2, sinkSlot2, outputStorage2, CONSOLE_FALLBACK2, COMPLETER_SYMBOL2, isObject2 = (obj) => {
|
|
26238
26579
|
return obj !== null && Object.prototype.toString.call(obj) === "[object Object]";
|
|
26239
26580
|
}, strictDeepEqual2 = (first, second) => {
|
|
26240
26581
|
if (first === second) {
|
|
@@ -28085,7 +28426,7 @@ var __create3, __getProtoOf3, __defProp3, __getOwnPropNames3, __hasOwnProp3, __t
|
|
|
28085
28426
|
}, __toESM22 = (mod22, isNodeMode, target) => (target = mod22 != null ? __create22(__getProtoOf22(mod22)) : {}, __copyProps2(isNodeMode || !mod22 || !mod22.__esModule ? __defProp22(target, "default", {
|
|
28086
28427
|
value: mod22,
|
|
28087
28428
|
enumerable: true
|
|
28088
|
-
}) : target, mod22)), require_common2, require_exception2, require_snippet2, require_type2, require_schema2, require_str2, require_seq2, require_map3, require_failsafe2, require_null2, require_bool2, require_int2, require_float2, require_json2, require_core2, require_timestamp2, require_merge3, require_binary2, require_omap2, require_pairs3, require_set2, require_default2, require_loader2, require_dumper2, import_js_yaml2, Type2, Schema2, FAILSAFE_SCHEMA2, JSON_SCHEMA2, CORE_SCHEMA2, DEFAULT_SCHEMA2, load2, loadAll2, dump2, YAMLException2, types2, safeLoad2, safeLoadAll2, safeDump2, index_vite_proxy_tmp_default2, logFilePathSlot2, LogLevel3, DEFAULT_LOG_LEVEL2 = 3, SimpleLogger2, loggerSingleton2, logger3, formatSlot2, formatExplicitSlot2, filterSlot2, CommonTelemetryEvents2, telemetryPropsSlot2, providerSlot2, telemetryInstanceSlot2, DEFAULT_AI_CONNECTION_STRING2, _localTelemetryInstance2, telemetry2, CLI_ERROR_CODES2, RETRY_HINTS2, RESULTS2, EXIT_CODES2, FilterEvaluationError2, OutputFormatter2, REDACTED2 = "[REDACTED]", MAX_VALUE_LENGTH2 = 200, SENSITIVE_NAME_TOKENS2, SENSITIVE_KEY_PREFIXES2, UUID_PATTERN2, EMAIL_PATTERN2, JWT_PATTERN2, LONG_TOKEN_PATTERN2, USER_HOME_PATTERN2, URL_PATTERN2, URL_TRAILING_PUNCT2, pollSignalSlot2, cliErrorCodeValues2, retryHintValues2, guardInstalledSlot2, savedOriginalsSlot2, DEFAULT_AUTH_TIMEOUT_MS3, modeSlot2, PollOutcome2, REASON_BY_OUTCOME2, TERMINAL_STATUSES2, FAILURE_STATUSES2, previewSlot2, ScreenLogger2, USER_AGENT_HEADER2 = "User-Agent", sdkUserAgentHostToken2, factorySlot2;
|
|
28429
|
+
}) : target, mod22)), require_common2, require_exception2, require_snippet2, require_type2, require_schema2, require_str2, require_seq2, require_map3, require_failsafe2, require_null2, require_bool2, require_int2, require_float2, require_json2, require_core2, require_timestamp2, require_merge3, require_binary2, require_omap2, require_pairs3, require_set2, require_default2, require_loader2, require_dumper2, import_js_yaml2, Type2, Schema2, FAILSAFE_SCHEMA2, JSON_SCHEMA2, CORE_SCHEMA2, DEFAULT_SCHEMA2, load2, loadAll2, dump2, YAMLException2, types2, safeLoad2, safeLoadAll2, safeDump2, index_vite_proxy_tmp_default2, logFilePathSlot2, LogLevel3, DEFAULT_LOG_LEVEL2 = 3, SimpleLogger2, loggerSingleton2, logger3, formatSlot2, formatExplicitSlot2, filterSlot2, recordedFailureSlot2, AUTH_ERROR_CODES2, VALIDATION_ERROR_CODES2, NETWORK_HTTP_ERROR_CODES2, TIMEOUT_ERROR_CODES2, NETWORK_OS_ERROR_CODES2, TIMEOUT_OS_ERROR_CODES2, TLS_ERROR_CODES22, MISSING_DEPENDENCY_CODES2, INTERNAL_ERROR_NAMES2, CommonTelemetryEvents2, KNOWN_AGENTS2, LOCAL_HOSTS2, authSignalSlot2, isTruthy2 = (value) => value !== undefined && value !== "" && value !== "0" && value.toLowerCase() !== "false", isEqual2 = (value, expected) => value?.toLowerCase() === expected, CI_SIGNATURES2, TELEMETRY_SESSION_ID_ENV2 = "UIPATH_SESSION_ID", TELEMETRY_SESSION_ID_PROPERTY2 = "session_id", telemetrySessionIdSlot2, telemetryPropsSlot2, providerSlot2, telemetryInstanceSlot2, DEFAULT_AI_CONNECTION_STRING2, _localTelemetryInstance2, telemetry2, CLI_ERROR_CODES2, RETRY_HINTS2, RESULTS2, EXIT_CODES2, FilterEvaluationError2, OutputFormatter2, LEGACY_SKILL_NAMESPACE2 = "uipath:", MAX_SKILL_NAME_LENGTH2 = 80, SKILL_NAME_PATTERN2, SKILL_ATTRIBUTION2, KNOWN_SKILL_NAMES2, COMMAND_ATTRIBUTION2, REDACTED2 = "[REDACTED]", MAX_VALUE_LENGTH2 = 200, SENSITIVE_NAME_TOKENS2, SENSITIVE_KEY_PREFIXES2, UUID_PATTERN2, EMAIL_PATTERN2, JWT_PATTERN2, LONG_TOKEN_PATTERN2, USER_HOME_PATTERN2, URL_PATTERN2, URL_TRAILING_PUNCT2, pollSignalSlot2, cliErrorCodeValues2, retryHintValues2, guardInstalledSlot2, savedOriginalsSlot2, DEFAULT_AUTH_TIMEOUT_MS3, modeSlot2, PollOutcome2, REASON_BY_OUTCOME2, TERMINAL_STATUSES2, FAILURE_STATUSES2, previewSlot2, ScreenLogger2, USER_AGENT_HEADER2 = "User-Agent", sdkUserAgentHostToken2, shippedKeysSlot2, factorySlot2;
|
|
28089
28430
|
var init_dist2 = __esm(() => {
|
|
28090
28431
|
__create3 = Object.create;
|
|
28091
28432
|
__getProtoOf3 = Object.getPrototypeOf;
|
|
@@ -30297,7 +30638,7 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
30297
30638
|
"ENETUNREACH",
|
|
30298
30639
|
"EAI_FAIL"
|
|
30299
30640
|
]);
|
|
30300
|
-
|
|
30641
|
+
TLS_ERROR_CODES3 = new Set([
|
|
30301
30642
|
"SELF_SIGNED_CERT_IN_CHAIN",
|
|
30302
30643
|
"DEPTH_ZERO_SELF_SIGNED_CERT",
|
|
30303
30644
|
"UNABLE_TO_VERIFY_LEAF_SIGNATURE",
|
|
@@ -33343,9 +33684,118 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
33343
33684
|
formatSlot2 = singleton3("OutputFormat");
|
|
33344
33685
|
formatExplicitSlot2 = singleton3("OutputFormatExplicit");
|
|
33345
33686
|
filterSlot2 = singleton3("OutputFilter");
|
|
33687
|
+
recordedFailureSlot2 = singleton3("CommandTelemetryFailure");
|
|
33688
|
+
AUTH_ERROR_CODES2 = new Set([
|
|
33689
|
+
"authentication_required",
|
|
33690
|
+
"permission_denied"
|
|
33691
|
+
]);
|
|
33692
|
+
VALIDATION_ERROR_CODES2 = new Set(["invalid_argument"]);
|
|
33693
|
+
NETWORK_HTTP_ERROR_CODES2 = new Set([
|
|
33694
|
+
"network_error",
|
|
33695
|
+
"rate_limited",
|
|
33696
|
+
"server_error",
|
|
33697
|
+
"not_found",
|
|
33698
|
+
"method_not_allowed"
|
|
33699
|
+
]);
|
|
33700
|
+
TIMEOUT_ERROR_CODES2 = new Set(["timeout"]);
|
|
33701
|
+
NETWORK_OS_ERROR_CODES2 = new Set([
|
|
33702
|
+
"ECONNREFUSED",
|
|
33703
|
+
"ECONNRESET",
|
|
33704
|
+
"ENOTFOUND",
|
|
33705
|
+
"EAI_AGAIN",
|
|
33706
|
+
"EPIPE",
|
|
33707
|
+
"EHOSTUNREACH",
|
|
33708
|
+
"ENETUNREACH",
|
|
33709
|
+
"EAI_FAIL"
|
|
33710
|
+
]);
|
|
33711
|
+
TIMEOUT_OS_ERROR_CODES2 = new Set(["ETIMEDOUT", "ESOCKETTIMEDOUT"]);
|
|
33712
|
+
TLS_ERROR_CODES22 = new Set([
|
|
33713
|
+
"SELF_SIGNED_CERT_IN_CHAIN",
|
|
33714
|
+
"DEPTH_ZERO_SELF_SIGNED_CERT",
|
|
33715
|
+
"UNABLE_TO_VERIFY_LEAF_SIGNATURE",
|
|
33716
|
+
"UNABLE_TO_GET_ISSUER_CERT_LOCALLY",
|
|
33717
|
+
"UNABLE_TO_GET_ISSUER_CERT",
|
|
33718
|
+
"CERT_HAS_EXPIRED",
|
|
33719
|
+
"CERT_UNTRUSTED",
|
|
33720
|
+
"ERR_TLS_CERT_ALTNAME_INVALID"
|
|
33721
|
+
]);
|
|
33722
|
+
MISSING_DEPENDENCY_CODES2 = new Set([
|
|
33723
|
+
"MODULE_NOT_FOUND",
|
|
33724
|
+
"ERR_MODULE_NOT_FOUND"
|
|
33725
|
+
]);
|
|
33726
|
+
INTERNAL_ERROR_NAMES2 = new Set([
|
|
33727
|
+
"TypeError",
|
|
33728
|
+
"ReferenceError",
|
|
33729
|
+
"SyntaxError",
|
|
33730
|
+
"RangeError"
|
|
33731
|
+
]);
|
|
33346
33732
|
CommonTelemetryEvents2 = {
|
|
33347
|
-
Error: "uip.error"
|
|
33348
|
-
|
|
33733
|
+
Error: "uip.error",
|
|
33734
|
+
ShipSucceeded: "ship_succeeded"
|
|
33735
|
+
};
|
|
33736
|
+
KNOWN_AGENTS2 = [
|
|
33737
|
+
{ envVar: "CLAUDECODE", value: "1", id: "claude-code" },
|
|
33738
|
+
{ envVar: "CURSOR_AGENT", value: "1", id: "cursor" },
|
|
33739
|
+
{ envVar: "GEMINI_CLI", value: "1", id: "gemini-cli" },
|
|
33740
|
+
{ envVar: "CODEX_THREAD_ID", id: "codex" },
|
|
33741
|
+
{ envVar: "CODEX_SANDBOX", id: "codex" },
|
|
33742
|
+
{ envVar: "AUGMENT_AGENT", value: "1", id: "augment" },
|
|
33743
|
+
{ envVar: "CLINE_ACTIVE", value: "true", id: "cline" }
|
|
33744
|
+
];
|
|
33745
|
+
LOCAL_HOSTS2 = new Set(["localhost", "127.0.0.1", "::1", "[::1]"]);
|
|
33746
|
+
authSignalSlot2 = singleton3("TelemetryExecutionContextAuthSignal");
|
|
33747
|
+
CI_SIGNATURES2 = [
|
|
33748
|
+
{
|
|
33749
|
+
provider: "github_actions",
|
|
33750
|
+
matches: (env) => isTruthy2(env.GITHUB_ACTIONS),
|
|
33751
|
+
isScheduler: (env) => env.GITHUB_EVENT_NAME === "schedule"
|
|
33752
|
+
},
|
|
33753
|
+
{
|
|
33754
|
+
provider: "azure_devops",
|
|
33755
|
+
matches: (env) => isTruthy2(env.TF_BUILD),
|
|
33756
|
+
isScheduler: (env) => isEqual2(env.BUILD_REASON, "schedule")
|
|
33757
|
+
},
|
|
33758
|
+
{
|
|
33759
|
+
provider: "gitlab",
|
|
33760
|
+
matches: (env) => isTruthy2(env.GITLAB_CI),
|
|
33761
|
+
isScheduler: (env) => env.CI_PIPELINE_SOURCE === "schedule"
|
|
33762
|
+
},
|
|
33763
|
+
{
|
|
33764
|
+
provider: "circleci",
|
|
33765
|
+
matches: (env) => isTruthy2(env.CIRCLECI),
|
|
33766
|
+
isScheduler: (env) => env.CIRCLE_PIPELINE_TRIGGER_SOURCE === "scheduled_pipeline"
|
|
33767
|
+
},
|
|
33768
|
+
{
|
|
33769
|
+
provider: "jenkins",
|
|
33770
|
+
matches: (env) => isTruthy2(env.JENKINS_URL) || isTruthy2(env.JENKINS_HOME)
|
|
33771
|
+
},
|
|
33772
|
+
{
|
|
33773
|
+
provider: "teamcity",
|
|
33774
|
+
matches: (env) => isTruthy2(env.TEAMCITY_VERSION)
|
|
33775
|
+
},
|
|
33776
|
+
{
|
|
33777
|
+
provider: "buildkite",
|
|
33778
|
+
matches: (env) => isTruthy2(env.BUILDKITE),
|
|
33779
|
+
isScheduler: (env) => env.BUILDKITE_SOURCE === "schedule"
|
|
33780
|
+
},
|
|
33781
|
+
{
|
|
33782
|
+
provider: "bitbucket",
|
|
33783
|
+
matches: (env) => isTruthy2(env.BITBUCKET_BUILD_NUMBER)
|
|
33784
|
+
},
|
|
33785
|
+
{
|
|
33786
|
+
provider: "travis",
|
|
33787
|
+
matches: (env) => isTruthy2(env.TRAVIS)
|
|
33788
|
+
},
|
|
33789
|
+
{
|
|
33790
|
+
provider: "appveyor",
|
|
33791
|
+
matches: (env) => isTruthy2(env.APPVEYOR)
|
|
33792
|
+
},
|
|
33793
|
+
{
|
|
33794
|
+
provider: "generic",
|
|
33795
|
+
matches: (env) => isTruthy2(env.CI)
|
|
33796
|
+
}
|
|
33797
|
+
];
|
|
33798
|
+
telemetrySessionIdSlot2 = singleton3("TelemetrySessionId");
|
|
33349
33799
|
telemetryPropsSlot2 = singleton3("TelemetryDefaultProps");
|
|
33350
33800
|
providerSlot2 = singleton3("TelemetryProvider");
|
|
33351
33801
|
telemetryInstanceSlot2 = singleton3("TelemetryService");
|
|
@@ -33429,8 +33879,24 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
33429
33879
|
data.ErrorCode ??= defaultErrorCodeForFailure2(data);
|
|
33430
33880
|
data.Retry ??= defaultRetryForErrorCode2(data.ErrorCode);
|
|
33431
33881
|
process.exitCode = EXIT_CODES2[data.Result] ?? 1;
|
|
33432
|
-
|
|
33433
|
-
|
|
33882
|
+
recordCommandFailureTelemetry2({
|
|
33883
|
+
result: data.Result,
|
|
33884
|
+
errorCode: data.ErrorCode,
|
|
33885
|
+
retry: data.Retry,
|
|
33886
|
+
message: data.Message,
|
|
33887
|
+
context: data.Context,
|
|
33888
|
+
exitCode: process.exitCode,
|
|
33889
|
+
errorClass: data.TelemetryErrorClass,
|
|
33890
|
+
terminalOutcome: data.TelemetryTerminalOutcome,
|
|
33891
|
+
terminalSignal: data.TelemetryTerminalSignal
|
|
33892
|
+
});
|
|
33893
|
+
const suppressTelemetry = data.SuppressTelemetry === true;
|
|
33894
|
+
const envelope = { ...data };
|
|
33895
|
+
delete envelope.SuppressTelemetry;
|
|
33896
|
+
delete envelope.TelemetryErrorClass;
|
|
33897
|
+
delete envelope.TelemetryTerminalOutcome;
|
|
33898
|
+
delete envelope.TelemetryTerminalSignal;
|
|
33899
|
+
if (!suppressTelemetry) {
|
|
33434
33900
|
telemetry2.trackEvent(CommonTelemetryEvents2.Error, {
|
|
33435
33901
|
result: data.Result,
|
|
33436
33902
|
errorCode: data.ErrorCode,
|
|
@@ -33492,6 +33958,79 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
33492
33958
|
}
|
|
33493
33959
|
OutputFormatter3.formatToString = formatToString;
|
|
33494
33960
|
})(OutputFormatter2 ||= {});
|
|
33961
|
+
SKILL_NAME_PATTERN2 = /^[a-z0-9][a-z0-9-]*[a-z0-9]$/;
|
|
33962
|
+
SKILL_ATTRIBUTION2 = attributionRecord2([
|
|
33963
|
+
["admin", "operate", ["uipath-admin"]],
|
|
33964
|
+
["agents", "build", ["uipath-agents"]],
|
|
33965
|
+
["api-workflow", "build", ["uipath-api-workflow"]],
|
|
33966
|
+
["automation-discovery", "build", ["uipath-automation-discovery"]],
|
|
33967
|
+
["coded-apps", "build", ["uipath-coded-apps"]],
|
|
33968
|
+
["data-fabric", "operate", ["uipath-data-fabric"]],
|
|
33969
|
+
["cli", "troubleshoot", ["uipath-feedback"]],
|
|
33970
|
+
["governance", "operate", ["uipath-governance"]],
|
|
33971
|
+
["action-center", "build", ["uipath-human-in-the-loop"]],
|
|
33972
|
+
["document-understanding", "build", ["uipath-ixp"]],
|
|
33973
|
+
[
|
|
33974
|
+
"maestro",
|
|
33975
|
+
"build",
|
|
33976
|
+
["uipath-maestro-bpmn", "uipath-maestro-case", "uipath-maestro-flow"]
|
|
33977
|
+
],
|
|
33978
|
+
["agenthub", "build", ["uipath-mcp-servers"]],
|
|
33979
|
+
["solution", "build", ["uipath-planner", "uipath-solution"]],
|
|
33980
|
+
["platform", "operate", ["uipath-platform"]],
|
|
33981
|
+
["quality", "troubleshoot", ["uipath-review"]],
|
|
33982
|
+
["rpa", "build", ["uipath-rpa"]],
|
|
33983
|
+
["cli", "operate", ["uipath-skill-catalog"]],
|
|
33984
|
+
["action-center", "operate", ["uipath-tasks"]],
|
|
33985
|
+
["test-manager", "operate", ["uipath-test"]],
|
|
33986
|
+
["platform", "troubleshoot", ["uipath-troubleshoot"]]
|
|
33987
|
+
]);
|
|
33988
|
+
KNOWN_SKILL_NAMES2 = new Set(Object.keys(SKILL_ATTRIBUTION2));
|
|
33989
|
+
COMMAND_ATTRIBUTION2 = commandAttribution2([
|
|
33990
|
+
["cli", "troubleshoot", ["uip.feedback"]],
|
|
33991
|
+
["llm-gateway", "operate", ["uip.llm-configuration", "uip.model-hub"]],
|
|
33992
|
+
["context-grounding", "build", ["uip.context-grounding"]],
|
|
33993
|
+
["api-workflow", "build", ["uip.api-workflow"]],
|
|
33994
|
+
["rpa", "build", ["uip.rpa-legacy"]],
|
|
33995
|
+
["conversational", "operate", ["uip.conversational"]],
|
|
33996
|
+
["agents", "build", ["uip.codedagent", "uip.agent"]],
|
|
33997
|
+
["agenthub", "build", ["uip.agenthub"]],
|
|
33998
|
+
["coded-apps", "build", ["uip.codedapp"]],
|
|
33999
|
+
["functions", "build", ["uip.functions"]],
|
|
34000
|
+
["solution", "build", ["uip.solution"]],
|
|
34001
|
+
["maestro", "build", ["uip.maestro", "uip.case", "uip.flow"]],
|
|
34002
|
+
["llm-observability", "troubleshoot", ["uip.traces"]],
|
|
34003
|
+
["platform", "operate", ["uip.platform"]],
|
|
34004
|
+
["admin", "operate", ["uip.admin"]],
|
|
34005
|
+
["automation-ops", "operate", ["uip.aops"]],
|
|
34006
|
+
["documentation", "troubleshoot", ["uip.docsai"]],
|
|
34007
|
+
["governance", "operate", ["uip.gov"]],
|
|
34008
|
+
["insights", "operate", ["uip.insights"]],
|
|
34009
|
+
["document-understanding", "build", ["uip.ixp"]],
|
|
34010
|
+
["process-mining", "operate", ["uip.pm"]],
|
|
34011
|
+
["action-center", "operate", ["uip.tasks"]],
|
|
34012
|
+
["test-manager", "operate", ["uip.tm"]],
|
|
34013
|
+
["vertical-solutions", "build", ["uip.vss"]],
|
|
34014
|
+
["data-fabric", "operate", ["uip.df"]],
|
|
34015
|
+
["integration-service", "build", ["uip.is"]],
|
|
34016
|
+
["orchestrator", "operate", ["uip.or"]],
|
|
34017
|
+
[
|
|
34018
|
+
"cli",
|
|
34019
|
+
"operate",
|
|
34020
|
+
[
|
|
34021
|
+
"uip.login",
|
|
34022
|
+
"uip.logout",
|
|
34023
|
+
"uip.user",
|
|
34024
|
+
"uip.config",
|
|
34025
|
+
"uip.tools",
|
|
34026
|
+
"uip.skills",
|
|
34027
|
+
"uip.completion",
|
|
34028
|
+
"uip.update",
|
|
34029
|
+
"uip.mcp",
|
|
34030
|
+
"uip.track"
|
|
34031
|
+
]
|
|
34032
|
+
]
|
|
34033
|
+
]).sort((a, b) => b.prefix.length - a.prefix.length);
|
|
33495
34034
|
SENSITIVE_NAME_TOKENS2 = new Set([
|
|
33496
34035
|
"token",
|
|
33497
34036
|
"tokens",
|
|
@@ -33545,6 +34084,8 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
33545
34084
|
const props = typeof properties === "function" ? properties(...args) : properties;
|
|
33546
34085
|
const startTime = performance.now();
|
|
33547
34086
|
let errorMessage2;
|
|
34087
|
+
let fallbackExitCode = EXIT_CODES2.Success;
|
|
34088
|
+
clearRecordedCommandFailureTelemetry2();
|
|
33548
34089
|
const [error] = await catchError3(fn(...args));
|
|
33549
34090
|
if (error) {
|
|
33550
34091
|
errorMessage2 = error instanceof Error ? error.message : String(error);
|
|
@@ -33559,6 +34100,8 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
33559
34100
|
const customRetry = isRetryHint2(typedRetry) ? typedRetry : undefined;
|
|
33560
34101
|
const typedContext = typed.context ?? typed.Context;
|
|
33561
34102
|
const customContext = isErrorContext2(typedContext) ? typedContext : undefined;
|
|
34103
|
+
const cancellationExitCode = typed.exitCode === 130 || isPromptCancellation2(error) ? 130 : undefined;
|
|
34104
|
+
fallbackExitCode = cancellationExitCode ?? EXIT_CODES2[finalResult];
|
|
33562
34105
|
OutputFormatter2.error({
|
|
33563
34106
|
Result: finalResult,
|
|
33564
34107
|
...customErrorCode ? { ErrorCode: customErrorCode } : {},
|
|
@@ -33567,16 +34110,26 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
33567
34110
|
...customRetry ? { Retry: customRetry } : {},
|
|
33568
34111
|
...customContext ? { Context: customContext } : {}
|
|
33569
34112
|
});
|
|
33570
|
-
context.exit(
|
|
34113
|
+
context.exit(fallbackExitCode);
|
|
33571
34114
|
}
|
|
33572
34115
|
const durationMs = performance.now() - startTime;
|
|
33573
|
-
const
|
|
34116
|
+
const exitCode = fallbackExitCode === 130 ? fallbackExitCode : exitCodeFromProcess2(fallbackExitCode);
|
|
34117
|
+
const recordedFailure = takeRecordedCommandFailureTelemetry2();
|
|
34118
|
+
const success = !error && exitCode === 0;
|
|
34119
|
+
const terminalTelemetry = buildCommandTerminalTelemetryProperties2({
|
|
34120
|
+
error,
|
|
34121
|
+
exitCode,
|
|
34122
|
+
recordedFailure,
|
|
34123
|
+
pollSignal: context.pollSignal
|
|
34124
|
+
});
|
|
33574
34125
|
telemetry2.trackEvent(telemetryName, redactProperties2({
|
|
33575
34126
|
...extractCommandParams2(command),
|
|
33576
34127
|
...props,
|
|
34128
|
+
...buildCommandTelemetryAttribution2(telemetryName, process.env.UIPATH_SKILL),
|
|
33577
34129
|
command: "true",
|
|
33578
34130
|
duration: String(durationMs),
|
|
33579
34131
|
success: String(success),
|
|
34132
|
+
...terminalTelemetry,
|
|
33580
34133
|
...errorMessage2 ? { errorMessage: errorMessage2 } : {}
|
|
33581
34134
|
}));
|
|
33582
34135
|
});
|
|
@@ -33630,6 +34183,7 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
33630
34183
|
ScreenLogger3.progress = progress;
|
|
33631
34184
|
})(ScreenLogger2 ||= {});
|
|
33632
34185
|
sdkUserAgentHostToken2 = singleton3("SdkUserAgentHostToken");
|
|
34186
|
+
shippedKeysSlot2 = singleton3("ShipSucceededDedupeKeys");
|
|
33633
34187
|
factorySlot2 = singleton3("PackagerFactoryProvider");
|
|
33634
34188
|
});
|
|
33635
34189
|
|
|
@@ -37613,6 +38167,177 @@ function getOutputFormat3() {
|
|
|
37613
38167
|
function getOutputFilter3() {
|
|
37614
38168
|
return filterSlot3.get();
|
|
37615
38169
|
}
|
|
38170
|
+
function isRecord3(value) {
|
|
38171
|
+
return value !== null && typeof value === "object";
|
|
38172
|
+
}
|
|
38173
|
+
function stringField3(value, field) {
|
|
38174
|
+
if (!isRecord3(value)) {
|
|
38175
|
+
return;
|
|
38176
|
+
}
|
|
38177
|
+
const raw = value[field];
|
|
38178
|
+
return typeof raw === "string" ? raw : undefined;
|
|
38179
|
+
}
|
|
38180
|
+
function numberField3(value, field) {
|
|
38181
|
+
if (!isRecord3(value)) {
|
|
38182
|
+
return;
|
|
38183
|
+
}
|
|
38184
|
+
const raw = value[field];
|
|
38185
|
+
return typeof raw === "number" ? raw : undefined;
|
|
38186
|
+
}
|
|
38187
|
+
function findStringInCauseChain3(error, field) {
|
|
38188
|
+
let current = error;
|
|
38189
|
+
for (let depth = 0;depth < 5 && current !== null && typeof current === "object"; depth++) {
|
|
38190
|
+
const value = stringField3(current, field);
|
|
38191
|
+
if (value) {
|
|
38192
|
+
return value;
|
|
38193
|
+
}
|
|
38194
|
+
current = current.cause;
|
|
38195
|
+
}
|
|
38196
|
+
return;
|
|
38197
|
+
}
|
|
38198
|
+
function findCodeInCauseChain3(error) {
|
|
38199
|
+
return findStringInCauseChain3(error, "code");
|
|
38200
|
+
}
|
|
38201
|
+
function isSpawnEnoent3(error) {
|
|
38202
|
+
const code = findCodeInCauseChain3(error);
|
|
38203
|
+
if (code !== "ENOENT") {
|
|
38204
|
+
return false;
|
|
38205
|
+
}
|
|
38206
|
+
const syscall = findStringInCauseChain3(error, "syscall");
|
|
38207
|
+
return syscall?.startsWith("spawn") === true;
|
|
38208
|
+
}
|
|
38209
|
+
function isCancellationError3(error, exitCode, pollSignal) {
|
|
38210
|
+
if (exitCode === 130) {
|
|
38211
|
+
return true;
|
|
38212
|
+
}
|
|
38213
|
+
if (!isRecord3(error)) {
|
|
38214
|
+
return false;
|
|
38215
|
+
}
|
|
38216
|
+
if (numberField3(error, "exitCode") === 130) {
|
|
38217
|
+
return true;
|
|
38218
|
+
}
|
|
38219
|
+
const name = stringField3(error, "name");
|
|
38220
|
+
if (name === "ExitPromptError") {
|
|
38221
|
+
return true;
|
|
38222
|
+
}
|
|
38223
|
+
if (name === "AbortError" && pollSignal?.aborted) {
|
|
38224
|
+
return true;
|
|
38225
|
+
}
|
|
38226
|
+
const message = stringField3(error, "message");
|
|
38227
|
+
return message?.includes("SIGINT") === true;
|
|
38228
|
+
}
|
|
38229
|
+
function terminalSignalFor3(input, outcome) {
|
|
38230
|
+
if (input.recordedFailure?.terminalSignal) {
|
|
38231
|
+
return input.recordedFailure.terminalSignal;
|
|
38232
|
+
}
|
|
38233
|
+
const explicit = findStringInCauseChain3(input.error, "terminalSignal") ?? findStringInCauseChain3(input.error, "signal");
|
|
38234
|
+
if (explicit) {
|
|
38235
|
+
return explicit;
|
|
38236
|
+
}
|
|
38237
|
+
return outcome === "cancelled" ? "SIGINT" : undefined;
|
|
38238
|
+
}
|
|
38239
|
+
function classifyHttpStatus3(status) {
|
|
38240
|
+
if (status === 401 || status === 403) {
|
|
38241
|
+
return "auth";
|
|
38242
|
+
}
|
|
38243
|
+
if (status === 400 || status === 409 || status === 422) {
|
|
38244
|
+
return "validation";
|
|
38245
|
+
}
|
|
38246
|
+
if (status === 408) {
|
|
38247
|
+
return "timeout";
|
|
38248
|
+
}
|
|
38249
|
+
return "network_http";
|
|
38250
|
+
}
|
|
38251
|
+
function classifyFromResult3(result) {
|
|
38252
|
+
switch (result) {
|
|
38253
|
+
case "AuthenticationError":
|
|
38254
|
+
return "auth";
|
|
38255
|
+
case "ValidationError":
|
|
38256
|
+
return "validation";
|
|
38257
|
+
case "TimeoutError":
|
|
38258
|
+
return "timeout";
|
|
38259
|
+
default:
|
|
38260
|
+
return;
|
|
38261
|
+
}
|
|
38262
|
+
}
|
|
38263
|
+
function classifyFromErrorCode3(errorCode2) {
|
|
38264
|
+
if (!errorCode2) {
|
|
38265
|
+
return;
|
|
38266
|
+
}
|
|
38267
|
+
if (AUTH_ERROR_CODES3.has(errorCode2)) {
|
|
38268
|
+
return "auth";
|
|
38269
|
+
}
|
|
38270
|
+
if (VALIDATION_ERROR_CODES3.has(errorCode2)) {
|
|
38271
|
+
return "validation";
|
|
38272
|
+
}
|
|
38273
|
+
if (TIMEOUT_ERROR_CODES3.has(errorCode2)) {
|
|
38274
|
+
return "timeout";
|
|
38275
|
+
}
|
|
38276
|
+
if (NETWORK_HTTP_ERROR_CODES3.has(errorCode2)) {
|
|
38277
|
+
return "network_http";
|
|
38278
|
+
}
|
|
38279
|
+
return;
|
|
38280
|
+
}
|
|
38281
|
+
function classifyFromError3(error) {
|
|
38282
|
+
const code = findCodeInCauseChain3(error);
|
|
38283
|
+
if (code) {
|
|
38284
|
+
if (code.startsWith("commander.")) {
|
|
38285
|
+
return "validation";
|
|
38286
|
+
}
|
|
38287
|
+
if (NETWORK_OS_ERROR_CODES3.has(code) || TLS_ERROR_CODES23.has(code)) {
|
|
38288
|
+
return "network_http";
|
|
38289
|
+
}
|
|
38290
|
+
if (TIMEOUT_OS_ERROR_CODES3.has(code)) {
|
|
38291
|
+
return "timeout";
|
|
38292
|
+
}
|
|
38293
|
+
if (MISSING_DEPENDENCY_CODES3.has(code) || isSpawnEnoent3(error)) {
|
|
38294
|
+
return "missing_dependency";
|
|
38295
|
+
}
|
|
38296
|
+
}
|
|
38297
|
+
const message = stringField3(error, "message");
|
|
38298
|
+
if (message?.includes("fetch failed") === true) {
|
|
38299
|
+
return "network_http";
|
|
38300
|
+
}
|
|
38301
|
+
const name = stringField3(error, "name");
|
|
38302
|
+
if (name && INTERNAL_ERROR_NAMES3.has(name)) {
|
|
38303
|
+
return "internal";
|
|
38304
|
+
}
|
|
38305
|
+
return;
|
|
38306
|
+
}
|
|
38307
|
+
function classifyError22(input) {
|
|
38308
|
+
const recorded = input.recordedFailure;
|
|
38309
|
+
if (recorded?.errorClass) {
|
|
38310
|
+
return recorded.errorClass;
|
|
38311
|
+
}
|
|
38312
|
+
const status = recorded?.context?.httpStatus;
|
|
38313
|
+
if (status !== undefined) {
|
|
38314
|
+
return classifyHttpStatus3(status);
|
|
38315
|
+
}
|
|
38316
|
+
return classifyFromResult3(recorded?.result) ?? classifyFromErrorCode3(recorded?.errorCode) ?? classifyFromError3(input.error) ?? "unknown";
|
|
38317
|
+
}
|
|
38318
|
+
function recordCommandFailureTelemetry3(failure) {
|
|
38319
|
+
recordedFailureSlot3.set(failure);
|
|
38320
|
+
}
|
|
38321
|
+
function clearRecordedCommandFailureTelemetry3() {
|
|
38322
|
+
recordedFailureSlot3.clear();
|
|
38323
|
+
}
|
|
38324
|
+
function takeRecordedCommandFailureTelemetry3() {
|
|
38325
|
+
const failure = recordedFailureSlot3.get();
|
|
38326
|
+
recordedFailureSlot3.clear();
|
|
38327
|
+
return failure;
|
|
38328
|
+
}
|
|
38329
|
+
function buildCommandTerminalTelemetryProperties3(input) {
|
|
38330
|
+
const cancelled = isCancellationError3(input.error, input.exitCode, input.pollSignal);
|
|
38331
|
+
const outcome = input.recordedFailure?.terminalOutcome ?? (input.exitCode === 0 ? "success" : cancelled ? "cancelled" : "failure");
|
|
38332
|
+
const errorClass = outcome === "success" || outcome === "no_op" ? undefined : outcome === "cancelled" ? "user_cancelled" : classifyError22(input);
|
|
38333
|
+
const terminalSignal = terminalSignalFor3(input, outcome);
|
|
38334
|
+
return {
|
|
38335
|
+
exit_code: input.exitCode,
|
|
38336
|
+
terminal_outcome: outcome,
|
|
38337
|
+
...errorClass ? { error_class: errorClass } : {},
|
|
38338
|
+
...terminalSignal ? { terminal_signal: terminalSignal } : {}
|
|
38339
|
+
};
|
|
38340
|
+
}
|
|
37616
38341
|
function readRegistryValue3(keyPath, valueName) {
|
|
37617
38342
|
if (process.platform !== "win32") {
|
|
37618
38343
|
return "";
|
|
@@ -37689,6 +38414,69 @@ class DebugTelemetryProvider2 {
|
|
|
37689
38414
|
logger4.debug(`[Telemetry] Dependency: ${name} [${type}] (${duration}ms, ${success ? "ok" : "fail"})`);
|
|
37690
38415
|
}
|
|
37691
38416
|
}
|
|
38417
|
+
function detectAgentFromEnv3(env) {
|
|
38418
|
+
for (const agent of KNOWN_AGENTS3) {
|
|
38419
|
+
const envValue = env[agent.envVar];
|
|
38420
|
+
if (agent.value !== undefined) {
|
|
38421
|
+
if (envValue === agent.value)
|
|
38422
|
+
return agent.id;
|
|
38423
|
+
} else {
|
|
38424
|
+
if (envValue)
|
|
38425
|
+
return agent.id;
|
|
38426
|
+
}
|
|
38427
|
+
}
|
|
38428
|
+
const agentEnv = env.AGENT;
|
|
38429
|
+
if (agentEnv) {
|
|
38430
|
+
if (agentEnv === "1" || agentEnv === "true")
|
|
38431
|
+
return "unknown";
|
|
38432
|
+
if (agentEnv.length <= 32)
|
|
38433
|
+
return agentEnv.toLowerCase();
|
|
38434
|
+
}
|
|
38435
|
+
return;
|
|
38436
|
+
}
|
|
38437
|
+
function currentEnv3() {
|
|
38438
|
+
return typeof process === "undefined" ? {} : process.env;
|
|
38439
|
+
}
|
|
38440
|
+
function currentTtyState3() {
|
|
38441
|
+
if (typeof process === "undefined")
|
|
38442
|
+
return false;
|
|
38443
|
+
return Boolean(process.stdout?.isTTY || process.stdin?.isTTY || process.stderr?.isTTY);
|
|
38444
|
+
}
|
|
38445
|
+
function detectCi3(env) {
|
|
38446
|
+
const signature = CI_SIGNATURES3.find((candidate) => candidate.matches(env));
|
|
38447
|
+
if (!signature)
|
|
38448
|
+
return;
|
|
38449
|
+
return {
|
|
38450
|
+
executionContext: signature.isScheduler?.(env) ? "scheduler" : "ci",
|
|
38451
|
+
ciProvider: signature.provider
|
|
38452
|
+
};
|
|
38453
|
+
}
|
|
38454
|
+
function detectExecutionContext3(options = {}) {
|
|
38455
|
+
const env = options.env ?? currentEnv3();
|
|
38456
|
+
const ci = detectCi3(env);
|
|
38457
|
+
if (ci)
|
|
38458
|
+
return ci;
|
|
38459
|
+
const agent = options.agent ?? detectAgentFromEnv3(env);
|
|
38460
|
+
if (agent) {
|
|
38461
|
+
return { executionContext: "agent" };
|
|
38462
|
+
}
|
|
38463
|
+
const authSignal = options.authSignal ?? authSignalSlot3.get();
|
|
38464
|
+
if (authSignal === "service_account") {
|
|
38465
|
+
return { executionContext: "service_account" };
|
|
38466
|
+
}
|
|
38467
|
+
const isTty = options.isTty ?? currentTtyState3();
|
|
38468
|
+
if (isTty) {
|
|
38469
|
+
return { executionContext: "manual" };
|
|
38470
|
+
}
|
|
38471
|
+
return { executionContext: "unknown" };
|
|
38472
|
+
}
|
|
38473
|
+
function getExecutionContextTelemetryProperties3() {
|
|
38474
|
+
const detected = detectExecutionContext3();
|
|
38475
|
+
return {
|
|
38476
|
+
execution_context: detected.executionContext,
|
|
38477
|
+
...detected.ciProvider ? { ci_provider: detected.ciProvider } : {}
|
|
38478
|
+
};
|
|
38479
|
+
}
|
|
37692
38480
|
|
|
37693
38481
|
class NodeContextStorage3 {
|
|
37694
38482
|
storage = new AsyncLocalStorage3;
|
|
@@ -37699,6 +38487,22 @@ class NodeContextStorage3 {
|
|
|
37699
38487
|
return this.storage.getStore();
|
|
37700
38488
|
}
|
|
37701
38489
|
}
|
|
38490
|
+
function getProcessEnv3() {
|
|
38491
|
+
return globalThis.process?.env;
|
|
38492
|
+
}
|
|
38493
|
+
function normalizeSessionId3(value) {
|
|
38494
|
+
if (typeof value !== "string" && typeof value !== "number" && typeof value !== "boolean") {
|
|
38495
|
+
return;
|
|
38496
|
+
}
|
|
38497
|
+
const trimmed = String(value).trim();
|
|
38498
|
+
return trimmed || undefined;
|
|
38499
|
+
}
|
|
38500
|
+
function getConfiguredTelemetrySessionId3() {
|
|
38501
|
+
return normalizeSessionId3(getProcessEnv3()?.[TELEMETRY_SESSION_ID_ENV3]);
|
|
38502
|
+
}
|
|
38503
|
+
function resolveTelemetrySessionId3(existingSessionId) {
|
|
38504
|
+
return getConfiguredTelemetrySessionId3() ?? normalizeSessionId3(existingSessionId);
|
|
38505
|
+
}
|
|
37702
38506
|
function getGlobalTelemetryProperties3() {
|
|
37703
38507
|
return telemetryPropsSlot3.get();
|
|
37704
38508
|
}
|
|
@@ -37780,12 +38584,22 @@ class TelemetryService3 {
|
|
|
37780
38584
|
return this.contextStorage.getContext();
|
|
37781
38585
|
}
|
|
37782
38586
|
enrichPropertiesWithContext(properties, context) {
|
|
37783
|
-
|
|
37784
|
-
|
|
38587
|
+
const globalProperties = getGlobalTelemetryProperties3();
|
|
38588
|
+
const existingSessionId = properties?.[TELEMETRY_SESSION_ID_PROPERTY3] ?? this.defaultProperties?.[TELEMETRY_SESSION_ID_PROPERTY3] ?? globalProperties?.[TELEMETRY_SESSION_ID_PROPERTY3];
|
|
38589
|
+
const sessionId = resolveTelemetrySessionId3(existingSessionId);
|
|
38590
|
+
const enriched = {
|
|
38591
|
+
...getExecutionContextTelemetryProperties3(),
|
|
38592
|
+
...globalProperties,
|
|
37785
38593
|
...this.defaultProperties,
|
|
37786
38594
|
...properties,
|
|
37787
38595
|
...context
|
|
37788
38596
|
};
|
|
38597
|
+
if (sessionId === undefined) {
|
|
38598
|
+
delete enriched[TELEMETRY_SESSION_ID_PROPERTY3];
|
|
38599
|
+
} else {
|
|
38600
|
+
enriched[TELEMETRY_SESSION_ID_PROPERTY3] = sessionId;
|
|
38601
|
+
}
|
|
38602
|
+
return enriched;
|
|
37789
38603
|
}
|
|
37790
38604
|
generateId() {
|
|
37791
38605
|
return crypto.randomUUID().replaceAll("-", "");
|
|
@@ -38167,6 +38981,81 @@ function defaultRetryForErrorCode3(errorCode2) {
|
|
|
38167
38981
|
return "RetryWillNotFix";
|
|
38168
38982
|
}
|
|
38169
38983
|
}
|
|
38984
|
+
function productMode3(productArea, mode) {
|
|
38985
|
+
return { product_area: productArea, mode };
|
|
38986
|
+
}
|
|
38987
|
+
function attributionRecord3(groups) {
|
|
38988
|
+
const record = {};
|
|
38989
|
+
for (const [productArea, mode, names] of groups) {
|
|
38990
|
+
const attribution = productMode3(productArea, mode);
|
|
38991
|
+
for (const name of names) {
|
|
38992
|
+
record[name] = attribution;
|
|
38993
|
+
}
|
|
38994
|
+
}
|
|
38995
|
+
return record;
|
|
38996
|
+
}
|
|
38997
|
+
function commandAttribution3(groups) {
|
|
38998
|
+
const entries = [];
|
|
38999
|
+
for (const [productArea, mode, prefixes] of groups) {
|
|
39000
|
+
const attribution = productMode3(productArea, mode);
|
|
39001
|
+
for (const prefix of prefixes) {
|
|
39002
|
+
entries.push({ prefix, attribution });
|
|
39003
|
+
}
|
|
39004
|
+
}
|
|
39005
|
+
return entries;
|
|
39006
|
+
}
|
|
39007
|
+
function normalizeCommandPath3(value) {
|
|
39008
|
+
if (typeof value !== "string") {
|
|
39009
|
+
return;
|
|
39010
|
+
}
|
|
39011
|
+
const trimmed = value.trim().toLowerCase();
|
|
39012
|
+
if (!trimmed) {
|
|
39013
|
+
return;
|
|
39014
|
+
}
|
|
39015
|
+
const tokens = trimmed.includes(" ") ? trimmed.split(/\s+/).filter((token) => token.length > 0).filter((token) => !token.startsWith("-")) : trimmed.split(".").filter((token) => token.length > 0);
|
|
39016
|
+
if (tokens.length === 0) {
|
|
39017
|
+
return;
|
|
39018
|
+
}
|
|
39019
|
+
const commandTokens = tokens[0] === "uip" ? tokens : ["uip", ...tokens];
|
|
39020
|
+
return commandTokens.join(".");
|
|
39021
|
+
}
|
|
39022
|
+
function getCommandProductModeAttribution3(commandPath) {
|
|
39023
|
+
const normalized = normalizeCommandPath3(commandPath);
|
|
39024
|
+
if (!normalized) {
|
|
39025
|
+
return;
|
|
39026
|
+
}
|
|
39027
|
+
return COMMAND_ATTRIBUTION3.find(({ prefix }) => normalized === prefix || normalized.startsWith(`${prefix}.`))?.attribution;
|
|
39028
|
+
}
|
|
39029
|
+
function normalizeSkillNameWithOptions3(value, options) {
|
|
39030
|
+
if (typeof value !== "string") {
|
|
39031
|
+
return;
|
|
39032
|
+
}
|
|
39033
|
+
const normalized = value.trim().toLowerCase();
|
|
39034
|
+
if (!normalized) {
|
|
39035
|
+
return;
|
|
39036
|
+
}
|
|
39037
|
+
const hasLegacyNamespace = normalized.startsWith(LEGACY_SKILL_NAMESPACE3);
|
|
39038
|
+
if (hasLegacyNamespace && !options.allowLegacyNamespace) {
|
|
39039
|
+
return;
|
|
39040
|
+
}
|
|
39041
|
+
const skillName = hasLegacyNamespace ? normalized.slice(LEGACY_SKILL_NAMESPACE3.length) : normalized;
|
|
39042
|
+
if (skillName.length > MAX_SKILL_NAME_LENGTH3 || !SKILL_NAME_PATTERN3.test(skillName) || !KNOWN_SKILL_NAMES3.has(skillName)) {
|
|
39043
|
+
return;
|
|
39044
|
+
}
|
|
39045
|
+
return skillName;
|
|
39046
|
+
}
|
|
39047
|
+
function normalizeSkillName3(value) {
|
|
39048
|
+
return normalizeSkillNameWithOptions3(value, {
|
|
39049
|
+
allowLegacyNamespace: false
|
|
39050
|
+
});
|
|
39051
|
+
}
|
|
39052
|
+
function buildCommandTelemetryAttribution3(commandPath, skillSource) {
|
|
39053
|
+
const skillName = normalizeSkillName3(skillSource);
|
|
39054
|
+
return {
|
|
39055
|
+
...skillName ? { skill_name: skillName } : {},
|
|
39056
|
+
...getCommandProductModeAttribution3(commandPath)
|
|
39057
|
+
};
|
|
39058
|
+
}
|
|
38170
39059
|
function shortHash3(input) {
|
|
38171
39060
|
let hash = 2166136261;
|
|
38172
39061
|
for (let i2 = 0;i2 < input.length; i2++) {
|
|
@@ -38293,6 +39182,12 @@ function commandHelpHint3(commandPath) {
|
|
|
38293
39182
|
const command = commandPath.replace(/\./g, " ");
|
|
38294
39183
|
return `An unexpected error occurred. Run '${command} --help' to verify command syntax, or run with --log-level debug for details.`;
|
|
38295
39184
|
}
|
|
39185
|
+
function isPromptCancellation3(error) {
|
|
39186
|
+
return error instanceof Error && error.name === "ExitPromptError";
|
|
39187
|
+
}
|
|
39188
|
+
function exitCodeFromProcess3(fallback) {
|
|
39189
|
+
return typeof process.exitCode === "number" ? process.exitCode : fallback;
|
|
39190
|
+
}
|
|
38296
39191
|
function isPreviewBuild3() {
|
|
38297
39192
|
return previewSlot3.get(false) ?? false;
|
|
38298
39193
|
}
|
|
@@ -39955,7 +40850,7 @@ var de_default2, en4, es_default2, es_MX_default2, fr_default2, ja_default2, ko_
|
|
|
39955
40850
|
...options,
|
|
39956
40851
|
target
|
|
39957
40852
|
});
|
|
39958
|
-
}, apps4, open_default4, LOCK_HEARTBEAT_MS4 = 5000, LOCK_STALE_MS4 = 15000, LOCK_MAX_WAIT_MS5 = 20000, LOCK_MAX_HOLD_MS4 = 60000, LOCK_RETRY_MIN_MS4 = 100, LOCK_RETRY_JITTER_MS4 = 200, fsInstance4, getFileSystem3 = () => fsInstance4, NETWORK_ERROR_CODES3,
|
|
40853
|
+
}, apps4, open_default4, LOCK_HEARTBEAT_MS4 = 5000, LOCK_STALE_MS4 = 15000, LOCK_MAX_WAIT_MS5 = 20000, LOCK_MAX_HOLD_MS4 = 60000, LOCK_RETRY_MIN_MS4 = 100, LOCK_RETRY_JITTER_MS4 = 200, fsInstance4, getFileSystem3 = () => fsInstance4, NETWORK_ERROR_CODES3, TLS_ERROR_CODES4, TLS_INSTRUCTIONS3, NETWORK_INSTRUCTIONS3, import__4, program3, createCommand3, createArgument3, createOption3, CommanderError3, InvalidArgumentError3, InvalidOptionArgumentError3, Command3, Argument3, Option3, Help3, examplesByCommand3, PREFIX3 = "@uipath/common/", _g3, storageSingleton3, sinkSlot3, outputStorage3, CONSOLE_FALLBACK3, COMPLETER_SYMBOL3, isObject3 = (obj) => {
|
|
39959
40854
|
return obj !== null && Object.prototype.toString.call(obj) === "[object Object]";
|
|
39960
40855
|
}, strictDeepEqual3 = (first, second) => {
|
|
39961
40856
|
if (first === second) {
|
|
@@ -41806,7 +42701,7 @@ var de_default2, en4, es_default2, es_MX_default2, fr_default2, ja_default2, ko_
|
|
|
41806
42701
|
}, __toESM23 = (mod22, isNodeMode, target) => (target = mod22 != null ? __create23(__getProtoOf23(mod22)) : {}, __copyProps3(isNodeMode || !mod22 || !mod22.__esModule ? __defProp23(target, "default", {
|
|
41807
42702
|
value: mod22,
|
|
41808
42703
|
enumerable: true
|
|
41809
|
-
}) : target, mod22)), require_common3, require_exception3, require_snippet3, require_type3, require_schema3, require_str3, require_seq3, require_map4, require_failsafe3, require_null3, require_bool3, require_int3, require_float3, require_json3, require_core3, require_timestamp3, require_merge4, require_binary3, require_omap3, require_pairs4, require_set3, require_default3, require_loader3, require_dumper3, import_js_yaml3, Type3, Schema3, FAILSAFE_SCHEMA3, JSON_SCHEMA3, CORE_SCHEMA3, DEFAULT_SCHEMA3, load3, loadAll3, dump3, YAMLException3, types3, safeLoad3, safeLoadAll3, safeDump3, index_vite_proxy_tmp_default3, logFilePathSlot3, LogLevel4, DEFAULT_LOG_LEVEL3 = 3, SimpleLogger3, loggerSingleton3, logger4, formatSlot3, formatExplicitSlot3, filterSlot3, CommonTelemetryEvents3, telemetryPropsSlot3, providerSlot3, telemetryInstanceSlot3, DEFAULT_AI_CONNECTION_STRING3, _localTelemetryInstance3, telemetry3, CLI_ERROR_CODES3, RETRY_HINTS3, RESULTS3, EXIT_CODES3, FilterEvaluationError3, OutputFormatter3, REDACTED3 = "[REDACTED]", MAX_VALUE_LENGTH3 = 200, SENSITIVE_NAME_TOKENS3, SENSITIVE_KEY_PREFIXES3, UUID_PATTERN3, EMAIL_PATTERN3, JWT_PATTERN3, LONG_TOKEN_PATTERN3, USER_HOME_PATTERN3, URL_PATTERN3, URL_TRAILING_PUNCT3, pollSignalSlot3, cliErrorCodeValues3, retryHintValues3, guardInstalledSlot3, savedOriginalsSlot3, DEFAULT_AUTH_TIMEOUT_MS4, modeSlot3, PollOutcome3, REASON_BY_OUTCOME3, TERMINAL_STATUSES3, FAILURE_STATUSES3, previewSlot3, ScreenLogger3, USER_AGENT_HEADER3 = "User-Agent", sdkUserAgentHostToken3, factorySlot3, globalLogHandler2 = (logMessage) => {
|
|
42704
|
+
}) : target, mod22)), require_common3, require_exception3, require_snippet3, require_type3, require_schema3, require_str3, require_seq3, require_map4, require_failsafe3, require_null3, require_bool3, require_int3, require_float3, require_json3, require_core3, require_timestamp3, require_merge4, require_binary3, require_omap3, require_pairs4, require_set3, require_default3, require_loader3, require_dumper3, import_js_yaml3, Type3, Schema3, FAILSAFE_SCHEMA3, JSON_SCHEMA3, CORE_SCHEMA3, DEFAULT_SCHEMA3, load3, loadAll3, dump3, YAMLException3, types3, safeLoad3, safeLoadAll3, safeDump3, index_vite_proxy_tmp_default3, logFilePathSlot3, LogLevel4, DEFAULT_LOG_LEVEL3 = 3, SimpleLogger3, loggerSingleton3, logger4, formatSlot3, formatExplicitSlot3, filterSlot3, recordedFailureSlot3, AUTH_ERROR_CODES3, VALIDATION_ERROR_CODES3, NETWORK_HTTP_ERROR_CODES3, TIMEOUT_ERROR_CODES3, NETWORK_OS_ERROR_CODES3, TIMEOUT_OS_ERROR_CODES3, TLS_ERROR_CODES23, MISSING_DEPENDENCY_CODES3, INTERNAL_ERROR_NAMES3, CommonTelemetryEvents3, KNOWN_AGENTS3, LOCAL_HOSTS3, authSignalSlot3, isTruthy3 = (value) => value !== undefined && value !== "" && value !== "0" && value.toLowerCase() !== "false", isEqual3 = (value, expected) => value?.toLowerCase() === expected, CI_SIGNATURES3, TELEMETRY_SESSION_ID_ENV3 = "UIPATH_SESSION_ID", TELEMETRY_SESSION_ID_PROPERTY3 = "session_id", telemetrySessionIdSlot3, telemetryPropsSlot3, providerSlot3, telemetryInstanceSlot3, DEFAULT_AI_CONNECTION_STRING3, _localTelemetryInstance3, telemetry3, CLI_ERROR_CODES3, RETRY_HINTS3, RESULTS3, EXIT_CODES3, FilterEvaluationError3, OutputFormatter3, LEGACY_SKILL_NAMESPACE3 = "uipath:", MAX_SKILL_NAME_LENGTH3 = 80, SKILL_NAME_PATTERN3, SKILL_ATTRIBUTION3, KNOWN_SKILL_NAMES3, COMMAND_ATTRIBUTION3, REDACTED3 = "[REDACTED]", MAX_VALUE_LENGTH3 = 200, SENSITIVE_NAME_TOKENS3, SENSITIVE_KEY_PREFIXES3, UUID_PATTERN3, EMAIL_PATTERN3, JWT_PATTERN3, LONG_TOKEN_PATTERN3, USER_HOME_PATTERN3, URL_PATTERN3, URL_TRAILING_PUNCT3, pollSignalSlot3, cliErrorCodeValues3, retryHintValues3, guardInstalledSlot3, savedOriginalsSlot3, DEFAULT_AUTH_TIMEOUT_MS4, modeSlot3, PollOutcome3, REASON_BY_OUTCOME3, TERMINAL_STATUSES3, FAILURE_STATUSES3, previewSlot3, ScreenLogger3, USER_AGENT_HEADER3 = "User-Agent", sdkUserAgentHostToken3, shippedKeysSlot3, factorySlot3, globalLogHandler2 = (logMessage) => {
|
|
41810
42705
|
const formattedMessage = logMessage.toFormattedString();
|
|
41811
42706
|
switch (logMessage.logLevel) {
|
|
41812
42707
|
case LogLevel2.Debug:
|
|
@@ -45281,7 +46176,7 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
45281
46176
|
"ENETUNREACH",
|
|
45282
46177
|
"EAI_FAIL"
|
|
45283
46178
|
]);
|
|
45284
|
-
|
|
46179
|
+
TLS_ERROR_CODES4 = new Set([
|
|
45285
46180
|
"SELF_SIGNED_CERT_IN_CHAIN",
|
|
45286
46181
|
"DEPTH_ZERO_SELF_SIGNED_CERT",
|
|
45287
46182
|
"UNABLE_TO_VERIFY_LEAF_SIGNATURE",
|
|
@@ -48327,9 +49222,118 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
48327
49222
|
formatSlot3 = singleton4("OutputFormat");
|
|
48328
49223
|
formatExplicitSlot3 = singleton4("OutputFormatExplicit");
|
|
48329
49224
|
filterSlot3 = singleton4("OutputFilter");
|
|
49225
|
+
recordedFailureSlot3 = singleton4("CommandTelemetryFailure");
|
|
49226
|
+
AUTH_ERROR_CODES3 = new Set([
|
|
49227
|
+
"authentication_required",
|
|
49228
|
+
"permission_denied"
|
|
49229
|
+
]);
|
|
49230
|
+
VALIDATION_ERROR_CODES3 = new Set(["invalid_argument"]);
|
|
49231
|
+
NETWORK_HTTP_ERROR_CODES3 = new Set([
|
|
49232
|
+
"network_error",
|
|
49233
|
+
"rate_limited",
|
|
49234
|
+
"server_error",
|
|
49235
|
+
"not_found",
|
|
49236
|
+
"method_not_allowed"
|
|
49237
|
+
]);
|
|
49238
|
+
TIMEOUT_ERROR_CODES3 = new Set(["timeout"]);
|
|
49239
|
+
NETWORK_OS_ERROR_CODES3 = new Set([
|
|
49240
|
+
"ECONNREFUSED",
|
|
49241
|
+
"ECONNRESET",
|
|
49242
|
+
"ENOTFOUND",
|
|
49243
|
+
"EAI_AGAIN",
|
|
49244
|
+
"EPIPE",
|
|
49245
|
+
"EHOSTUNREACH",
|
|
49246
|
+
"ENETUNREACH",
|
|
49247
|
+
"EAI_FAIL"
|
|
49248
|
+
]);
|
|
49249
|
+
TIMEOUT_OS_ERROR_CODES3 = new Set(["ETIMEDOUT", "ESOCKETTIMEDOUT"]);
|
|
49250
|
+
TLS_ERROR_CODES23 = new Set([
|
|
49251
|
+
"SELF_SIGNED_CERT_IN_CHAIN",
|
|
49252
|
+
"DEPTH_ZERO_SELF_SIGNED_CERT",
|
|
49253
|
+
"UNABLE_TO_VERIFY_LEAF_SIGNATURE",
|
|
49254
|
+
"UNABLE_TO_GET_ISSUER_CERT_LOCALLY",
|
|
49255
|
+
"UNABLE_TO_GET_ISSUER_CERT",
|
|
49256
|
+
"CERT_HAS_EXPIRED",
|
|
49257
|
+
"CERT_UNTRUSTED",
|
|
49258
|
+
"ERR_TLS_CERT_ALTNAME_INVALID"
|
|
49259
|
+
]);
|
|
49260
|
+
MISSING_DEPENDENCY_CODES3 = new Set([
|
|
49261
|
+
"MODULE_NOT_FOUND",
|
|
49262
|
+
"ERR_MODULE_NOT_FOUND"
|
|
49263
|
+
]);
|
|
49264
|
+
INTERNAL_ERROR_NAMES3 = new Set([
|
|
49265
|
+
"TypeError",
|
|
49266
|
+
"ReferenceError",
|
|
49267
|
+
"SyntaxError",
|
|
49268
|
+
"RangeError"
|
|
49269
|
+
]);
|
|
48330
49270
|
CommonTelemetryEvents3 = {
|
|
48331
|
-
Error: "uip.error"
|
|
48332
|
-
|
|
49271
|
+
Error: "uip.error",
|
|
49272
|
+
ShipSucceeded: "ship_succeeded"
|
|
49273
|
+
};
|
|
49274
|
+
KNOWN_AGENTS3 = [
|
|
49275
|
+
{ envVar: "CLAUDECODE", value: "1", id: "claude-code" },
|
|
49276
|
+
{ envVar: "CURSOR_AGENT", value: "1", id: "cursor" },
|
|
49277
|
+
{ envVar: "GEMINI_CLI", value: "1", id: "gemini-cli" },
|
|
49278
|
+
{ envVar: "CODEX_THREAD_ID", id: "codex" },
|
|
49279
|
+
{ envVar: "CODEX_SANDBOX", id: "codex" },
|
|
49280
|
+
{ envVar: "AUGMENT_AGENT", value: "1", id: "augment" },
|
|
49281
|
+
{ envVar: "CLINE_ACTIVE", value: "true", id: "cline" }
|
|
49282
|
+
];
|
|
49283
|
+
LOCAL_HOSTS3 = new Set(["localhost", "127.0.0.1", "::1", "[::1]"]);
|
|
49284
|
+
authSignalSlot3 = singleton4("TelemetryExecutionContextAuthSignal");
|
|
49285
|
+
CI_SIGNATURES3 = [
|
|
49286
|
+
{
|
|
49287
|
+
provider: "github_actions",
|
|
49288
|
+
matches: (env) => isTruthy3(env.GITHUB_ACTIONS),
|
|
49289
|
+
isScheduler: (env) => env.GITHUB_EVENT_NAME === "schedule"
|
|
49290
|
+
},
|
|
49291
|
+
{
|
|
49292
|
+
provider: "azure_devops",
|
|
49293
|
+
matches: (env) => isTruthy3(env.TF_BUILD),
|
|
49294
|
+
isScheduler: (env) => isEqual3(env.BUILD_REASON, "schedule")
|
|
49295
|
+
},
|
|
49296
|
+
{
|
|
49297
|
+
provider: "gitlab",
|
|
49298
|
+
matches: (env) => isTruthy3(env.GITLAB_CI),
|
|
49299
|
+
isScheduler: (env) => env.CI_PIPELINE_SOURCE === "schedule"
|
|
49300
|
+
},
|
|
49301
|
+
{
|
|
49302
|
+
provider: "circleci",
|
|
49303
|
+
matches: (env) => isTruthy3(env.CIRCLECI),
|
|
49304
|
+
isScheduler: (env) => env.CIRCLE_PIPELINE_TRIGGER_SOURCE === "scheduled_pipeline"
|
|
49305
|
+
},
|
|
49306
|
+
{
|
|
49307
|
+
provider: "jenkins",
|
|
49308
|
+
matches: (env) => isTruthy3(env.JENKINS_URL) || isTruthy3(env.JENKINS_HOME)
|
|
49309
|
+
},
|
|
49310
|
+
{
|
|
49311
|
+
provider: "teamcity",
|
|
49312
|
+
matches: (env) => isTruthy3(env.TEAMCITY_VERSION)
|
|
49313
|
+
},
|
|
49314
|
+
{
|
|
49315
|
+
provider: "buildkite",
|
|
49316
|
+
matches: (env) => isTruthy3(env.BUILDKITE),
|
|
49317
|
+
isScheduler: (env) => env.BUILDKITE_SOURCE === "schedule"
|
|
49318
|
+
},
|
|
49319
|
+
{
|
|
49320
|
+
provider: "bitbucket",
|
|
49321
|
+
matches: (env) => isTruthy3(env.BITBUCKET_BUILD_NUMBER)
|
|
49322
|
+
},
|
|
49323
|
+
{
|
|
49324
|
+
provider: "travis",
|
|
49325
|
+
matches: (env) => isTruthy3(env.TRAVIS)
|
|
49326
|
+
},
|
|
49327
|
+
{
|
|
49328
|
+
provider: "appveyor",
|
|
49329
|
+
matches: (env) => isTruthy3(env.APPVEYOR)
|
|
49330
|
+
},
|
|
49331
|
+
{
|
|
49332
|
+
provider: "generic",
|
|
49333
|
+
matches: (env) => isTruthy3(env.CI)
|
|
49334
|
+
}
|
|
49335
|
+
];
|
|
49336
|
+
telemetrySessionIdSlot3 = singleton4("TelemetrySessionId");
|
|
48333
49337
|
telemetryPropsSlot3 = singleton4("TelemetryDefaultProps");
|
|
48334
49338
|
providerSlot3 = singleton4("TelemetryProvider");
|
|
48335
49339
|
telemetryInstanceSlot3 = singleton4("TelemetryService");
|
|
@@ -48413,8 +49417,24 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
48413
49417
|
data.ErrorCode ??= defaultErrorCodeForFailure3(data);
|
|
48414
49418
|
data.Retry ??= defaultRetryForErrorCode3(data.ErrorCode);
|
|
48415
49419
|
process.exitCode = EXIT_CODES3[data.Result] ?? 1;
|
|
48416
|
-
|
|
48417
|
-
|
|
49420
|
+
recordCommandFailureTelemetry3({
|
|
49421
|
+
result: data.Result,
|
|
49422
|
+
errorCode: data.ErrorCode,
|
|
49423
|
+
retry: data.Retry,
|
|
49424
|
+
message: data.Message,
|
|
49425
|
+
context: data.Context,
|
|
49426
|
+
exitCode: process.exitCode,
|
|
49427
|
+
errorClass: data.TelemetryErrorClass,
|
|
49428
|
+
terminalOutcome: data.TelemetryTerminalOutcome,
|
|
49429
|
+
terminalSignal: data.TelemetryTerminalSignal
|
|
49430
|
+
});
|
|
49431
|
+
const suppressTelemetry = data.SuppressTelemetry === true;
|
|
49432
|
+
const envelope = { ...data };
|
|
49433
|
+
delete envelope.SuppressTelemetry;
|
|
49434
|
+
delete envelope.TelemetryErrorClass;
|
|
49435
|
+
delete envelope.TelemetryTerminalOutcome;
|
|
49436
|
+
delete envelope.TelemetryTerminalSignal;
|
|
49437
|
+
if (!suppressTelemetry) {
|
|
48418
49438
|
telemetry3.trackEvent(CommonTelemetryEvents3.Error, {
|
|
48419
49439
|
result: data.Result,
|
|
48420
49440
|
errorCode: data.ErrorCode,
|
|
@@ -48476,6 +49496,79 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
48476
49496
|
}
|
|
48477
49497
|
OutputFormatter22.formatToString = formatToString;
|
|
48478
49498
|
})(OutputFormatter3 ||= {});
|
|
49499
|
+
SKILL_NAME_PATTERN3 = /^[a-z0-9][a-z0-9-]*[a-z0-9]$/;
|
|
49500
|
+
SKILL_ATTRIBUTION3 = attributionRecord3([
|
|
49501
|
+
["admin", "operate", ["uipath-admin"]],
|
|
49502
|
+
["agents", "build", ["uipath-agents"]],
|
|
49503
|
+
["api-workflow", "build", ["uipath-api-workflow"]],
|
|
49504
|
+
["automation-discovery", "build", ["uipath-automation-discovery"]],
|
|
49505
|
+
["coded-apps", "build", ["uipath-coded-apps"]],
|
|
49506
|
+
["data-fabric", "operate", ["uipath-data-fabric"]],
|
|
49507
|
+
["cli", "troubleshoot", ["uipath-feedback"]],
|
|
49508
|
+
["governance", "operate", ["uipath-governance"]],
|
|
49509
|
+
["action-center", "build", ["uipath-human-in-the-loop"]],
|
|
49510
|
+
["document-understanding", "build", ["uipath-ixp"]],
|
|
49511
|
+
[
|
|
49512
|
+
"maestro",
|
|
49513
|
+
"build",
|
|
49514
|
+
["uipath-maestro-bpmn", "uipath-maestro-case", "uipath-maestro-flow"]
|
|
49515
|
+
],
|
|
49516
|
+
["agenthub", "build", ["uipath-mcp-servers"]],
|
|
49517
|
+
["solution", "build", ["uipath-planner", "uipath-solution"]],
|
|
49518
|
+
["platform", "operate", ["uipath-platform"]],
|
|
49519
|
+
["quality", "troubleshoot", ["uipath-review"]],
|
|
49520
|
+
["rpa", "build", ["uipath-rpa"]],
|
|
49521
|
+
["cli", "operate", ["uipath-skill-catalog"]],
|
|
49522
|
+
["action-center", "operate", ["uipath-tasks"]],
|
|
49523
|
+
["test-manager", "operate", ["uipath-test"]],
|
|
49524
|
+
["platform", "troubleshoot", ["uipath-troubleshoot"]]
|
|
49525
|
+
]);
|
|
49526
|
+
KNOWN_SKILL_NAMES3 = new Set(Object.keys(SKILL_ATTRIBUTION3));
|
|
49527
|
+
COMMAND_ATTRIBUTION3 = commandAttribution3([
|
|
49528
|
+
["cli", "troubleshoot", ["uip.feedback"]],
|
|
49529
|
+
["llm-gateway", "operate", ["uip.llm-configuration", "uip.model-hub"]],
|
|
49530
|
+
["context-grounding", "build", ["uip.context-grounding"]],
|
|
49531
|
+
["api-workflow", "build", ["uip.api-workflow"]],
|
|
49532
|
+
["rpa", "build", ["uip.rpa-legacy"]],
|
|
49533
|
+
["conversational", "operate", ["uip.conversational"]],
|
|
49534
|
+
["agents", "build", ["uip.codedagent", "uip.agent"]],
|
|
49535
|
+
["agenthub", "build", ["uip.agenthub"]],
|
|
49536
|
+
["coded-apps", "build", ["uip.codedapp"]],
|
|
49537
|
+
["functions", "build", ["uip.functions"]],
|
|
49538
|
+
["solution", "build", ["uip.solution"]],
|
|
49539
|
+
["maestro", "build", ["uip.maestro", "uip.case", "uip.flow"]],
|
|
49540
|
+
["llm-observability", "troubleshoot", ["uip.traces"]],
|
|
49541
|
+
["platform", "operate", ["uip.platform"]],
|
|
49542
|
+
["admin", "operate", ["uip.admin"]],
|
|
49543
|
+
["automation-ops", "operate", ["uip.aops"]],
|
|
49544
|
+
["documentation", "troubleshoot", ["uip.docsai"]],
|
|
49545
|
+
["governance", "operate", ["uip.gov"]],
|
|
49546
|
+
["insights", "operate", ["uip.insights"]],
|
|
49547
|
+
["document-understanding", "build", ["uip.ixp"]],
|
|
49548
|
+
["process-mining", "operate", ["uip.pm"]],
|
|
49549
|
+
["action-center", "operate", ["uip.tasks"]],
|
|
49550
|
+
["test-manager", "operate", ["uip.tm"]],
|
|
49551
|
+
["vertical-solutions", "build", ["uip.vss"]],
|
|
49552
|
+
["data-fabric", "operate", ["uip.df"]],
|
|
49553
|
+
["integration-service", "build", ["uip.is"]],
|
|
49554
|
+
["orchestrator", "operate", ["uip.or"]],
|
|
49555
|
+
[
|
|
49556
|
+
"cli",
|
|
49557
|
+
"operate",
|
|
49558
|
+
[
|
|
49559
|
+
"uip.login",
|
|
49560
|
+
"uip.logout",
|
|
49561
|
+
"uip.user",
|
|
49562
|
+
"uip.config",
|
|
49563
|
+
"uip.tools",
|
|
49564
|
+
"uip.skills",
|
|
49565
|
+
"uip.completion",
|
|
49566
|
+
"uip.update",
|
|
49567
|
+
"uip.mcp",
|
|
49568
|
+
"uip.track"
|
|
49569
|
+
]
|
|
49570
|
+
]
|
|
49571
|
+
]).sort((a, b) => b.prefix.length - a.prefix.length);
|
|
48479
49572
|
SENSITIVE_NAME_TOKENS3 = new Set([
|
|
48480
49573
|
"token",
|
|
48481
49574
|
"tokens",
|
|
@@ -48529,6 +49622,8 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
48529
49622
|
const props = typeof properties === "function" ? properties(...args) : properties;
|
|
48530
49623
|
const startTime = performance.now();
|
|
48531
49624
|
let errorMessage3;
|
|
49625
|
+
let fallbackExitCode = EXIT_CODES3.Success;
|
|
49626
|
+
clearRecordedCommandFailureTelemetry3();
|
|
48532
49627
|
const [error] = await catchError4(fn(...args));
|
|
48533
49628
|
if (error) {
|
|
48534
49629
|
errorMessage3 = error instanceof Error ? error.message : String(error);
|
|
@@ -48543,6 +49638,8 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
48543
49638
|
const customRetry = isRetryHint3(typedRetry) ? typedRetry : undefined;
|
|
48544
49639
|
const typedContext = typed.context ?? typed.Context;
|
|
48545
49640
|
const customContext = isErrorContext3(typedContext) ? typedContext : undefined;
|
|
49641
|
+
const cancellationExitCode = typed.exitCode === 130 || isPromptCancellation3(error) ? 130 : undefined;
|
|
49642
|
+
fallbackExitCode = cancellationExitCode ?? EXIT_CODES3[finalResult];
|
|
48546
49643
|
OutputFormatter3.error({
|
|
48547
49644
|
Result: finalResult,
|
|
48548
49645
|
...customErrorCode ? { ErrorCode: customErrorCode } : {},
|
|
@@ -48551,16 +49648,26 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
48551
49648
|
...customRetry ? { Retry: customRetry } : {},
|
|
48552
49649
|
...customContext ? { Context: customContext } : {}
|
|
48553
49650
|
});
|
|
48554
|
-
context.exit(
|
|
49651
|
+
context.exit(fallbackExitCode);
|
|
48555
49652
|
}
|
|
48556
49653
|
const durationMs = performance.now() - startTime;
|
|
48557
|
-
const
|
|
49654
|
+
const exitCode = fallbackExitCode === 130 ? fallbackExitCode : exitCodeFromProcess3(fallbackExitCode);
|
|
49655
|
+
const recordedFailure = takeRecordedCommandFailureTelemetry3();
|
|
49656
|
+
const success = !error && exitCode === 0;
|
|
49657
|
+
const terminalTelemetry = buildCommandTerminalTelemetryProperties3({
|
|
49658
|
+
error,
|
|
49659
|
+
exitCode,
|
|
49660
|
+
recordedFailure,
|
|
49661
|
+
pollSignal: context.pollSignal
|
|
49662
|
+
});
|
|
48558
49663
|
telemetry3.trackEvent(telemetryName, redactProperties3({
|
|
48559
49664
|
...extractCommandParams3(command),
|
|
48560
49665
|
...props,
|
|
49666
|
+
...buildCommandTelemetryAttribution3(telemetryName, process.env.UIPATH_SKILL),
|
|
48561
49667
|
command: "true",
|
|
48562
49668
|
duration: String(durationMs),
|
|
48563
49669
|
success: String(success),
|
|
49670
|
+
...terminalTelemetry,
|
|
48564
49671
|
...errorMessage3 ? { errorMessage: errorMessage3 } : {}
|
|
48565
49672
|
}));
|
|
48566
49673
|
});
|
|
@@ -48614,6 +49721,7 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
48614
49721
|
ScreenLogger22.progress = progress;
|
|
48615
49722
|
})(ScreenLogger3 ||= {});
|
|
48616
49723
|
sdkUserAgentHostToken3 = singleton4("SdkUserAgentHostToken");
|
|
49724
|
+
shippedKeysSlot3 = singleton4("ShipSucceededDedupeKeys");
|
|
48617
49725
|
factorySlot3 = singleton4("PackagerFactoryProvider");
|
|
48618
49726
|
((RulesConfigFileType22) => {
|
|
48619
49727
|
RulesConfigFileType22["Default"] = "Default";
|
|
@@ -48723,7 +49831,7 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
48723
49831
|
package_default3 = {
|
|
48724
49832
|
name: "@uipath/project-packager",
|
|
48725
49833
|
license: "MIT",
|
|
48726
|
-
version: "1.197.0-preview.
|
|
49834
|
+
version: "1.197.0-preview.67",
|
|
48727
49835
|
description: "UiPath Project Packager - core library for packing individual UiPath projects",
|
|
48728
49836
|
type: "module",
|
|
48729
49837
|
main: "./dist/index.js",
|
|
@@ -49047,7 +50155,7 @@ var init_package = __esm(() => {
|
|
|
49047
50155
|
package_default4 = {
|
|
49048
50156
|
name: "@uipath/project-packager",
|
|
49049
50157
|
license: "MIT",
|
|
49050
|
-
version: "1.197.0-preview.
|
|
50158
|
+
version: "1.197.0-preview.67",
|
|
49051
50159
|
description: "UiPath Project Packager - core library for packing individual UiPath projects",
|
|
49052
50160
|
type: "module",
|
|
49053
50161
|
main: "./dist/index.js",
|
|
@@ -67814,8 +68922,8 @@ var require_sequenceEqual = __commonJS((exports) => {
|
|
|
67814
68922
|
return lift_1.operate(function(source, subscriber) {
|
|
67815
68923
|
var aState = createState();
|
|
67816
68924
|
var bState = createState();
|
|
67817
|
-
var emit = function(
|
|
67818
|
-
subscriber.next(
|
|
68925
|
+
var emit = function(isEqual4) {
|
|
68926
|
+
subscriber.next(isEqual4);
|
|
67819
68927
|
subscriber.complete();
|
|
67820
68928
|
};
|
|
67821
68929
|
var createSubscriber = function(selfState, otherState) {
|
|
@@ -78493,7 +79601,7 @@ import"./packager-tool.js";
|
|
|
78493
79601
|
var package_default = {
|
|
78494
79602
|
name: "@uipath/api-workflow-tool",
|
|
78495
79603
|
license: "MIT",
|
|
78496
|
-
version: "1.197.0-preview.
|
|
79604
|
+
version: "1.197.0-preview.67",
|
|
78497
79605
|
description: "Run UiPath API Workflows locally.",
|
|
78498
79606
|
private: false,
|
|
78499
79607
|
repository: {
|
|
@@ -83595,9 +84703,228 @@ function getOutputFilter() {
|
|
|
83595
84703
|
return filterSlot.get();
|
|
83596
84704
|
}
|
|
83597
84705
|
|
|
84706
|
+
// ../common/src/telemetry/command-terminal.ts
|
|
84707
|
+
var recordedFailureSlot = singleton("CommandTelemetryFailure");
|
|
84708
|
+
var AUTH_ERROR_CODES = new Set([
|
|
84709
|
+
"authentication_required",
|
|
84710
|
+
"permission_denied"
|
|
84711
|
+
]);
|
|
84712
|
+
var VALIDATION_ERROR_CODES = new Set(["invalid_argument"]);
|
|
84713
|
+
var NETWORK_HTTP_ERROR_CODES = new Set([
|
|
84714
|
+
"network_error",
|
|
84715
|
+
"rate_limited",
|
|
84716
|
+
"server_error",
|
|
84717
|
+
"not_found",
|
|
84718
|
+
"method_not_allowed"
|
|
84719
|
+
]);
|
|
84720
|
+
var TIMEOUT_ERROR_CODES = new Set(["timeout"]);
|
|
84721
|
+
var NETWORK_OS_ERROR_CODES = new Set([
|
|
84722
|
+
"ECONNREFUSED",
|
|
84723
|
+
"ECONNRESET",
|
|
84724
|
+
"ENOTFOUND",
|
|
84725
|
+
"EAI_AGAIN",
|
|
84726
|
+
"EPIPE",
|
|
84727
|
+
"EHOSTUNREACH",
|
|
84728
|
+
"ENETUNREACH",
|
|
84729
|
+
"EAI_FAIL"
|
|
84730
|
+
]);
|
|
84731
|
+
var TIMEOUT_OS_ERROR_CODES = new Set(["ETIMEDOUT", "ESOCKETTIMEDOUT"]);
|
|
84732
|
+
var TLS_ERROR_CODES2 = new Set([
|
|
84733
|
+
"SELF_SIGNED_CERT_IN_CHAIN",
|
|
84734
|
+
"DEPTH_ZERO_SELF_SIGNED_CERT",
|
|
84735
|
+
"UNABLE_TO_VERIFY_LEAF_SIGNATURE",
|
|
84736
|
+
"UNABLE_TO_GET_ISSUER_CERT_LOCALLY",
|
|
84737
|
+
"UNABLE_TO_GET_ISSUER_CERT",
|
|
84738
|
+
"CERT_HAS_EXPIRED",
|
|
84739
|
+
"CERT_UNTRUSTED",
|
|
84740
|
+
"ERR_TLS_CERT_ALTNAME_INVALID"
|
|
84741
|
+
]);
|
|
84742
|
+
var MISSING_DEPENDENCY_CODES = new Set([
|
|
84743
|
+
"MODULE_NOT_FOUND",
|
|
84744
|
+
"ERR_MODULE_NOT_FOUND"
|
|
84745
|
+
]);
|
|
84746
|
+
var INTERNAL_ERROR_NAMES = new Set([
|
|
84747
|
+
"TypeError",
|
|
84748
|
+
"ReferenceError",
|
|
84749
|
+
"SyntaxError",
|
|
84750
|
+
"RangeError"
|
|
84751
|
+
]);
|
|
84752
|
+
function isRecord(value) {
|
|
84753
|
+
return value !== null && typeof value === "object";
|
|
84754
|
+
}
|
|
84755
|
+
function stringField(value, field) {
|
|
84756
|
+
if (!isRecord(value)) {
|
|
84757
|
+
return;
|
|
84758
|
+
}
|
|
84759
|
+
const raw = value[field];
|
|
84760
|
+
return typeof raw === "string" ? raw : undefined;
|
|
84761
|
+
}
|
|
84762
|
+
function numberField(value, field) {
|
|
84763
|
+
if (!isRecord(value)) {
|
|
84764
|
+
return;
|
|
84765
|
+
}
|
|
84766
|
+
const raw = value[field];
|
|
84767
|
+
return typeof raw === "number" ? raw : undefined;
|
|
84768
|
+
}
|
|
84769
|
+
function findStringInCauseChain(error, field) {
|
|
84770
|
+
let current = error;
|
|
84771
|
+
for (let depth = 0;depth < 5 && current !== null && typeof current === "object"; depth++) {
|
|
84772
|
+
const value = stringField(current, field);
|
|
84773
|
+
if (value) {
|
|
84774
|
+
return value;
|
|
84775
|
+
}
|
|
84776
|
+
current = current.cause;
|
|
84777
|
+
}
|
|
84778
|
+
return;
|
|
84779
|
+
}
|
|
84780
|
+
function findCodeInCauseChain(error) {
|
|
84781
|
+
return findStringInCauseChain(error, "code");
|
|
84782
|
+
}
|
|
84783
|
+
function isSpawnEnoent(error) {
|
|
84784
|
+
const code = findCodeInCauseChain(error);
|
|
84785
|
+
if (code !== "ENOENT") {
|
|
84786
|
+
return false;
|
|
84787
|
+
}
|
|
84788
|
+
const syscall = findStringInCauseChain(error, "syscall");
|
|
84789
|
+
return syscall?.startsWith("spawn") === true;
|
|
84790
|
+
}
|
|
84791
|
+
function isCancellationError(error, exitCode, pollSignal) {
|
|
84792
|
+
if (exitCode === 130) {
|
|
84793
|
+
return true;
|
|
84794
|
+
}
|
|
84795
|
+
if (!isRecord(error)) {
|
|
84796
|
+
return false;
|
|
84797
|
+
}
|
|
84798
|
+
if (numberField(error, "exitCode") === 130) {
|
|
84799
|
+
return true;
|
|
84800
|
+
}
|
|
84801
|
+
const name = stringField(error, "name");
|
|
84802
|
+
if (name === "ExitPromptError") {
|
|
84803
|
+
return true;
|
|
84804
|
+
}
|
|
84805
|
+
if (name === "AbortError" && pollSignal?.aborted) {
|
|
84806
|
+
return true;
|
|
84807
|
+
}
|
|
84808
|
+
const message = stringField(error, "message");
|
|
84809
|
+
return message?.includes("SIGINT") === true;
|
|
84810
|
+
}
|
|
84811
|
+
function terminalSignalFor(input, outcome) {
|
|
84812
|
+
if (input.recordedFailure?.terminalSignal) {
|
|
84813
|
+
return input.recordedFailure.terminalSignal;
|
|
84814
|
+
}
|
|
84815
|
+
const explicit = findStringInCauseChain(input.error, "terminalSignal") ?? findStringInCauseChain(input.error, "signal");
|
|
84816
|
+
if (explicit) {
|
|
84817
|
+
return explicit;
|
|
84818
|
+
}
|
|
84819
|
+
return outcome === "cancelled" ? "SIGINT" : undefined;
|
|
84820
|
+
}
|
|
84821
|
+
function classifyHttpStatus(status) {
|
|
84822
|
+
if (status === 401 || status === 403) {
|
|
84823
|
+
return "auth";
|
|
84824
|
+
}
|
|
84825
|
+
if (status === 400 || status === 409 || status === 422) {
|
|
84826
|
+
return "validation";
|
|
84827
|
+
}
|
|
84828
|
+
if (status === 408) {
|
|
84829
|
+
return "timeout";
|
|
84830
|
+
}
|
|
84831
|
+
return "network_http";
|
|
84832
|
+
}
|
|
84833
|
+
function classifyFromResult(result) {
|
|
84834
|
+
switch (result) {
|
|
84835
|
+
case "AuthenticationError":
|
|
84836
|
+
return "auth";
|
|
84837
|
+
case "ValidationError":
|
|
84838
|
+
return "validation";
|
|
84839
|
+
case "TimeoutError":
|
|
84840
|
+
return "timeout";
|
|
84841
|
+
default:
|
|
84842
|
+
return;
|
|
84843
|
+
}
|
|
84844
|
+
}
|
|
84845
|
+
function classifyFromErrorCode(errorCode) {
|
|
84846
|
+
if (!errorCode) {
|
|
84847
|
+
return;
|
|
84848
|
+
}
|
|
84849
|
+
if (AUTH_ERROR_CODES.has(errorCode)) {
|
|
84850
|
+
return "auth";
|
|
84851
|
+
}
|
|
84852
|
+
if (VALIDATION_ERROR_CODES.has(errorCode)) {
|
|
84853
|
+
return "validation";
|
|
84854
|
+
}
|
|
84855
|
+
if (TIMEOUT_ERROR_CODES.has(errorCode)) {
|
|
84856
|
+
return "timeout";
|
|
84857
|
+
}
|
|
84858
|
+
if (NETWORK_HTTP_ERROR_CODES.has(errorCode)) {
|
|
84859
|
+
return "network_http";
|
|
84860
|
+
}
|
|
84861
|
+
return;
|
|
84862
|
+
}
|
|
84863
|
+
function classifyFromError(error) {
|
|
84864
|
+
const code = findCodeInCauseChain(error);
|
|
84865
|
+
if (code) {
|
|
84866
|
+
if (code.startsWith("commander.")) {
|
|
84867
|
+
return "validation";
|
|
84868
|
+
}
|
|
84869
|
+
if (NETWORK_OS_ERROR_CODES.has(code) || TLS_ERROR_CODES2.has(code)) {
|
|
84870
|
+
return "network_http";
|
|
84871
|
+
}
|
|
84872
|
+
if (TIMEOUT_OS_ERROR_CODES.has(code)) {
|
|
84873
|
+
return "timeout";
|
|
84874
|
+
}
|
|
84875
|
+
if (MISSING_DEPENDENCY_CODES.has(code) || isSpawnEnoent(error)) {
|
|
84876
|
+
return "missing_dependency";
|
|
84877
|
+
}
|
|
84878
|
+
}
|
|
84879
|
+
const message = stringField(error, "message");
|
|
84880
|
+
if (message?.includes("fetch failed") === true) {
|
|
84881
|
+
return "network_http";
|
|
84882
|
+
}
|
|
84883
|
+
const name = stringField(error, "name");
|
|
84884
|
+
if (name && INTERNAL_ERROR_NAMES.has(name)) {
|
|
84885
|
+
return "internal";
|
|
84886
|
+
}
|
|
84887
|
+
return;
|
|
84888
|
+
}
|
|
84889
|
+
function classifyError(input) {
|
|
84890
|
+
const recorded = input.recordedFailure;
|
|
84891
|
+
if (recorded?.errorClass) {
|
|
84892
|
+
return recorded.errorClass;
|
|
84893
|
+
}
|
|
84894
|
+
const status = recorded?.context?.httpStatus;
|
|
84895
|
+
if (status !== undefined) {
|
|
84896
|
+
return classifyHttpStatus(status);
|
|
84897
|
+
}
|
|
84898
|
+
return classifyFromResult(recorded?.result) ?? classifyFromErrorCode(recorded?.errorCode) ?? classifyFromError(input.error) ?? "unknown";
|
|
84899
|
+
}
|
|
84900
|
+
function recordCommandFailureTelemetry(failure) {
|
|
84901
|
+
recordedFailureSlot.set(failure);
|
|
84902
|
+
}
|
|
84903
|
+
function clearRecordedCommandFailureTelemetry() {
|
|
84904
|
+
recordedFailureSlot.clear();
|
|
84905
|
+
}
|
|
84906
|
+
function takeRecordedCommandFailureTelemetry() {
|
|
84907
|
+
const failure = recordedFailureSlot.get();
|
|
84908
|
+
recordedFailureSlot.clear();
|
|
84909
|
+
return failure;
|
|
84910
|
+
}
|
|
84911
|
+
function buildCommandTerminalTelemetryProperties(input) {
|
|
84912
|
+
const cancelled = isCancellationError(input.error, input.exitCode, input.pollSignal);
|
|
84913
|
+
const outcome = input.recordedFailure?.terminalOutcome ?? (input.exitCode === 0 ? "success" : cancelled ? "cancelled" : "failure");
|
|
84914
|
+
const errorClass = outcome === "success" || outcome === "no_op" ? undefined : outcome === "cancelled" ? "user_cancelled" : classifyError(input);
|
|
84915
|
+
const terminalSignal = terminalSignalFor(input, outcome);
|
|
84916
|
+
return {
|
|
84917
|
+
exit_code: input.exitCode,
|
|
84918
|
+
terminal_outcome: outcome,
|
|
84919
|
+
...errorClass ? { error_class: errorClass } : {},
|
|
84920
|
+
...terminalSignal ? { terminal_signal: terminalSignal } : {}
|
|
84921
|
+
};
|
|
84922
|
+
}
|
|
84923
|
+
|
|
83598
84924
|
// ../common/src/telemetry/telemetry-events.ts
|
|
83599
84925
|
var CommonTelemetryEvents = {
|
|
83600
|
-
Error: "uip.error"
|
|
84926
|
+
Error: "uip.error",
|
|
84927
|
+
ShipSucceeded: "ship_succeeded"
|
|
83601
84928
|
};
|
|
83602
84929
|
|
|
83603
84930
|
// ../common/src/registry.ts
|
|
@@ -83664,6 +84991,136 @@ function formatMessage(category, name, properties) {
|
|
|
83664
84991
|
}
|
|
83665
84992
|
return message;
|
|
83666
84993
|
}
|
|
84994
|
+
// ../common/src/telemetry/detect-agent.ts
|
|
84995
|
+
var KNOWN_AGENTS = [
|
|
84996
|
+
{ envVar: "CLAUDECODE", value: "1", id: "claude-code" },
|
|
84997
|
+
{ envVar: "CURSOR_AGENT", value: "1", id: "cursor" },
|
|
84998
|
+
{ envVar: "GEMINI_CLI", value: "1", id: "gemini-cli" },
|
|
84999
|
+
{ envVar: "CODEX_THREAD_ID", id: "codex" },
|
|
85000
|
+
{ envVar: "CODEX_SANDBOX", id: "codex" },
|
|
85001
|
+
{ envVar: "AUGMENT_AGENT", value: "1", id: "augment" },
|
|
85002
|
+
{ envVar: "CLINE_ACTIVE", value: "true", id: "cline" }
|
|
85003
|
+
];
|
|
85004
|
+
function detectAgentFromEnv(env) {
|
|
85005
|
+
for (const agent of KNOWN_AGENTS) {
|
|
85006
|
+
const envValue = env[agent.envVar];
|
|
85007
|
+
if (agent.value !== undefined) {
|
|
85008
|
+
if (envValue === agent.value)
|
|
85009
|
+
return agent.id;
|
|
85010
|
+
} else {
|
|
85011
|
+
if (envValue)
|
|
85012
|
+
return agent.id;
|
|
85013
|
+
}
|
|
85014
|
+
}
|
|
85015
|
+
const agentEnv = env.AGENT;
|
|
85016
|
+
if (agentEnv) {
|
|
85017
|
+
if (agentEnv === "1" || agentEnv === "true")
|
|
85018
|
+
return "unknown";
|
|
85019
|
+
if (agentEnv.length <= 32)
|
|
85020
|
+
return agentEnv.toLowerCase();
|
|
85021
|
+
}
|
|
85022
|
+
return;
|
|
85023
|
+
}
|
|
85024
|
+
// ../common/src/telemetry/environment-info.ts
|
|
85025
|
+
var LOCAL_HOSTS = new Set(["localhost", "127.0.0.1", "::1", "[::1]"]);
|
|
85026
|
+
// ../common/src/telemetry/execution-context.ts
|
|
85027
|
+
var authSignalSlot = singleton("TelemetryExecutionContextAuthSignal");
|
|
85028
|
+
var isTruthy = (value) => value !== undefined && value !== "" && value !== "0" && value.toLowerCase() !== "false";
|
|
85029
|
+
var isEqual = (value, expected) => value?.toLowerCase() === expected;
|
|
85030
|
+
var CI_SIGNATURES = [
|
|
85031
|
+
{
|
|
85032
|
+
provider: "github_actions",
|
|
85033
|
+
matches: (env) => isTruthy(env.GITHUB_ACTIONS),
|
|
85034
|
+
isScheduler: (env) => env.GITHUB_EVENT_NAME === "schedule"
|
|
85035
|
+
},
|
|
85036
|
+
{
|
|
85037
|
+
provider: "azure_devops",
|
|
85038
|
+
matches: (env) => isTruthy(env.TF_BUILD),
|
|
85039
|
+
isScheduler: (env) => isEqual(env.BUILD_REASON, "schedule")
|
|
85040
|
+
},
|
|
85041
|
+
{
|
|
85042
|
+
provider: "gitlab",
|
|
85043
|
+
matches: (env) => isTruthy(env.GITLAB_CI),
|
|
85044
|
+
isScheduler: (env) => env.CI_PIPELINE_SOURCE === "schedule"
|
|
85045
|
+
},
|
|
85046
|
+
{
|
|
85047
|
+
provider: "circleci",
|
|
85048
|
+
matches: (env) => isTruthy(env.CIRCLECI),
|
|
85049
|
+
isScheduler: (env) => env.CIRCLE_PIPELINE_TRIGGER_SOURCE === "scheduled_pipeline"
|
|
85050
|
+
},
|
|
85051
|
+
{
|
|
85052
|
+
provider: "jenkins",
|
|
85053
|
+
matches: (env) => isTruthy(env.JENKINS_URL) || isTruthy(env.JENKINS_HOME)
|
|
85054
|
+
},
|
|
85055
|
+
{
|
|
85056
|
+
provider: "teamcity",
|
|
85057
|
+
matches: (env) => isTruthy(env.TEAMCITY_VERSION)
|
|
85058
|
+
},
|
|
85059
|
+
{
|
|
85060
|
+
provider: "buildkite",
|
|
85061
|
+
matches: (env) => isTruthy(env.BUILDKITE),
|
|
85062
|
+
isScheduler: (env) => env.BUILDKITE_SOURCE === "schedule"
|
|
85063
|
+
},
|
|
85064
|
+
{
|
|
85065
|
+
provider: "bitbucket",
|
|
85066
|
+
matches: (env) => isTruthy(env.BITBUCKET_BUILD_NUMBER)
|
|
85067
|
+
},
|
|
85068
|
+
{
|
|
85069
|
+
provider: "travis",
|
|
85070
|
+
matches: (env) => isTruthy(env.TRAVIS)
|
|
85071
|
+
},
|
|
85072
|
+
{
|
|
85073
|
+
provider: "appveyor",
|
|
85074
|
+
matches: (env) => isTruthy(env.APPVEYOR)
|
|
85075
|
+
},
|
|
85076
|
+
{
|
|
85077
|
+
provider: "generic",
|
|
85078
|
+
matches: (env) => isTruthy(env.CI)
|
|
85079
|
+
}
|
|
85080
|
+
];
|
|
85081
|
+
function currentEnv() {
|
|
85082
|
+
return typeof process === "undefined" ? {} : process.env;
|
|
85083
|
+
}
|
|
85084
|
+
function currentTtyState() {
|
|
85085
|
+
if (typeof process === "undefined")
|
|
85086
|
+
return false;
|
|
85087
|
+
return Boolean(process.stdout?.isTTY || process.stdin?.isTTY || process.stderr?.isTTY);
|
|
85088
|
+
}
|
|
85089
|
+
function detectCi(env) {
|
|
85090
|
+
const signature = CI_SIGNATURES.find((candidate) => candidate.matches(env));
|
|
85091
|
+
if (!signature)
|
|
85092
|
+
return;
|
|
85093
|
+
return {
|
|
85094
|
+
executionContext: signature.isScheduler?.(env) ? "scheduler" : "ci",
|
|
85095
|
+
ciProvider: signature.provider
|
|
85096
|
+
};
|
|
85097
|
+
}
|
|
85098
|
+
function detectExecutionContext(options = {}) {
|
|
85099
|
+
const env = options.env ?? currentEnv();
|
|
85100
|
+
const ci = detectCi(env);
|
|
85101
|
+
if (ci)
|
|
85102
|
+
return ci;
|
|
85103
|
+
const agent = options.agent ?? detectAgentFromEnv(env);
|
|
85104
|
+
if (agent) {
|
|
85105
|
+
return { executionContext: "agent" };
|
|
85106
|
+
}
|
|
85107
|
+
const authSignal = options.authSignal ?? authSignalSlot.get();
|
|
85108
|
+
if (authSignal === "service_account") {
|
|
85109
|
+
return { executionContext: "service_account" };
|
|
85110
|
+
}
|
|
85111
|
+
const isTty = options.isTty ?? currentTtyState();
|
|
85112
|
+
if (isTty) {
|
|
85113
|
+
return { executionContext: "manual" };
|
|
85114
|
+
}
|
|
85115
|
+
return { executionContext: "unknown" };
|
|
85116
|
+
}
|
|
85117
|
+
function getExecutionContextTelemetryProperties() {
|
|
85118
|
+
const detected = detectExecutionContext();
|
|
85119
|
+
return {
|
|
85120
|
+
execution_context: detected.executionContext,
|
|
85121
|
+
...detected.ciProvider ? { ci_provider: detected.ciProvider } : {}
|
|
85122
|
+
};
|
|
85123
|
+
}
|
|
83667
85124
|
// ../common/src/telemetry/node-context-storage.ts
|
|
83668
85125
|
import { AsyncLocalStorage } from "node:async_hooks";
|
|
83669
85126
|
|
|
@@ -83676,6 +85133,26 @@ class NodeContextStorage {
|
|
|
83676
85133
|
return this.storage.getStore();
|
|
83677
85134
|
}
|
|
83678
85135
|
}
|
|
85136
|
+
// ../common/src/telemetry/session-id.ts
|
|
85137
|
+
var TELEMETRY_SESSION_ID_ENV = "UIPATH_SESSION_ID";
|
|
85138
|
+
var TELEMETRY_SESSION_ID_PROPERTY = "session_id";
|
|
85139
|
+
var telemetrySessionIdSlot = singleton("TelemetrySessionId");
|
|
85140
|
+
function getProcessEnv() {
|
|
85141
|
+
return globalThis.process?.env;
|
|
85142
|
+
}
|
|
85143
|
+
function normalizeSessionId(value) {
|
|
85144
|
+
if (typeof value !== "string" && typeof value !== "number" && typeof value !== "boolean") {
|
|
85145
|
+
return;
|
|
85146
|
+
}
|
|
85147
|
+
const trimmed = String(value).trim();
|
|
85148
|
+
return trimmed || undefined;
|
|
85149
|
+
}
|
|
85150
|
+
function getConfiguredTelemetrySessionId() {
|
|
85151
|
+
return normalizeSessionId(getProcessEnv()?.[TELEMETRY_SESSION_ID_ENV]);
|
|
85152
|
+
}
|
|
85153
|
+
function resolveTelemetrySessionId(existingSessionId) {
|
|
85154
|
+
return getConfiguredTelemetrySessionId() ?? normalizeSessionId(existingSessionId);
|
|
85155
|
+
}
|
|
83679
85156
|
// ../common/src/telemetry/global-telemetry-properties.ts
|
|
83680
85157
|
var telemetryPropsSlot = singleton("TelemetryDefaultProps");
|
|
83681
85158
|
function getGlobalTelemetryProperties() {
|
|
@@ -83760,12 +85237,22 @@ class TelemetryService {
|
|
|
83760
85237
|
return this.contextStorage.getContext();
|
|
83761
85238
|
}
|
|
83762
85239
|
enrichPropertiesWithContext(properties, context) {
|
|
83763
|
-
|
|
83764
|
-
|
|
85240
|
+
const globalProperties = getGlobalTelemetryProperties();
|
|
85241
|
+
const existingSessionId = properties?.[TELEMETRY_SESSION_ID_PROPERTY] ?? this.defaultProperties?.[TELEMETRY_SESSION_ID_PROPERTY] ?? globalProperties?.[TELEMETRY_SESSION_ID_PROPERTY];
|
|
85242
|
+
const sessionId = resolveTelemetrySessionId(existingSessionId);
|
|
85243
|
+
const enriched = {
|
|
85244
|
+
...getExecutionContextTelemetryProperties(),
|
|
85245
|
+
...globalProperties,
|
|
83765
85246
|
...this.defaultProperties,
|
|
83766
85247
|
...properties,
|
|
83767
85248
|
...context
|
|
83768
85249
|
};
|
|
85250
|
+
if (sessionId === undefined) {
|
|
85251
|
+
delete enriched[TELEMETRY_SESSION_ID_PROPERTY];
|
|
85252
|
+
} else {
|
|
85253
|
+
enriched[TELEMETRY_SESSION_ID_PROPERTY] = sessionId;
|
|
85254
|
+
}
|
|
85255
|
+
return enriched;
|
|
83769
85256
|
}
|
|
83770
85257
|
generateId() {
|
|
83771
85258
|
return crypto.randomUUID().replaceAll("-", "");
|
|
@@ -83868,6 +85355,9 @@ class FailureOutput {
|
|
|
83868
85355
|
Log;
|
|
83869
85356
|
Data;
|
|
83870
85357
|
SuppressTelemetry;
|
|
85358
|
+
TelemetryErrorClass;
|
|
85359
|
+
TelemetryTerminalOutcome;
|
|
85360
|
+
TelemetryTerminalSignal;
|
|
83871
85361
|
constructor(result, message, instructions, context, errorCode, retry) {
|
|
83872
85362
|
this.Result = result;
|
|
83873
85363
|
this.Message = message;
|
|
@@ -84266,8 +85756,24 @@ var OutputFormatter;
|
|
|
84266
85756
|
data.ErrorCode ??= defaultErrorCodeForFailure(data);
|
|
84267
85757
|
data.Retry ??= defaultRetryForErrorCode(data.ErrorCode);
|
|
84268
85758
|
process.exitCode = EXIT_CODES[data.Result] ?? 1;
|
|
84269
|
-
|
|
84270
|
-
|
|
85759
|
+
recordCommandFailureTelemetry({
|
|
85760
|
+
result: data.Result,
|
|
85761
|
+
errorCode: data.ErrorCode,
|
|
85762
|
+
retry: data.Retry,
|
|
85763
|
+
message: data.Message,
|
|
85764
|
+
context: data.Context,
|
|
85765
|
+
exitCode: process.exitCode,
|
|
85766
|
+
errorClass: data.TelemetryErrorClass,
|
|
85767
|
+
terminalOutcome: data.TelemetryTerminalOutcome,
|
|
85768
|
+
terminalSignal: data.TelemetryTerminalSignal
|
|
85769
|
+
});
|
|
85770
|
+
const suppressTelemetry = data.SuppressTelemetry === true;
|
|
85771
|
+
const envelope = { ...data };
|
|
85772
|
+
delete envelope.SuppressTelemetry;
|
|
85773
|
+
delete envelope.TelemetryErrorClass;
|
|
85774
|
+
delete envelope.TelemetryTerminalOutcome;
|
|
85775
|
+
delete envelope.TelemetryTerminalSignal;
|
|
85776
|
+
if (!suppressTelemetry) {
|
|
84271
85777
|
telemetry.trackEvent(CommonTelemetryEvents.Error, {
|
|
84272
85778
|
result: data.Result,
|
|
84273
85779
|
errorCode: data.ErrorCode,
|
|
@@ -84330,6 +85836,158 @@ var OutputFormatter;
|
|
|
84330
85836
|
OutputFormatter.formatToString = formatToString;
|
|
84331
85837
|
})(OutputFormatter ||= {});
|
|
84332
85838
|
|
|
85839
|
+
// ../common/src/telemetry/command-attribution.ts
|
|
85840
|
+
var LEGACY_SKILL_NAMESPACE = "uipath:";
|
|
85841
|
+
var MAX_SKILL_NAME_LENGTH = 80;
|
|
85842
|
+
var SKILL_NAME_PATTERN = /^[a-z0-9][a-z0-9-]*[a-z0-9]$/;
|
|
85843
|
+
function productMode(productArea, mode) {
|
|
85844
|
+
return { product_area: productArea, mode };
|
|
85845
|
+
}
|
|
85846
|
+
function attributionRecord(groups) {
|
|
85847
|
+
const record = {};
|
|
85848
|
+
for (const [productArea, mode, names] of groups) {
|
|
85849
|
+
const attribution = productMode(productArea, mode);
|
|
85850
|
+
for (const name of names) {
|
|
85851
|
+
record[name] = attribution;
|
|
85852
|
+
}
|
|
85853
|
+
}
|
|
85854
|
+
return record;
|
|
85855
|
+
}
|
|
85856
|
+
function commandAttribution(groups) {
|
|
85857
|
+
const entries = [];
|
|
85858
|
+
for (const [productArea, mode, prefixes] of groups) {
|
|
85859
|
+
const attribution = productMode(productArea, mode);
|
|
85860
|
+
for (const prefix of prefixes) {
|
|
85861
|
+
entries.push({ prefix, attribution });
|
|
85862
|
+
}
|
|
85863
|
+
}
|
|
85864
|
+
return entries;
|
|
85865
|
+
}
|
|
85866
|
+
var SKILL_ATTRIBUTION = attributionRecord([
|
|
85867
|
+
["admin", "operate", ["uipath-admin"]],
|
|
85868
|
+
["agents", "build", ["uipath-agents"]],
|
|
85869
|
+
["api-workflow", "build", ["uipath-api-workflow"]],
|
|
85870
|
+
["automation-discovery", "build", ["uipath-automation-discovery"]],
|
|
85871
|
+
["coded-apps", "build", ["uipath-coded-apps"]],
|
|
85872
|
+
["data-fabric", "operate", ["uipath-data-fabric"]],
|
|
85873
|
+
["cli", "troubleshoot", ["uipath-feedback"]],
|
|
85874
|
+
["governance", "operate", ["uipath-governance"]],
|
|
85875
|
+
["action-center", "build", ["uipath-human-in-the-loop"]],
|
|
85876
|
+
["document-understanding", "build", ["uipath-ixp"]],
|
|
85877
|
+
[
|
|
85878
|
+
"maestro",
|
|
85879
|
+
"build",
|
|
85880
|
+
["uipath-maestro-bpmn", "uipath-maestro-case", "uipath-maestro-flow"]
|
|
85881
|
+
],
|
|
85882
|
+
["agenthub", "build", ["uipath-mcp-servers"]],
|
|
85883
|
+
["solution", "build", ["uipath-planner", "uipath-solution"]],
|
|
85884
|
+
["platform", "operate", ["uipath-platform"]],
|
|
85885
|
+
["quality", "troubleshoot", ["uipath-review"]],
|
|
85886
|
+
["rpa", "build", ["uipath-rpa"]],
|
|
85887
|
+
["cli", "operate", ["uipath-skill-catalog"]],
|
|
85888
|
+
["action-center", "operate", ["uipath-tasks"]],
|
|
85889
|
+
["test-manager", "operate", ["uipath-test"]],
|
|
85890
|
+
["platform", "troubleshoot", ["uipath-troubleshoot"]]
|
|
85891
|
+
]);
|
|
85892
|
+
var KNOWN_SKILL_NAMES = new Set(Object.keys(SKILL_ATTRIBUTION));
|
|
85893
|
+
var COMMAND_ATTRIBUTION = commandAttribution([
|
|
85894
|
+
["cli", "troubleshoot", ["uip.feedback"]],
|
|
85895
|
+
["llm-gateway", "operate", ["uip.llm-configuration", "uip.model-hub"]],
|
|
85896
|
+
["context-grounding", "build", ["uip.context-grounding"]],
|
|
85897
|
+
["api-workflow", "build", ["uip.api-workflow"]],
|
|
85898
|
+
["rpa", "build", ["uip.rpa-legacy"]],
|
|
85899
|
+
["conversational", "operate", ["uip.conversational"]],
|
|
85900
|
+
["agents", "build", ["uip.codedagent", "uip.agent"]],
|
|
85901
|
+
["agenthub", "build", ["uip.agenthub"]],
|
|
85902
|
+
["coded-apps", "build", ["uip.codedapp"]],
|
|
85903
|
+
["functions", "build", ["uip.functions"]],
|
|
85904
|
+
["solution", "build", ["uip.solution"]],
|
|
85905
|
+
["maestro", "build", ["uip.maestro", "uip.case", "uip.flow"]],
|
|
85906
|
+
["llm-observability", "troubleshoot", ["uip.traces"]],
|
|
85907
|
+
["platform", "operate", ["uip.platform"]],
|
|
85908
|
+
["admin", "operate", ["uip.admin"]],
|
|
85909
|
+
["automation-ops", "operate", ["uip.aops"]],
|
|
85910
|
+
["documentation", "troubleshoot", ["uip.docsai"]],
|
|
85911
|
+
["governance", "operate", ["uip.gov"]],
|
|
85912
|
+
["insights", "operate", ["uip.insights"]],
|
|
85913
|
+
["document-understanding", "build", ["uip.ixp"]],
|
|
85914
|
+
["process-mining", "operate", ["uip.pm"]],
|
|
85915
|
+
["action-center", "operate", ["uip.tasks"]],
|
|
85916
|
+
["test-manager", "operate", ["uip.tm"]],
|
|
85917
|
+
["vertical-solutions", "build", ["uip.vss"]],
|
|
85918
|
+
["data-fabric", "operate", ["uip.df"]],
|
|
85919
|
+
["integration-service", "build", ["uip.is"]],
|
|
85920
|
+
["orchestrator", "operate", ["uip.or"]],
|
|
85921
|
+
[
|
|
85922
|
+
"cli",
|
|
85923
|
+
"operate",
|
|
85924
|
+
[
|
|
85925
|
+
"uip.login",
|
|
85926
|
+
"uip.logout",
|
|
85927
|
+
"uip.user",
|
|
85928
|
+
"uip.config",
|
|
85929
|
+
"uip.tools",
|
|
85930
|
+
"uip.skills",
|
|
85931
|
+
"uip.completion",
|
|
85932
|
+
"uip.update",
|
|
85933
|
+
"uip.mcp",
|
|
85934
|
+
"uip.track"
|
|
85935
|
+
]
|
|
85936
|
+
]
|
|
85937
|
+
]).sort((a, b) => b.prefix.length - a.prefix.length);
|
|
85938
|
+
function normalizeCommandPath(value) {
|
|
85939
|
+
if (typeof value !== "string") {
|
|
85940
|
+
return;
|
|
85941
|
+
}
|
|
85942
|
+
const trimmed = value.trim().toLowerCase();
|
|
85943
|
+
if (!trimmed) {
|
|
85944
|
+
return;
|
|
85945
|
+
}
|
|
85946
|
+
const tokens = trimmed.includes(" ") ? trimmed.split(/\s+/).filter((token) => token.length > 0).filter((token) => !token.startsWith("-")) : trimmed.split(".").filter((token) => token.length > 0);
|
|
85947
|
+
if (tokens.length === 0) {
|
|
85948
|
+
return;
|
|
85949
|
+
}
|
|
85950
|
+
const commandTokens = tokens[0] === "uip" ? tokens : ["uip", ...tokens];
|
|
85951
|
+
return commandTokens.join(".");
|
|
85952
|
+
}
|
|
85953
|
+
function getCommandProductModeAttribution(commandPath) {
|
|
85954
|
+
const normalized = normalizeCommandPath(commandPath);
|
|
85955
|
+
if (!normalized) {
|
|
85956
|
+
return;
|
|
85957
|
+
}
|
|
85958
|
+
return COMMAND_ATTRIBUTION.find(({ prefix }) => normalized === prefix || normalized.startsWith(`${prefix}.`))?.attribution;
|
|
85959
|
+
}
|
|
85960
|
+
function normalizeSkillNameWithOptions(value, options) {
|
|
85961
|
+
if (typeof value !== "string") {
|
|
85962
|
+
return;
|
|
85963
|
+
}
|
|
85964
|
+
const normalized = value.trim().toLowerCase();
|
|
85965
|
+
if (!normalized) {
|
|
85966
|
+
return;
|
|
85967
|
+
}
|
|
85968
|
+
const hasLegacyNamespace = normalized.startsWith(LEGACY_SKILL_NAMESPACE);
|
|
85969
|
+
if (hasLegacyNamespace && !options.allowLegacyNamespace) {
|
|
85970
|
+
return;
|
|
85971
|
+
}
|
|
85972
|
+
const skillName = hasLegacyNamespace ? normalized.slice(LEGACY_SKILL_NAMESPACE.length) : normalized;
|
|
85973
|
+
if (skillName.length > MAX_SKILL_NAME_LENGTH || !SKILL_NAME_PATTERN.test(skillName) || !KNOWN_SKILL_NAMES.has(skillName)) {
|
|
85974
|
+
return;
|
|
85975
|
+
}
|
|
85976
|
+
return skillName;
|
|
85977
|
+
}
|
|
85978
|
+
function normalizeSkillName(value) {
|
|
85979
|
+
return normalizeSkillNameWithOptions(value, {
|
|
85980
|
+
allowLegacyNamespace: false
|
|
85981
|
+
});
|
|
85982
|
+
}
|
|
85983
|
+
function buildCommandTelemetryAttribution(commandPath, skillSource) {
|
|
85984
|
+
const skillName = normalizeSkillName(skillSource);
|
|
85985
|
+
return {
|
|
85986
|
+
...skillName ? { skill_name: skillName } : {},
|
|
85987
|
+
...getCommandProductModeAttribution(commandPath)
|
|
85988
|
+
};
|
|
85989
|
+
}
|
|
85990
|
+
|
|
84333
85991
|
// ../common/src/telemetry/pii-redactor.ts
|
|
84334
85992
|
var REDACTED = "[REDACTED]";
|
|
84335
85993
|
var MAX_VALUE_LENGTH = 200;
|
|
@@ -84515,6 +86173,12 @@ function commandHelpHint(commandPath) {
|
|
|
84515
86173
|
const command = commandPath.replace(/\./g, " ");
|
|
84516
86174
|
return `An unexpected error occurred. Run '${command} --help' to verify command syntax, or run with --log-level debug for details.`;
|
|
84517
86175
|
}
|
|
86176
|
+
function isPromptCancellation(error) {
|
|
86177
|
+
return error instanceof Error && error.name === "ExitPromptError";
|
|
86178
|
+
}
|
|
86179
|
+
function exitCodeFromProcess(fallback) {
|
|
86180
|
+
return typeof process.exitCode === "number" ? process.exitCode : fallback;
|
|
86181
|
+
}
|
|
84518
86182
|
Command.prototype.trackedAction = function(context, fn, properties) {
|
|
84519
86183
|
const command = this;
|
|
84520
86184
|
return this.action(async (...args) => {
|
|
@@ -84522,6 +86186,8 @@ Command.prototype.trackedAction = function(context, fn, properties) {
|
|
|
84522
86186
|
const props = typeof properties === "function" ? properties(...args) : properties;
|
|
84523
86187
|
const startTime = performance.now();
|
|
84524
86188
|
let errorMessage;
|
|
86189
|
+
let fallbackExitCode = EXIT_CODES.Success;
|
|
86190
|
+
clearRecordedCommandFailureTelemetry();
|
|
84525
86191
|
const [error] = await catchError(fn(...args));
|
|
84526
86192
|
if (error) {
|
|
84527
86193
|
errorMessage = error instanceof Error ? error.message : String(error);
|
|
@@ -84536,6 +86202,8 @@ Command.prototype.trackedAction = function(context, fn, properties) {
|
|
|
84536
86202
|
const customRetry = isRetryHint(typedRetry) ? typedRetry : undefined;
|
|
84537
86203
|
const typedContext = typed.context ?? typed.Context;
|
|
84538
86204
|
const customContext = isErrorContext(typedContext) ? typedContext : undefined;
|
|
86205
|
+
const cancellationExitCode = typed.exitCode === 130 || isPromptCancellation(error) ? 130 : undefined;
|
|
86206
|
+
fallbackExitCode = cancellationExitCode ?? EXIT_CODES[finalResult];
|
|
84539
86207
|
OutputFormatter.error({
|
|
84540
86208
|
Result: finalResult,
|
|
84541
86209
|
...customErrorCode ? { ErrorCode: customErrorCode } : {},
|
|
@@ -84544,16 +86212,26 @@ Command.prototype.trackedAction = function(context, fn, properties) {
|
|
|
84544
86212
|
...customRetry ? { Retry: customRetry } : {},
|
|
84545
86213
|
...customContext ? { Context: customContext } : {}
|
|
84546
86214
|
});
|
|
84547
|
-
context.exit(
|
|
86215
|
+
context.exit(fallbackExitCode);
|
|
84548
86216
|
}
|
|
84549
86217
|
const durationMs = performance.now() - startTime;
|
|
84550
|
-
const
|
|
86218
|
+
const exitCode = fallbackExitCode === 130 ? fallbackExitCode : exitCodeFromProcess(fallbackExitCode);
|
|
86219
|
+
const recordedFailure = takeRecordedCommandFailureTelemetry();
|
|
86220
|
+
const success = !error && exitCode === 0;
|
|
86221
|
+
const terminalTelemetry = buildCommandTerminalTelemetryProperties({
|
|
86222
|
+
error,
|
|
86223
|
+
exitCode,
|
|
86224
|
+
recordedFailure,
|
|
86225
|
+
pollSignal: context.pollSignal
|
|
86226
|
+
});
|
|
84551
86227
|
telemetry.trackEvent(telemetryName, redactProperties({
|
|
84552
86228
|
...extractCommandParams(command),
|
|
84553
86229
|
...props,
|
|
86230
|
+
...buildCommandTelemetryAttribution(telemetryName, process.env.UIPATH_SKILL),
|
|
84554
86231
|
command: "true",
|
|
84555
86232
|
duration: String(durationMs),
|
|
84556
86233
|
success: String(success),
|
|
86234
|
+
...terminalTelemetry,
|
|
84557
86235
|
...errorMessage ? { errorMessage } : {}
|
|
84558
86236
|
}));
|
|
84559
86237
|
});
|
|
@@ -84720,6 +86398,8 @@ function installRequestHeaderForwarding(BaseApiClass, patchKey, forward) {
|
|
|
84720
86398
|
function installSdkUserAgentHeader(BaseApiClass, userAgent) {
|
|
84721
86399
|
installRequestHeaderForwarding(BaseApiClass, userAgentPatchKey(userAgent), (headers) => addSdkUserAgentHeader(headers, userAgent));
|
|
84722
86400
|
}
|
|
86401
|
+
// ../common/src/telemetry/ship-succeeded.ts
|
|
86402
|
+
var shippedKeysSlot = singleton("ShipSucceededDedupeKeys");
|
|
84723
86403
|
// ../common/src/tool-provider.ts
|
|
84724
86404
|
var factorySlot = singleton("PackagerFactoryProvider");
|
|
84725
86405
|
// src/services/bindings-service.ts
|
|
@@ -85255,7 +86935,7 @@ class TextApiResponse {
|
|
|
85255
86935
|
var package_default2 = {
|
|
85256
86936
|
name: "@uipath/integrationservice-sdk",
|
|
85257
86937
|
license: "MIT",
|
|
85258
|
-
version: "1.197.0-preview.
|
|
86938
|
+
version: "1.197.0-preview.67",
|
|
85259
86939
|
repository: {
|
|
85260
86940
|
type: "git",
|
|
85261
86941
|
url: "https://github.com/UiPath/cli.git",
|
|
@@ -94776,7 +96456,7 @@ function querystringSingleKey3(key, value, keyPrefix = "") {
|
|
|
94776
96456
|
var package_default5 = {
|
|
94777
96457
|
name: "@uipath/solution-sdk",
|
|
94778
96458
|
license: "MIT",
|
|
94779
|
-
version: "1.197.0-preview.
|
|
96459
|
+
version: "1.197.0-preview.67",
|
|
94780
96460
|
repository: {
|
|
94781
96461
|
type: "git",
|
|
94782
96462
|
url: "https://github.com/UiPath/cli.git",
|
|
@@ -94837,7 +96517,7 @@ function normalizeProjectType(projectType) {
|
|
|
94837
96517
|
function toPortableRelativePath(relativePath) {
|
|
94838
96518
|
return relativePath.replace(/\\/g, "/");
|
|
94839
96519
|
}
|
|
94840
|
-
function
|
|
96520
|
+
function isRecord4(value) {
|
|
94841
96521
|
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
94842
96522
|
}
|
|
94843
96523
|
async function tryRegisterProjectInParentSolution(fs11, projectDir, options) {
|
|
@@ -95030,11 +96710,11 @@ async function readProjectManifest(fs11, filePath, useProjectJson) {
|
|
|
95030
96710
|
null
|
|
95031
96711
|
];
|
|
95032
96712
|
}
|
|
95033
|
-
if (!
|
|
96713
|
+
if (!isRecord4(parsed)) {
|
|
95034
96714
|
return [new Error(`Invalid project file: ${filePath}`), null];
|
|
95035
96715
|
}
|
|
95036
96716
|
const designOptions = parsed.designOptions;
|
|
95037
|
-
const outputType = useProjectJson &&
|
|
96717
|
+
const outputType = useProjectJson && isRecord4(designOptions) ? readString(designOptions.outputType) : undefined;
|
|
95038
96718
|
const projectType = outputType ?? readString(parsed.ProjectType);
|
|
95039
96719
|
if (!projectType) {
|
|
95040
96720
|
return [new Error(`ProjectType not found in ${filePath}`), null];
|
|
@@ -95061,7 +96741,7 @@ async function readSolutionManifest(fs11, solutionFile) {
|
|
|
95061
96741
|
null
|
|
95062
96742
|
];
|
|
95063
96743
|
}
|
|
95064
|
-
if (!
|
|
96744
|
+
if (!isRecord4(parsed)) {
|
|
95065
96745
|
return [
|
|
95066
96746
|
new Error(`Invalid solution file: ${solutionFile} must contain a JSON object.`),
|
|
95067
96747
|
null
|
|
@@ -95075,7 +96755,7 @@ async function readSolutionManifest(fs11, solutionFile) {
|
|
|
95075
96755
|
}
|
|
95076
96756
|
const projects = [];
|
|
95077
96757
|
for (const [index, project] of parsed.Projects.entries()) {
|
|
95078
|
-
if (!
|
|
96758
|
+
if (!isRecord4(project)) {
|
|
95079
96759
|
return [
|
|
95080
96760
|
new Error(`Invalid solution file: Projects[${index}] must be an object.`),
|
|
95081
96761
|
null
|
|
@@ -97065,4 +98745,4 @@ export {
|
|
|
97065
98745
|
metadata
|
|
97066
98746
|
};
|
|
97067
98747
|
|
|
97068
|
-
//# debugId=
|
|
98748
|
+
//# debugId=864101D6091AFF3864756E2164756E21
|