@uipath/apms-tool 1.197.0 → 1.198.0-preview.100
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/index.js +1356 -852
- package/dist/tool.js +1356 -852
- package/package.json +2 -2
package/dist/tool.js
CHANGED
|
@@ -19137,7 +19137,7 @@ var init_server = __esm(() => {
|
|
|
19137
19137
|
var package_default = {
|
|
19138
19138
|
name: "@uipath/apms-tool",
|
|
19139
19139
|
license: "MIT",
|
|
19140
|
-
version: "1.
|
|
19140
|
+
version: "1.198.0-preview.100",
|
|
19141
19141
|
description: "CLI plugin for the UiPath Access Policy Management Service.",
|
|
19142
19142
|
private: false,
|
|
19143
19143
|
repository: {
|
|
@@ -19545,7 +19545,7 @@ class VoidApiResponse {
|
|
|
19545
19545
|
var package_default2 = {
|
|
19546
19546
|
name: "@uipath/apms-sdk",
|
|
19547
19547
|
license: "MIT",
|
|
19548
|
-
version: "1.
|
|
19548
|
+
version: "1.198.0",
|
|
19549
19549
|
description: "SDK for the UiPath Access Policy Management Service API.",
|
|
19550
19550
|
repository: {
|
|
19551
19551
|
type: "git",
|
|
@@ -21737,6 +21737,10 @@ function normalizeTokenRefreshUnavailableFailure() {
|
|
|
21737
21737
|
function errorMessage(error) {
|
|
21738
21738
|
return error instanceof Error ? error.message : String(error);
|
|
21739
21739
|
}
|
|
21740
|
+
|
|
21741
|
+
// ../../auth/src/index.ts
|
|
21742
|
+
init_constants();
|
|
21743
|
+
|
|
21740
21744
|
// ../../auth/src/interactive.ts
|
|
21741
21745
|
init_src();
|
|
21742
21746
|
|
|
@@ -21856,8 +21860,15 @@ var TLS_ERROR_CODES = new Set([
|
|
|
21856
21860
|
var TLS_INSTRUCTIONS = "The server's TLS certificate could not be verified. Most often a " + "corporate proxy/firewall re-signs HTTPS with a root CA that Node does " + "not trust — set NODE_EXTRA_CA_CERTS to that CA's PEM file (and HTTPS_PROXY " + "if you connect through a proxy). If the certificate is instead expired or " + "its hostname does not match, fix the endpoint URL or the system clock. " + "Then retry.";
|
|
21857
21861
|
var NETWORK_INSTRUCTIONS = "Could not reach the UiPath service. Check your network connection and " + "VPN, confirm any HTTP_PROXY/HTTPS_PROXY/NO_PROXY settings are correct, " + "then retry.";
|
|
21858
21862
|
function describeConnectivityError(error) {
|
|
21859
|
-
|
|
21860
|
-
|
|
21863
|
+
const queue = [error];
|
|
21864
|
+
const seen = new Set;
|
|
21865
|
+
for (let steps = 0;queue.length > 0 && steps < 32; steps++) {
|
|
21866
|
+
const current = queue.shift();
|
|
21867
|
+
if (current === null || typeof current !== "object")
|
|
21868
|
+
continue;
|
|
21869
|
+
if (seen.has(current))
|
|
21870
|
+
continue;
|
|
21871
|
+
seen.add(current);
|
|
21861
21872
|
const cur = current;
|
|
21862
21873
|
const code = typeof cur.code === "string" ? cur.code : undefined;
|
|
21863
21874
|
const message = typeof cur.message === "string" ? cur.message : undefined;
|
|
@@ -21877,7 +21888,10 @@ function describeConnectivityError(error) {
|
|
|
21877
21888
|
instructions: NETWORK_INSTRUCTIONS
|
|
21878
21889
|
};
|
|
21879
21890
|
}
|
|
21880
|
-
|
|
21891
|
+
if (cur.cause !== undefined)
|
|
21892
|
+
queue.push(cur.cause);
|
|
21893
|
+
if (Array.isArray(cur.errors))
|
|
21894
|
+
queue.push(...cur.errors);
|
|
21881
21895
|
}
|
|
21882
21896
|
return;
|
|
21883
21897
|
}
|
|
@@ -24121,31 +24135,17 @@ function search(data, expression, options) {
|
|
|
24121
24135
|
}
|
|
24122
24136
|
|
|
24123
24137
|
// ../../../node_modules/js-yaml/dist/js-yaml.mjs
|
|
24124
|
-
|
|
24125
|
-
|
|
24126
|
-
|
|
24127
|
-
var
|
|
24128
|
-
var
|
|
24129
|
-
var
|
|
24130
|
-
var
|
|
24131
|
-
|
|
24132
|
-
|
|
24133
|
-
|
|
24134
|
-
|
|
24135
|
-
key = keys[i];
|
|
24136
|
-
if (!__hasOwnProp2.call(to, key) && key !== except)
|
|
24137
|
-
__defProp2(to, key, {
|
|
24138
|
-
get: ((k) => from[k]).bind(null, key),
|
|
24139
|
-
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
24140
|
-
});
|
|
24141
|
-
}
|
|
24142
|
-
return to;
|
|
24143
|
-
};
|
|
24144
|
-
var __toESM2 = (mod2, isNodeMode, target) => (target = mod2 != null ? __create2(__getProtoOf2(mod2)) : {}, __copyProps(isNodeMode || !mod2 || !mod2.__esModule ? __defProp2(target, "default", {
|
|
24145
|
-
value: mod2,
|
|
24146
|
-
enumerable: true
|
|
24147
|
-
}) : target, mod2));
|
|
24148
|
-
var require_common = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
24138
|
+
function getDefaultExportFromCjs(x) {
|
|
24139
|
+
return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, "default") ? x["default"] : x;
|
|
24140
|
+
}
|
|
24141
|
+
var jsYaml = {};
|
|
24142
|
+
var loader = {};
|
|
24143
|
+
var common = {};
|
|
24144
|
+
var hasRequiredCommon;
|
|
24145
|
+
function requireCommon() {
|
|
24146
|
+
if (hasRequiredCommon)
|
|
24147
|
+
return common;
|
|
24148
|
+
hasRequiredCommon = 1;
|
|
24149
24149
|
function isNothing(subject) {
|
|
24150
24150
|
return typeof subject === "undefined" || subject === null;
|
|
24151
24151
|
}
|
|
@@ -24171,55 +24171,71 @@ var require_common = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
24171
24171
|
}
|
|
24172
24172
|
function repeat(string, count) {
|
|
24173
24173
|
let result = "";
|
|
24174
|
-
for (let cycle = 0;cycle < count; cycle += 1)
|
|
24174
|
+
for (let cycle = 0;cycle < count; cycle += 1) {
|
|
24175
24175
|
result += string;
|
|
24176
|
+
}
|
|
24176
24177
|
return result;
|
|
24177
24178
|
}
|
|
24178
24179
|
function isNegativeZero(number) {
|
|
24179
24180
|
return number === 0 && Number.NEGATIVE_INFINITY === 1 / number;
|
|
24180
24181
|
}
|
|
24181
|
-
|
|
24182
|
-
|
|
24183
|
-
|
|
24184
|
-
|
|
24185
|
-
|
|
24186
|
-
|
|
24187
|
-
|
|
24188
|
-
|
|
24189
|
-
|
|
24182
|
+
common.isNothing = isNothing;
|
|
24183
|
+
common.isObject = isObject2;
|
|
24184
|
+
common.toArray = toArray;
|
|
24185
|
+
common.repeat = repeat;
|
|
24186
|
+
common.isNegativeZero = isNegativeZero;
|
|
24187
|
+
common.extend = extend;
|
|
24188
|
+
return common;
|
|
24189
|
+
}
|
|
24190
|
+
var exception;
|
|
24191
|
+
var hasRequiredException;
|
|
24192
|
+
function requireException() {
|
|
24193
|
+
if (hasRequiredException)
|
|
24194
|
+
return exception;
|
|
24195
|
+
hasRequiredException = 1;
|
|
24196
|
+
function formatError(exception2, compact) {
|
|
24190
24197
|
let where = "";
|
|
24191
|
-
const message =
|
|
24192
|
-
if (!
|
|
24198
|
+
const message = exception2.reason || "(unknown reason)";
|
|
24199
|
+
if (!exception2.mark)
|
|
24193
24200
|
return message;
|
|
24194
|
-
if (
|
|
24195
|
-
where += 'in "' +
|
|
24196
|
-
|
|
24197
|
-
|
|
24201
|
+
if (exception2.mark.name) {
|
|
24202
|
+
where += 'in "' + exception2.mark.name + '" ';
|
|
24203
|
+
}
|
|
24204
|
+
where += "(" + (exception2.mark.line + 1) + ":" + (exception2.mark.column + 1) + ")";
|
|
24205
|
+
if (!compact && exception2.mark.snippet) {
|
|
24198
24206
|
where += `
|
|
24199
24207
|
|
|
24200
|
-
` +
|
|
24208
|
+
` + exception2.mark.snippet;
|
|
24209
|
+
}
|
|
24201
24210
|
return message + " " + where;
|
|
24202
24211
|
}
|
|
24203
|
-
function
|
|
24212
|
+
function YAMLException2(reason, mark) {
|
|
24204
24213
|
Error.call(this);
|
|
24205
24214
|
this.name = "YAMLException";
|
|
24206
24215
|
this.reason = reason;
|
|
24207
24216
|
this.mark = mark;
|
|
24208
24217
|
this.message = formatError(this, false);
|
|
24209
|
-
if (Error.captureStackTrace)
|
|
24218
|
+
if (Error.captureStackTrace) {
|
|
24210
24219
|
Error.captureStackTrace(this, this.constructor);
|
|
24211
|
-
else
|
|
24212
|
-
this.stack =
|
|
24220
|
+
} else {
|
|
24221
|
+
this.stack = new Error().stack || "";
|
|
24222
|
+
}
|
|
24213
24223
|
}
|
|
24214
|
-
|
|
24215
|
-
|
|
24216
|
-
|
|
24224
|
+
YAMLException2.prototype = Object.create(Error.prototype);
|
|
24225
|
+
YAMLException2.prototype.constructor = YAMLException2;
|
|
24226
|
+
YAMLException2.prototype.toString = function toString(compact) {
|
|
24217
24227
|
return this.name + ": " + formatError(this, compact);
|
|
24218
24228
|
};
|
|
24219
|
-
|
|
24220
|
-
|
|
24221
|
-
|
|
24222
|
-
|
|
24229
|
+
exception = YAMLException2;
|
|
24230
|
+
return exception;
|
|
24231
|
+
}
|
|
24232
|
+
var snippet;
|
|
24233
|
+
var hasRequiredSnippet;
|
|
24234
|
+
function requireSnippet() {
|
|
24235
|
+
if (hasRequiredSnippet)
|
|
24236
|
+
return snippet;
|
|
24237
|
+
hasRequiredSnippet = 1;
|
|
24238
|
+
const common2 = requireCommon();
|
|
24223
24239
|
function getLine(buffer, lineStart, lineEnd, position, maxLineLength) {
|
|
24224
24240
|
let head = "";
|
|
24225
24241
|
let tail = "";
|
|
@@ -24238,7 +24254,7 @@ var require_snippet = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
24238
24254
|
};
|
|
24239
24255
|
}
|
|
24240
24256
|
function padStart(string, max) {
|
|
24241
|
-
return
|
|
24257
|
+
return common2.repeat(" ", max - string.length) + string;
|
|
24242
24258
|
}
|
|
24243
24259
|
function makeSnippet(mark, options) {
|
|
24244
24260
|
options = Object.create(options || null);
|
|
@@ -24260,8 +24276,9 @@ var require_snippet = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
24260
24276
|
while (match = re.exec(mark.buffer)) {
|
|
24261
24277
|
lineEnds.push(match.index);
|
|
24262
24278
|
lineStarts.push(match.index + match[0].length);
|
|
24263
|
-
if (mark.position <= match.index && foundLineNo < 0)
|
|
24279
|
+
if (mark.position <= match.index && foundLineNo < 0) {
|
|
24264
24280
|
foundLineNo = lineStarts.length - 2;
|
|
24281
|
+
}
|
|
24265
24282
|
}
|
|
24266
24283
|
if (foundLineNo < 0)
|
|
24267
24284
|
foundLineNo = lineStarts.length - 1;
|
|
@@ -24272,28 +24289,34 @@ var require_snippet = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
24272
24289
|
if (foundLineNo - i < 0)
|
|
24273
24290
|
break;
|
|
24274
24291
|
const line2 = getLine(mark.buffer, lineStarts[foundLineNo - i], lineEnds[foundLineNo - i], mark.position - (lineStarts[foundLineNo] - lineStarts[foundLineNo - i]), maxLineLength);
|
|
24275
|
-
result =
|
|
24292
|
+
result = common2.repeat(" ", options.indent) + padStart((mark.line - i + 1).toString(), lineNoLength) + " | " + line2.str + `
|
|
24276
24293
|
` + result;
|
|
24277
24294
|
}
|
|
24278
24295
|
const line = getLine(mark.buffer, lineStarts[foundLineNo], lineEnds[foundLineNo], mark.position, maxLineLength);
|
|
24279
|
-
result +=
|
|
24296
|
+
result += common2.repeat(" ", options.indent) + padStart((mark.line + 1).toString(), lineNoLength) + " | " + line.str + `
|
|
24280
24297
|
`;
|
|
24281
|
-
result +=
|
|
24298
|
+
result += common2.repeat("-", options.indent + lineNoLength + 3 + line.pos) + `^
|
|
24282
24299
|
`;
|
|
24283
24300
|
for (let i = 1;i <= options.linesAfter; i++) {
|
|
24284
24301
|
if (foundLineNo + i >= lineEnds.length)
|
|
24285
24302
|
break;
|
|
24286
24303
|
const line2 = getLine(mark.buffer, lineStarts[foundLineNo + i], lineEnds[foundLineNo + i], mark.position - (lineStarts[foundLineNo] - lineStarts[foundLineNo + i]), maxLineLength);
|
|
24287
|
-
result +=
|
|
24304
|
+
result += common2.repeat(" ", options.indent) + padStart((mark.line + i + 1).toString(), lineNoLength) + " | " + line2.str + `
|
|
24288
24305
|
`;
|
|
24289
24306
|
}
|
|
24290
24307
|
return result.replace(/\n$/, "");
|
|
24291
24308
|
}
|
|
24292
|
-
|
|
24293
|
-
|
|
24294
|
-
|
|
24295
|
-
|
|
24296
|
-
|
|
24309
|
+
snippet = makeSnippet;
|
|
24310
|
+
return snippet;
|
|
24311
|
+
}
|
|
24312
|
+
var type;
|
|
24313
|
+
var hasRequiredType;
|
|
24314
|
+
function requireType() {
|
|
24315
|
+
if (hasRequiredType)
|
|
24316
|
+
return type;
|
|
24317
|
+
hasRequiredType = 1;
|
|
24318
|
+
const YAMLException2 = requireException();
|
|
24319
|
+
const TYPE_CONSTRUCTOR_OPTIONS = [
|
|
24297
24320
|
"kind",
|
|
24298
24321
|
"multi",
|
|
24299
24322
|
"resolve",
|
|
@@ -24305,26 +24328,28 @@ var require_type = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
24305
24328
|
"defaultStyle",
|
|
24306
24329
|
"styleAliases"
|
|
24307
24330
|
];
|
|
24308
|
-
|
|
24331
|
+
const YAML_NODE_KINDS = [
|
|
24309
24332
|
"scalar",
|
|
24310
24333
|
"sequence",
|
|
24311
24334
|
"mapping"
|
|
24312
24335
|
];
|
|
24313
|
-
function compileStyleAliases(
|
|
24336
|
+
function compileStyleAliases(map2) {
|
|
24314
24337
|
const result = {};
|
|
24315
|
-
if (
|
|
24316
|
-
Object.keys(
|
|
24317
|
-
|
|
24338
|
+
if (map2 !== null) {
|
|
24339
|
+
Object.keys(map2).forEach(function(style) {
|
|
24340
|
+
map2[style].forEach(function(alias) {
|
|
24318
24341
|
result[String(alias)] = style;
|
|
24319
24342
|
});
|
|
24320
24343
|
});
|
|
24344
|
+
}
|
|
24321
24345
|
return result;
|
|
24322
24346
|
}
|
|
24323
|
-
function
|
|
24347
|
+
function Type2(tag, options) {
|
|
24324
24348
|
options = options || {};
|
|
24325
24349
|
Object.keys(options).forEach(function(name) {
|
|
24326
|
-
if (TYPE_CONSTRUCTOR_OPTIONS.indexOf(name) === -1)
|
|
24327
|
-
throw new
|
|
24350
|
+
if (TYPE_CONSTRUCTOR_OPTIONS.indexOf(name) === -1) {
|
|
24351
|
+
throw new YAMLException2('Unknown option "' + name + '" is met in definition of "' + tag + '" YAML type.');
|
|
24352
|
+
}
|
|
24328
24353
|
});
|
|
24329
24354
|
this.options = options;
|
|
24330
24355
|
this.tag = tag;
|
|
@@ -24342,21 +24367,29 @@ var require_type = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
24342
24367
|
this.defaultStyle = options["defaultStyle"] || null;
|
|
24343
24368
|
this.multi = options["multi"] || false;
|
|
24344
24369
|
this.styleAliases = compileStyleAliases(options["styleAliases"] || null);
|
|
24345
|
-
if (YAML_NODE_KINDS.indexOf(this.kind) === -1)
|
|
24346
|
-
throw new
|
|
24370
|
+
if (YAML_NODE_KINDS.indexOf(this.kind) === -1) {
|
|
24371
|
+
throw new YAMLException2('Unknown kind "' + this.kind + '" is specified for "' + tag + '" YAML type.');
|
|
24372
|
+
}
|
|
24347
24373
|
}
|
|
24348
|
-
|
|
24349
|
-
|
|
24350
|
-
|
|
24351
|
-
|
|
24352
|
-
|
|
24353
|
-
|
|
24374
|
+
type = Type2;
|
|
24375
|
+
return type;
|
|
24376
|
+
}
|
|
24377
|
+
var schema;
|
|
24378
|
+
var hasRequiredSchema;
|
|
24379
|
+
function requireSchema() {
|
|
24380
|
+
if (hasRequiredSchema)
|
|
24381
|
+
return schema;
|
|
24382
|
+
hasRequiredSchema = 1;
|
|
24383
|
+
const YAMLException2 = requireException();
|
|
24384
|
+
const Type2 = requireType();
|
|
24385
|
+
function compileList(schema2, name) {
|
|
24354
24386
|
const result = [];
|
|
24355
|
-
|
|
24387
|
+
schema2[name].forEach(function(currentType) {
|
|
24356
24388
|
let newIndex = result.length;
|
|
24357
24389
|
result.forEach(function(previousType, previousIndex) {
|
|
24358
|
-
if (previousType.tag === currentType.tag && previousType.kind === currentType.kind && previousType.multi === currentType.multi)
|
|
24390
|
+
if (previousType.tag === currentType.tag && previousType.kind === currentType.kind && previousType.multi === currentType.multi) {
|
|
24359
24391
|
newIndex = previousIndex;
|
|
24392
|
+
}
|
|
24360
24393
|
});
|
|
24361
24394
|
result[newIndex] = currentType;
|
|
24362
24395
|
});
|
|
@@ -24375,47 +24408,54 @@ var require_schema = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
24375
24408
|
fallback: []
|
|
24376
24409
|
}
|
|
24377
24410
|
};
|
|
24378
|
-
function collectType(
|
|
24379
|
-
if (
|
|
24380
|
-
result.multi[
|
|
24381
|
-
result.multi["fallback"].push(
|
|
24382
|
-
} else
|
|
24383
|
-
result[
|
|
24411
|
+
function collectType(type2) {
|
|
24412
|
+
if (type2.multi) {
|
|
24413
|
+
result.multi[type2.kind].push(type2);
|
|
24414
|
+
result.multi["fallback"].push(type2);
|
|
24415
|
+
} else {
|
|
24416
|
+
result[type2.kind][type2.tag] = result["fallback"][type2.tag] = type2;
|
|
24417
|
+
}
|
|
24384
24418
|
}
|
|
24385
|
-
for (let index = 0, length = arguments.length;index < length; index += 1)
|
|
24419
|
+
for (let index = 0, length = arguments.length;index < length; index += 1) {
|
|
24386
24420
|
arguments[index].forEach(collectType);
|
|
24421
|
+
}
|
|
24387
24422
|
return result;
|
|
24388
24423
|
}
|
|
24389
|
-
function
|
|
24424
|
+
function Schema2(definition) {
|
|
24390
24425
|
return this.extend(definition);
|
|
24391
24426
|
}
|
|
24392
|
-
|
|
24427
|
+
Schema2.prototype.extend = function extend(definition) {
|
|
24393
24428
|
let implicit = [];
|
|
24394
24429
|
let explicit = [];
|
|
24395
|
-
if (definition instanceof
|
|
24430
|
+
if (definition instanceof Type2) {
|
|
24396
24431
|
explicit.push(definition);
|
|
24397
|
-
else if (Array.isArray(definition))
|
|
24432
|
+
} else if (Array.isArray(definition)) {
|
|
24398
24433
|
explicit = explicit.concat(definition);
|
|
24399
|
-
else if (definition && (Array.isArray(definition.implicit) || Array.isArray(definition.explicit))) {
|
|
24434
|
+
} else if (definition && (Array.isArray(definition.implicit) || Array.isArray(definition.explicit))) {
|
|
24400
24435
|
if (definition.implicit)
|
|
24401
24436
|
implicit = implicit.concat(definition.implicit);
|
|
24402
24437
|
if (definition.explicit)
|
|
24403
24438
|
explicit = explicit.concat(definition.explicit);
|
|
24404
|
-
} else
|
|
24405
|
-
throw new
|
|
24406
|
-
|
|
24407
|
-
|
|
24408
|
-
|
|
24409
|
-
|
|
24410
|
-
|
|
24411
|
-
if (
|
|
24412
|
-
throw new
|
|
24439
|
+
} else {
|
|
24440
|
+
throw new YAMLException2("Schema.extend argument should be a Type, [ Type ], or a schema definition ({ implicit: [...], explicit: [...] })");
|
|
24441
|
+
}
|
|
24442
|
+
implicit.forEach(function(type2) {
|
|
24443
|
+
if (!(type2 instanceof Type2)) {
|
|
24444
|
+
throw new YAMLException2("Specified list of YAML types (or a single Type object) contains a non-Type object.");
|
|
24445
|
+
}
|
|
24446
|
+
if (type2.loadKind && type2.loadKind !== "scalar") {
|
|
24447
|
+
throw new YAMLException2("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.");
|
|
24448
|
+
}
|
|
24449
|
+
if (type2.multi) {
|
|
24450
|
+
throw new YAMLException2("There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.");
|
|
24451
|
+
}
|
|
24413
24452
|
});
|
|
24414
|
-
explicit.forEach(function(
|
|
24415
|
-
if (!(
|
|
24416
|
-
throw new
|
|
24453
|
+
explicit.forEach(function(type2) {
|
|
24454
|
+
if (!(type2 instanceof Type2)) {
|
|
24455
|
+
throw new YAMLException2("Specified list of YAML types (or a single Type object) contains a non-Type object.");
|
|
24456
|
+
}
|
|
24417
24457
|
});
|
|
24418
|
-
const result = Object.create(
|
|
24458
|
+
const result = Object.create(Schema2.prototype);
|
|
24419
24459
|
result.implicit = (this.implicit || []).concat(implicit);
|
|
24420
24460
|
result.explicit = (this.explicit || []).concat(explicit);
|
|
24421
24461
|
result.compiledImplicit = compileList(result, "implicit");
|
|
@@ -24423,41 +24463,77 @@ var require_schema = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
24423
24463
|
result.compiledTypeMap = compileMap(result.compiledImplicit, result.compiledExplicit);
|
|
24424
24464
|
return result;
|
|
24425
24465
|
};
|
|
24426
|
-
|
|
24427
|
-
|
|
24428
|
-
|
|
24429
|
-
|
|
24466
|
+
schema = Schema2;
|
|
24467
|
+
return schema;
|
|
24468
|
+
}
|
|
24469
|
+
var str;
|
|
24470
|
+
var hasRequiredStr;
|
|
24471
|
+
function requireStr() {
|
|
24472
|
+
if (hasRequiredStr)
|
|
24473
|
+
return str;
|
|
24474
|
+
hasRequiredStr = 1;
|
|
24475
|
+
const Type2 = requireType();
|
|
24476
|
+
str = new Type2("tag:yaml.org,2002:str", {
|
|
24430
24477
|
kind: "scalar",
|
|
24431
24478
|
construct: function(data) {
|
|
24432
24479
|
return data !== null ? data : "";
|
|
24433
24480
|
}
|
|
24434
24481
|
});
|
|
24435
|
-
|
|
24436
|
-
|
|
24437
|
-
|
|
24482
|
+
return str;
|
|
24483
|
+
}
|
|
24484
|
+
var seq;
|
|
24485
|
+
var hasRequiredSeq;
|
|
24486
|
+
function requireSeq() {
|
|
24487
|
+
if (hasRequiredSeq)
|
|
24488
|
+
return seq;
|
|
24489
|
+
hasRequiredSeq = 1;
|
|
24490
|
+
const Type2 = requireType();
|
|
24491
|
+
seq = new Type2("tag:yaml.org,2002:seq", {
|
|
24438
24492
|
kind: "sequence",
|
|
24439
24493
|
construct: function(data) {
|
|
24440
24494
|
return data !== null ? data : [];
|
|
24441
24495
|
}
|
|
24442
24496
|
});
|
|
24443
|
-
|
|
24444
|
-
|
|
24445
|
-
|
|
24497
|
+
return seq;
|
|
24498
|
+
}
|
|
24499
|
+
var map;
|
|
24500
|
+
var hasRequiredMap;
|
|
24501
|
+
function requireMap() {
|
|
24502
|
+
if (hasRequiredMap)
|
|
24503
|
+
return map;
|
|
24504
|
+
hasRequiredMap = 1;
|
|
24505
|
+
const Type2 = requireType();
|
|
24506
|
+
map = new Type2("tag:yaml.org,2002:map", {
|
|
24446
24507
|
kind: "mapping",
|
|
24447
24508
|
construct: function(data) {
|
|
24448
24509
|
return data !== null ? data : {};
|
|
24449
24510
|
}
|
|
24450
24511
|
});
|
|
24451
|
-
|
|
24452
|
-
|
|
24453
|
-
|
|
24454
|
-
|
|
24455
|
-
|
|
24456
|
-
|
|
24457
|
-
|
|
24458
|
-
|
|
24459
|
-
|
|
24460
|
-
|
|
24512
|
+
return map;
|
|
24513
|
+
}
|
|
24514
|
+
var failsafe;
|
|
24515
|
+
var hasRequiredFailsafe;
|
|
24516
|
+
function requireFailsafe() {
|
|
24517
|
+
if (hasRequiredFailsafe)
|
|
24518
|
+
return failsafe;
|
|
24519
|
+
hasRequiredFailsafe = 1;
|
|
24520
|
+
const Schema2 = requireSchema();
|
|
24521
|
+
failsafe = new Schema2({
|
|
24522
|
+
explicit: [
|
|
24523
|
+
requireStr(),
|
|
24524
|
+
requireSeq(),
|
|
24525
|
+
requireMap()
|
|
24526
|
+
]
|
|
24527
|
+
});
|
|
24528
|
+
return failsafe;
|
|
24529
|
+
}
|
|
24530
|
+
var _null;
|
|
24531
|
+
var hasRequired_null;
|
|
24532
|
+
function require_null() {
|
|
24533
|
+
if (hasRequired_null)
|
|
24534
|
+
return _null;
|
|
24535
|
+
hasRequired_null = 1;
|
|
24536
|
+
const Type2 = requireType();
|
|
24461
24537
|
function resolveYamlNull(data) {
|
|
24462
24538
|
if (data === null)
|
|
24463
24539
|
return true;
|
|
@@ -24470,7 +24546,7 @@ var require_null = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
24470
24546
|
function isNull(object) {
|
|
24471
24547
|
return object === null;
|
|
24472
24548
|
}
|
|
24473
|
-
|
|
24549
|
+
_null = new Type2("tag:yaml.org,2002:null", {
|
|
24474
24550
|
kind: "scalar",
|
|
24475
24551
|
resolve: resolveYamlNull,
|
|
24476
24552
|
construct: constructYamlNull,
|
|
@@ -24494,9 +24570,15 @@ var require_null = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
24494
24570
|
},
|
|
24495
24571
|
defaultStyle: "lowercase"
|
|
24496
24572
|
});
|
|
24497
|
-
|
|
24498
|
-
|
|
24499
|
-
|
|
24573
|
+
return _null;
|
|
24574
|
+
}
|
|
24575
|
+
var bool;
|
|
24576
|
+
var hasRequiredBool;
|
|
24577
|
+
function requireBool() {
|
|
24578
|
+
if (hasRequiredBool)
|
|
24579
|
+
return bool;
|
|
24580
|
+
hasRequiredBool = 1;
|
|
24581
|
+
const Type2 = requireType();
|
|
24500
24582
|
function resolveYamlBoolean(data) {
|
|
24501
24583
|
if (data === null)
|
|
24502
24584
|
return false;
|
|
@@ -24509,7 +24591,7 @@ var require_bool = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
24509
24591
|
function isBoolean(object) {
|
|
24510
24592
|
return Object.prototype.toString.call(object) === "[object Boolean]";
|
|
24511
24593
|
}
|
|
24512
|
-
|
|
24594
|
+
bool = new Type2("tag:yaml.org,2002:bool", {
|
|
24513
24595
|
kind: "scalar",
|
|
24514
24596
|
resolve: resolveYamlBoolean,
|
|
24515
24597
|
construct: constructYamlBoolean,
|
|
@@ -24527,10 +24609,16 @@ var require_bool = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
24527
24609
|
},
|
|
24528
24610
|
defaultStyle: "lowercase"
|
|
24529
24611
|
});
|
|
24530
|
-
|
|
24531
|
-
|
|
24532
|
-
|
|
24533
|
-
|
|
24612
|
+
return bool;
|
|
24613
|
+
}
|
|
24614
|
+
var int;
|
|
24615
|
+
var hasRequiredInt;
|
|
24616
|
+
function requireInt() {
|
|
24617
|
+
if (hasRequiredInt)
|
|
24618
|
+
return int;
|
|
24619
|
+
hasRequiredInt = 1;
|
|
24620
|
+
const common2 = requireCommon();
|
|
24621
|
+
const Type2 = requireType();
|
|
24534
24622
|
function isHexCode(c) {
|
|
24535
24623
|
return c >= 48 && c <= 57 || c >= 65 && c <= 70 || c >= 97 && c <= 102;
|
|
24536
24624
|
}
|
|
@@ -24549,8 +24637,9 @@ var require_int = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
24549
24637
|
if (!max)
|
|
24550
24638
|
return false;
|
|
24551
24639
|
let ch = data[index];
|
|
24552
|
-
if (ch === "-" || ch === "+")
|
|
24640
|
+
if (ch === "-" || ch === "+") {
|
|
24553
24641
|
ch = data[++index];
|
|
24642
|
+
}
|
|
24554
24643
|
if (ch === "0") {
|
|
24555
24644
|
if (index + 1 === max)
|
|
24556
24645
|
return true;
|
|
@@ -24563,7 +24652,7 @@ var require_int = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
24563
24652
|
return false;
|
|
24564
24653
|
hasDigits = true;
|
|
24565
24654
|
}
|
|
24566
|
-
return hasDigits &&
|
|
24655
|
+
return hasDigits && isFinite(parseYamlInteger(data));
|
|
24567
24656
|
}
|
|
24568
24657
|
if (ch === "x") {
|
|
24569
24658
|
index++;
|
|
@@ -24572,7 +24661,7 @@ var require_int = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
24572
24661
|
return false;
|
|
24573
24662
|
hasDigits = true;
|
|
24574
24663
|
}
|
|
24575
|
-
return hasDigits &&
|
|
24664
|
+
return hasDigits && isFinite(parseYamlInteger(data));
|
|
24576
24665
|
}
|
|
24577
24666
|
if (ch === "o") {
|
|
24578
24667
|
index++;
|
|
@@ -24581,17 +24670,18 @@ var require_int = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
24581
24670
|
return false;
|
|
24582
24671
|
hasDigits = true;
|
|
24583
24672
|
}
|
|
24584
|
-
return hasDigits &&
|
|
24673
|
+
return hasDigits && isFinite(parseYamlInteger(data));
|
|
24585
24674
|
}
|
|
24586
24675
|
}
|
|
24587
24676
|
for (;index < max; index++) {
|
|
24588
|
-
if (!isDecCode(data.charCodeAt(index)))
|
|
24677
|
+
if (!isDecCode(data.charCodeAt(index))) {
|
|
24589
24678
|
return false;
|
|
24679
|
+
}
|
|
24590
24680
|
hasDigits = true;
|
|
24591
24681
|
}
|
|
24592
24682
|
if (!hasDigits)
|
|
24593
24683
|
return false;
|
|
24594
|
-
return
|
|
24684
|
+
return isFinite(parseYamlInteger(data));
|
|
24595
24685
|
}
|
|
24596
24686
|
function parseYamlInteger(data) {
|
|
24597
24687
|
let value = data;
|
|
@@ -24619,9 +24709,9 @@ var require_int = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
24619
24709
|
return parseYamlInteger(data);
|
|
24620
24710
|
}
|
|
24621
24711
|
function isInteger(object) {
|
|
24622
|
-
return Object.prototype.toString.call(object) === "[object Number]" && object % 1 === 0 && !
|
|
24712
|
+
return Object.prototype.toString.call(object) === "[object Number]" && (object % 1 === 0 && !common2.isNegativeZero(object));
|
|
24623
24713
|
}
|
|
24624
|
-
|
|
24714
|
+
int = new Type2("tag:yaml.org,2002:int", {
|
|
24625
24715
|
kind: "scalar",
|
|
24626
24716
|
resolve: resolveYamlInteger,
|
|
24627
24717
|
construct: constructYamlInteger,
|
|
@@ -24648,35 +24738,45 @@ var require_int = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
24648
24738
|
hexadecimal: [16, "hex"]
|
|
24649
24739
|
}
|
|
24650
24740
|
});
|
|
24651
|
-
|
|
24652
|
-
|
|
24653
|
-
|
|
24654
|
-
|
|
24655
|
-
|
|
24656
|
-
|
|
24741
|
+
return int;
|
|
24742
|
+
}
|
|
24743
|
+
var float;
|
|
24744
|
+
var hasRequiredFloat;
|
|
24745
|
+
function requireFloat() {
|
|
24746
|
+
if (hasRequiredFloat)
|
|
24747
|
+
return float;
|
|
24748
|
+
hasRequiredFloat = 1;
|
|
24749
|
+
const common2 = requireCommon();
|
|
24750
|
+
const Type2 = requireType();
|
|
24751
|
+
const YAML_FLOAT_PATTERN = new RegExp("^(?:[-+]?(?:[0-9]+)(?:\\.[0-9]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$");
|
|
24752
|
+
const YAML_FLOAT_SPECIAL_PATTERN = new RegExp("^(?:[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$");
|
|
24657
24753
|
function resolveYamlFloat(data) {
|
|
24658
24754
|
if (data === null)
|
|
24659
24755
|
return false;
|
|
24660
|
-
if (!YAML_FLOAT_PATTERN.test(data))
|
|
24756
|
+
if (!YAML_FLOAT_PATTERN.test(data)) {
|
|
24661
24757
|
return false;
|
|
24662
|
-
|
|
24758
|
+
}
|
|
24759
|
+
if (isFinite(parseFloat(data, 10))) {
|
|
24663
24760
|
return true;
|
|
24761
|
+
}
|
|
24664
24762
|
return YAML_FLOAT_SPECIAL_PATTERN.test(data);
|
|
24665
24763
|
}
|
|
24666
24764
|
function constructYamlFloat(data) {
|
|
24667
24765
|
let value = data.toLowerCase();
|
|
24668
24766
|
const sign = value[0] === "-" ? -1 : 1;
|
|
24669
|
-
if ("+-".indexOf(value[0]) >= 0)
|
|
24767
|
+
if ("+-".indexOf(value[0]) >= 0) {
|
|
24670
24768
|
value = value.slice(1);
|
|
24671
|
-
|
|
24769
|
+
}
|
|
24770
|
+
if (value === ".inf") {
|
|
24672
24771
|
return sign === 1 ? Number.POSITIVE_INFINITY : Number.NEGATIVE_INFINITY;
|
|
24673
|
-
else if (value === ".nan")
|
|
24772
|
+
} else if (value === ".nan") {
|
|
24674
24773
|
return NaN;
|
|
24774
|
+
}
|
|
24675
24775
|
return sign * parseFloat(value, 10);
|
|
24676
24776
|
}
|
|
24677
|
-
|
|
24777
|
+
const SCIENTIFIC_WITHOUT_DOT = /^[-+]?[0-9]+e/;
|
|
24678
24778
|
function representYamlFloat(object, style) {
|
|
24679
|
-
if (isNaN(object))
|
|
24779
|
+
if (isNaN(object)) {
|
|
24680
24780
|
switch (style) {
|
|
24681
24781
|
case "lowercase":
|
|
24682
24782
|
return ".nan";
|
|
@@ -24685,7 +24785,7 @@ var require_float = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
24685
24785
|
case "camelcase":
|
|
24686
24786
|
return ".NaN";
|
|
24687
24787
|
}
|
|
24688
|
-
else if (Number.POSITIVE_INFINITY === object)
|
|
24788
|
+
} else if (Number.POSITIVE_INFINITY === object) {
|
|
24689
24789
|
switch (style) {
|
|
24690
24790
|
case "lowercase":
|
|
24691
24791
|
return ".inf";
|
|
@@ -24694,7 +24794,7 @@ var require_float = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
24694
24794
|
case "camelcase":
|
|
24695
24795
|
return ".Inf";
|
|
24696
24796
|
}
|
|
24697
|
-
else if (Number.NEGATIVE_INFINITY === object)
|
|
24797
|
+
} else if (Number.NEGATIVE_INFINITY === object) {
|
|
24698
24798
|
switch (style) {
|
|
24699
24799
|
case "lowercase":
|
|
24700
24800
|
return "-.inf";
|
|
@@ -24703,15 +24803,16 @@ var require_float = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
24703
24803
|
case "camelcase":
|
|
24704
24804
|
return "-.Inf";
|
|
24705
24805
|
}
|
|
24706
|
-
else if (
|
|
24806
|
+
} else if (common2.isNegativeZero(object)) {
|
|
24707
24807
|
return "-0.0";
|
|
24808
|
+
}
|
|
24708
24809
|
const res = object.toString(10);
|
|
24709
24810
|
return SCIENTIFIC_WITHOUT_DOT.test(res) ? res.replace("e", ".e") : res;
|
|
24710
24811
|
}
|
|
24711
24812
|
function isFloat(object) {
|
|
24712
|
-
return Object.prototype.toString.call(object) === "[object Number]" && (object % 1 !== 0 ||
|
|
24813
|
+
return Object.prototype.toString.call(object) === "[object Number]" && (object % 1 !== 0 || common2.isNegativeZero(object));
|
|
24713
24814
|
}
|
|
24714
|
-
|
|
24815
|
+
float = new Type2("tag:yaml.org,2002:float", {
|
|
24715
24816
|
kind: "scalar",
|
|
24716
24817
|
resolve: resolveYamlFloat,
|
|
24717
24818
|
construct: constructYamlFloat,
|
|
@@ -24719,22 +24820,42 @@ var require_float = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
24719
24820
|
represent: representYamlFloat,
|
|
24720
24821
|
defaultStyle: "lowercase"
|
|
24721
24822
|
});
|
|
24722
|
-
|
|
24723
|
-
|
|
24724
|
-
|
|
24725
|
-
|
|
24726
|
-
|
|
24727
|
-
|
|
24728
|
-
|
|
24729
|
-
|
|
24730
|
-
|
|
24731
|
-
|
|
24732
|
-
|
|
24733
|
-
|
|
24734
|
-
|
|
24735
|
-
|
|
24736
|
-
|
|
24737
|
-
|
|
24823
|
+
return float;
|
|
24824
|
+
}
|
|
24825
|
+
var json;
|
|
24826
|
+
var hasRequiredJson;
|
|
24827
|
+
function requireJson() {
|
|
24828
|
+
if (hasRequiredJson)
|
|
24829
|
+
return json;
|
|
24830
|
+
hasRequiredJson = 1;
|
|
24831
|
+
json = requireFailsafe().extend({
|
|
24832
|
+
implicit: [
|
|
24833
|
+
require_null(),
|
|
24834
|
+
requireBool(),
|
|
24835
|
+
requireInt(),
|
|
24836
|
+
requireFloat()
|
|
24837
|
+
]
|
|
24838
|
+
});
|
|
24839
|
+
return json;
|
|
24840
|
+
}
|
|
24841
|
+
var core;
|
|
24842
|
+
var hasRequiredCore;
|
|
24843
|
+
function requireCore() {
|
|
24844
|
+
if (hasRequiredCore)
|
|
24845
|
+
return core;
|
|
24846
|
+
hasRequiredCore = 1;
|
|
24847
|
+
core = requireJson();
|
|
24848
|
+
return core;
|
|
24849
|
+
}
|
|
24850
|
+
var timestamp;
|
|
24851
|
+
var hasRequiredTimestamp;
|
|
24852
|
+
function requireTimestamp() {
|
|
24853
|
+
if (hasRequiredTimestamp)
|
|
24854
|
+
return timestamp;
|
|
24855
|
+
hasRequiredTimestamp = 1;
|
|
24856
|
+
const Type2 = requireType();
|
|
24857
|
+
const YAML_DATE_REGEXP = new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$");
|
|
24858
|
+
const YAML_TIMESTAMP_REGEXP = new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$");
|
|
24738
24859
|
function resolveYamlTimestamp(data) {
|
|
24739
24860
|
if (data === null)
|
|
24740
24861
|
return false;
|
|
@@ -24755,15 +24876,17 @@ var require_timestamp = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
24755
24876
|
const year = +match[1];
|
|
24756
24877
|
const month = +match[2] - 1;
|
|
24757
24878
|
const day = +match[3];
|
|
24758
|
-
if (!match[4])
|
|
24879
|
+
if (!match[4]) {
|
|
24759
24880
|
return new Date(Date.UTC(year, month, day));
|
|
24881
|
+
}
|
|
24760
24882
|
const hour = +match[4];
|
|
24761
24883
|
const minute = +match[5];
|
|
24762
24884
|
const second = +match[6];
|
|
24763
24885
|
if (match[7]) {
|
|
24764
24886
|
fraction = match[7].slice(0, 3);
|
|
24765
|
-
while (fraction.length < 3)
|
|
24887
|
+
while (fraction.length < 3) {
|
|
24766
24888
|
fraction += "0";
|
|
24889
|
+
}
|
|
24767
24890
|
fraction = +fraction;
|
|
24768
24891
|
}
|
|
24769
24892
|
if (match[9]) {
|
|
@@ -24781,36 +24904,48 @@ var require_timestamp = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
24781
24904
|
function representYamlTimestamp(object) {
|
|
24782
24905
|
return object.toISOString();
|
|
24783
24906
|
}
|
|
24784
|
-
|
|
24907
|
+
timestamp = new Type2("tag:yaml.org,2002:timestamp", {
|
|
24785
24908
|
kind: "scalar",
|
|
24786
24909
|
resolve: resolveYamlTimestamp,
|
|
24787
24910
|
construct: constructYamlTimestamp,
|
|
24788
24911
|
instanceOf: Date,
|
|
24789
24912
|
represent: representYamlTimestamp
|
|
24790
24913
|
});
|
|
24791
|
-
|
|
24792
|
-
|
|
24793
|
-
|
|
24914
|
+
return timestamp;
|
|
24915
|
+
}
|
|
24916
|
+
var merge;
|
|
24917
|
+
var hasRequiredMerge;
|
|
24918
|
+
function requireMerge() {
|
|
24919
|
+
if (hasRequiredMerge)
|
|
24920
|
+
return merge;
|
|
24921
|
+
hasRequiredMerge = 1;
|
|
24922
|
+
const Type2 = requireType();
|
|
24794
24923
|
function resolveYamlMerge(data) {
|
|
24795
24924
|
return data === "<<" || data === null;
|
|
24796
24925
|
}
|
|
24797
|
-
|
|
24926
|
+
merge = new Type2("tag:yaml.org,2002:merge", {
|
|
24798
24927
|
kind: "scalar",
|
|
24799
24928
|
resolve: resolveYamlMerge
|
|
24800
24929
|
});
|
|
24801
|
-
|
|
24802
|
-
|
|
24803
|
-
|
|
24804
|
-
|
|
24930
|
+
return merge;
|
|
24931
|
+
}
|
|
24932
|
+
var binary;
|
|
24933
|
+
var hasRequiredBinary;
|
|
24934
|
+
function requireBinary() {
|
|
24935
|
+
if (hasRequiredBinary)
|
|
24936
|
+
return binary;
|
|
24937
|
+
hasRequiredBinary = 1;
|
|
24938
|
+
const Type2 = requireType();
|
|
24939
|
+
const BASE64_MAP = `ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=
|
|
24805
24940
|
\r`;
|
|
24806
24941
|
function resolveYamlBinary(data) {
|
|
24807
24942
|
if (data === null)
|
|
24808
24943
|
return false;
|
|
24809
24944
|
let bitlen = 0;
|
|
24810
24945
|
const max = data.length;
|
|
24811
|
-
const
|
|
24946
|
+
const map2 = BASE64_MAP;
|
|
24812
24947
|
for (let idx = 0;idx < max; idx++) {
|
|
24813
|
-
const code =
|
|
24948
|
+
const code = map2.indexOf(data.charAt(idx));
|
|
24814
24949
|
if (code > 64)
|
|
24815
24950
|
continue;
|
|
24816
24951
|
if (code < 0)
|
|
@@ -24822,7 +24957,7 @@ var require_binary = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
24822
24957
|
function constructYamlBinary(data) {
|
|
24823
24958
|
const input = data.replace(/[\r\n=]/g, "");
|
|
24824
24959
|
const max = input.length;
|
|
24825
|
-
const
|
|
24960
|
+
const map2 = BASE64_MAP;
|
|
24826
24961
|
let bits = 0;
|
|
24827
24962
|
const result = [];
|
|
24828
24963
|
for (let idx = 0;idx < max; idx++) {
|
|
@@ -24831,7 +24966,7 @@ var require_binary = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
24831
24966
|
result.push(bits >> 8 & 255);
|
|
24832
24967
|
result.push(bits & 255);
|
|
24833
24968
|
}
|
|
24834
|
-
bits = bits << 6 |
|
|
24969
|
+
bits = bits << 6 | map2.indexOf(input.charAt(idx));
|
|
24835
24970
|
}
|
|
24836
24971
|
const tailbits = max % 4 * 6;
|
|
24837
24972
|
if (tailbits === 0) {
|
|
@@ -24841,58 +24976,65 @@ var require_binary = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
24841
24976
|
} else if (tailbits === 18) {
|
|
24842
24977
|
result.push(bits >> 10 & 255);
|
|
24843
24978
|
result.push(bits >> 2 & 255);
|
|
24844
|
-
} else if (tailbits === 12)
|
|
24979
|
+
} else if (tailbits === 12) {
|
|
24845
24980
|
result.push(bits >> 4 & 255);
|
|
24981
|
+
}
|
|
24846
24982
|
return new Uint8Array(result);
|
|
24847
24983
|
}
|
|
24848
24984
|
function representYamlBinary(object) {
|
|
24849
24985
|
let result = "";
|
|
24850
24986
|
let bits = 0;
|
|
24851
24987
|
const max = object.length;
|
|
24852
|
-
const
|
|
24988
|
+
const map2 = BASE64_MAP;
|
|
24853
24989
|
for (let idx = 0;idx < max; idx++) {
|
|
24854
24990
|
if (idx % 3 === 0 && idx) {
|
|
24855
|
-
result +=
|
|
24856
|
-
result +=
|
|
24857
|
-
result +=
|
|
24858
|
-
result +=
|
|
24991
|
+
result += map2[bits >> 18 & 63];
|
|
24992
|
+
result += map2[bits >> 12 & 63];
|
|
24993
|
+
result += map2[bits >> 6 & 63];
|
|
24994
|
+
result += map2[bits & 63];
|
|
24859
24995
|
}
|
|
24860
24996
|
bits = (bits << 8) + object[idx];
|
|
24861
24997
|
}
|
|
24862
24998
|
const tail = max % 3;
|
|
24863
24999
|
if (tail === 0) {
|
|
24864
|
-
result +=
|
|
24865
|
-
result +=
|
|
24866
|
-
result +=
|
|
24867
|
-
result +=
|
|
25000
|
+
result += map2[bits >> 18 & 63];
|
|
25001
|
+
result += map2[bits >> 12 & 63];
|
|
25002
|
+
result += map2[bits >> 6 & 63];
|
|
25003
|
+
result += map2[bits & 63];
|
|
24868
25004
|
} else if (tail === 2) {
|
|
24869
|
-
result +=
|
|
24870
|
-
result +=
|
|
24871
|
-
result +=
|
|
24872
|
-
result +=
|
|
25005
|
+
result += map2[bits >> 10 & 63];
|
|
25006
|
+
result += map2[bits >> 4 & 63];
|
|
25007
|
+
result += map2[bits << 2 & 63];
|
|
25008
|
+
result += map2[64];
|
|
24873
25009
|
} else if (tail === 1) {
|
|
24874
|
-
result +=
|
|
24875
|
-
result +=
|
|
24876
|
-
result +=
|
|
24877
|
-
result +=
|
|
25010
|
+
result += map2[bits >> 2 & 63];
|
|
25011
|
+
result += map2[bits << 4 & 63];
|
|
25012
|
+
result += map2[64];
|
|
25013
|
+
result += map2[64];
|
|
24878
25014
|
}
|
|
24879
25015
|
return result;
|
|
24880
25016
|
}
|
|
24881
25017
|
function isBinary(obj) {
|
|
24882
25018
|
return Object.prototype.toString.call(obj) === "[object Uint8Array]";
|
|
24883
25019
|
}
|
|
24884
|
-
|
|
25020
|
+
binary = new Type2("tag:yaml.org,2002:binary", {
|
|
24885
25021
|
kind: "scalar",
|
|
24886
25022
|
resolve: resolveYamlBinary,
|
|
24887
25023
|
construct: constructYamlBinary,
|
|
24888
25024
|
predicate: isBinary,
|
|
24889
25025
|
represent: representYamlBinary
|
|
24890
25026
|
});
|
|
24891
|
-
|
|
24892
|
-
|
|
24893
|
-
|
|
24894
|
-
|
|
24895
|
-
|
|
25027
|
+
return binary;
|
|
25028
|
+
}
|
|
25029
|
+
var omap;
|
|
25030
|
+
var hasRequiredOmap;
|
|
25031
|
+
function requireOmap() {
|
|
25032
|
+
if (hasRequiredOmap)
|
|
25033
|
+
return omap;
|
|
25034
|
+
hasRequiredOmap = 1;
|
|
25035
|
+
const Type2 = requireType();
|
|
25036
|
+
const _hasOwnProperty = Object.prototype.hasOwnProperty;
|
|
25037
|
+
const _toString = Object.prototype.toString;
|
|
24896
25038
|
function resolveYamlOmap(data) {
|
|
24897
25039
|
if (data === null)
|
|
24898
25040
|
return true;
|
|
@@ -24904,12 +25046,14 @@ var require_omap = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
24904
25046
|
if (_toString.call(pair) !== "[object Object]")
|
|
24905
25047
|
return false;
|
|
24906
25048
|
let pairKey;
|
|
24907
|
-
for (pairKey in pair)
|
|
24908
|
-
if (_hasOwnProperty.call(pair, pairKey))
|
|
25049
|
+
for (pairKey in pair) {
|
|
25050
|
+
if (_hasOwnProperty.call(pair, pairKey)) {
|
|
24909
25051
|
if (!pairHasKey)
|
|
24910
25052
|
pairHasKey = true;
|
|
24911
25053
|
else
|
|
24912
25054
|
return false;
|
|
25055
|
+
}
|
|
25056
|
+
}
|
|
24913
25057
|
if (!pairHasKey)
|
|
24914
25058
|
return false;
|
|
24915
25059
|
if (objectKeys.indexOf(pairKey) === -1)
|
|
@@ -24922,15 +25066,21 @@ var require_omap = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
24922
25066
|
function constructYamlOmap(data) {
|
|
24923
25067
|
return data !== null ? data : [];
|
|
24924
25068
|
}
|
|
24925
|
-
|
|
25069
|
+
omap = new Type2("tag:yaml.org,2002:omap", {
|
|
24926
25070
|
kind: "sequence",
|
|
24927
25071
|
resolve: resolveYamlOmap,
|
|
24928
25072
|
construct: constructYamlOmap
|
|
24929
25073
|
});
|
|
24930
|
-
|
|
24931
|
-
|
|
24932
|
-
|
|
24933
|
-
|
|
25074
|
+
return omap;
|
|
25075
|
+
}
|
|
25076
|
+
var pairs;
|
|
25077
|
+
var hasRequiredPairs;
|
|
25078
|
+
function requirePairs() {
|
|
25079
|
+
if (hasRequiredPairs)
|
|
25080
|
+
return pairs;
|
|
25081
|
+
hasRequiredPairs = 1;
|
|
25082
|
+
const Type2 = requireType();
|
|
25083
|
+
const _toString = Object.prototype.toString;
|
|
24934
25084
|
function resolveYamlPairs(data) {
|
|
24935
25085
|
if (data === null)
|
|
24936
25086
|
return true;
|
|
@@ -24959,64 +25109,85 @@ var require_pairs2 = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
24959
25109
|
}
|
|
24960
25110
|
return result;
|
|
24961
25111
|
}
|
|
24962
|
-
|
|
25112
|
+
pairs = new Type2("tag:yaml.org,2002:pairs", {
|
|
24963
25113
|
kind: "sequence",
|
|
24964
25114
|
resolve: resolveYamlPairs,
|
|
24965
25115
|
construct: constructYamlPairs
|
|
24966
25116
|
});
|
|
24967
|
-
|
|
24968
|
-
|
|
24969
|
-
|
|
24970
|
-
|
|
25117
|
+
return pairs;
|
|
25118
|
+
}
|
|
25119
|
+
var set;
|
|
25120
|
+
var hasRequiredSet;
|
|
25121
|
+
function requireSet() {
|
|
25122
|
+
if (hasRequiredSet)
|
|
25123
|
+
return set;
|
|
25124
|
+
hasRequiredSet = 1;
|
|
25125
|
+
const Type2 = requireType();
|
|
25126
|
+
const _hasOwnProperty = Object.prototype.hasOwnProperty;
|
|
24971
25127
|
function resolveYamlSet(data) {
|
|
24972
25128
|
if (data === null)
|
|
24973
25129
|
return true;
|
|
24974
25130
|
const object = data;
|
|
24975
|
-
for (const key in object)
|
|
25131
|
+
for (const key in object) {
|
|
24976
25132
|
if (_hasOwnProperty.call(object, key)) {
|
|
24977
25133
|
if (object[key] !== null)
|
|
24978
25134
|
return false;
|
|
24979
25135
|
}
|
|
25136
|
+
}
|
|
24980
25137
|
return true;
|
|
24981
25138
|
}
|
|
24982
25139
|
function constructYamlSet(data) {
|
|
24983
25140
|
return data !== null ? data : {};
|
|
24984
25141
|
}
|
|
24985
|
-
|
|
25142
|
+
set = new Type2("tag:yaml.org,2002:set", {
|
|
24986
25143
|
kind: "mapping",
|
|
24987
25144
|
resolve: resolveYamlSet,
|
|
24988
25145
|
construct: constructYamlSet
|
|
24989
25146
|
});
|
|
24990
|
-
|
|
24991
|
-
|
|
24992
|
-
|
|
24993
|
-
|
|
25147
|
+
return set;
|
|
25148
|
+
}
|
|
25149
|
+
var _default;
|
|
25150
|
+
var hasRequired_default;
|
|
25151
|
+
function require_default() {
|
|
25152
|
+
if (hasRequired_default)
|
|
25153
|
+
return _default;
|
|
25154
|
+
hasRequired_default = 1;
|
|
25155
|
+
_default = requireCore().extend({
|
|
25156
|
+
implicit: [
|
|
25157
|
+
requireTimestamp(),
|
|
25158
|
+
requireMerge()
|
|
25159
|
+
],
|
|
24994
25160
|
explicit: [
|
|
24995
|
-
|
|
24996
|
-
|
|
24997
|
-
|
|
24998
|
-
|
|
25161
|
+
requireBinary(),
|
|
25162
|
+
requireOmap(),
|
|
25163
|
+
requirePairs(),
|
|
25164
|
+
requireSet()
|
|
24999
25165
|
]
|
|
25000
25166
|
});
|
|
25001
|
-
|
|
25002
|
-
|
|
25003
|
-
|
|
25004
|
-
|
|
25005
|
-
|
|
25006
|
-
|
|
25007
|
-
|
|
25008
|
-
|
|
25009
|
-
|
|
25010
|
-
|
|
25011
|
-
|
|
25012
|
-
|
|
25013
|
-
|
|
25014
|
-
|
|
25015
|
-
|
|
25016
|
-
|
|
25017
|
-
|
|
25018
|
-
|
|
25019
|
-
|
|
25167
|
+
return _default;
|
|
25168
|
+
}
|
|
25169
|
+
var hasRequiredLoader;
|
|
25170
|
+
function requireLoader() {
|
|
25171
|
+
if (hasRequiredLoader)
|
|
25172
|
+
return loader;
|
|
25173
|
+
hasRequiredLoader = 1;
|
|
25174
|
+
const common2 = requireCommon();
|
|
25175
|
+
const YAMLException2 = requireException();
|
|
25176
|
+
const makeSnippet = requireSnippet();
|
|
25177
|
+
const DEFAULT_SCHEMA2 = require_default();
|
|
25178
|
+
const _hasOwnProperty = Object.prototype.hasOwnProperty;
|
|
25179
|
+
const CONTEXT_FLOW_IN = 1;
|
|
25180
|
+
const CONTEXT_FLOW_OUT = 2;
|
|
25181
|
+
const CONTEXT_BLOCK_IN = 3;
|
|
25182
|
+
const CONTEXT_BLOCK_OUT = 4;
|
|
25183
|
+
const CHOMPING_CLIP = 1;
|
|
25184
|
+
const CHOMPING_STRIP = 2;
|
|
25185
|
+
const CHOMPING_KEEP = 3;
|
|
25186
|
+
const PATTERN_NON_PRINTABLE = /[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/;
|
|
25187
|
+
const PATTERN_NON_ASCII_LINE_BREAKS = /[\x85\u2028\u2029]/;
|
|
25188
|
+
const PATTERN_FLOW_INDICATORS = /[,\[\]{}]/;
|
|
25189
|
+
const PATTERN_TAG_HANDLE = /^(?:!|!!|![0-9A-Za-z-]+!)$/;
|
|
25190
|
+
const PATTERN_TAG_URI = /^(?:!|[^,\[\]{}])(?:%[0-9a-f]{2}|[0-9a-z\-#;/?:@&=+$,_.!~*'()\[\]])*$/i;
|
|
25020
25191
|
function _class(obj) {
|
|
25021
25192
|
return Object.prototype.toString.call(obj);
|
|
25022
25193
|
}
|
|
@@ -25033,25 +25204,31 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25033
25204
|
return c === 44 || c === 91 || c === 93 || c === 123 || c === 125;
|
|
25034
25205
|
}
|
|
25035
25206
|
function fromHexCode(c) {
|
|
25036
|
-
if (c >= 48 && c <= 57)
|
|
25207
|
+
if (c >= 48 && c <= 57) {
|
|
25037
25208
|
return c - 48;
|
|
25209
|
+
}
|
|
25038
25210
|
const lc = c | 32;
|
|
25039
|
-
if (lc >= 97 && lc <= 102)
|
|
25211
|
+
if (lc >= 97 && lc <= 102) {
|
|
25040
25212
|
return lc - 97 + 10;
|
|
25213
|
+
}
|
|
25041
25214
|
return -1;
|
|
25042
25215
|
}
|
|
25043
25216
|
function escapedHexLen(c) {
|
|
25044
|
-
if (c === 120)
|
|
25217
|
+
if (c === 120) {
|
|
25045
25218
|
return 2;
|
|
25046
|
-
|
|
25219
|
+
}
|
|
25220
|
+
if (c === 117) {
|
|
25047
25221
|
return 4;
|
|
25048
|
-
|
|
25222
|
+
}
|
|
25223
|
+
if (c === 85) {
|
|
25049
25224
|
return 8;
|
|
25225
|
+
}
|
|
25050
25226
|
return 0;
|
|
25051
25227
|
}
|
|
25052
25228
|
function fromDecimalCode(c) {
|
|
25053
|
-
if (c >= 48 && c <= 57)
|
|
25229
|
+
if (c >= 48 && c <= 57) {
|
|
25054
25230
|
return c - 48;
|
|
25231
|
+
}
|
|
25055
25232
|
return -1;
|
|
25056
25233
|
}
|
|
25057
25234
|
function simpleEscapeSequence(c) {
|
|
@@ -25098,23 +25275,25 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25098
25275
|
}
|
|
25099
25276
|
}
|
|
25100
25277
|
function charFromCodepoint(c) {
|
|
25101
|
-
if (c <= 65535)
|
|
25278
|
+
if (c <= 65535) {
|
|
25102
25279
|
return String.fromCharCode(c);
|
|
25280
|
+
}
|
|
25103
25281
|
return String.fromCharCode((c - 65536 >> 10) + 55296, (c - 65536 & 1023) + 56320);
|
|
25104
25282
|
}
|
|
25105
25283
|
function setProperty(object, key, value) {
|
|
25106
|
-
if (key === "__proto__")
|
|
25284
|
+
if (key === "__proto__") {
|
|
25107
25285
|
Object.defineProperty(object, key, {
|
|
25108
25286
|
configurable: true,
|
|
25109
25287
|
enumerable: true,
|
|
25110
25288
|
writable: true,
|
|
25111
25289
|
value
|
|
25112
25290
|
});
|
|
25113
|
-
else
|
|
25291
|
+
} else {
|
|
25114
25292
|
object[key] = value;
|
|
25293
|
+
}
|
|
25115
25294
|
}
|
|
25116
|
-
|
|
25117
|
-
|
|
25295
|
+
const simpleEscapeCheck = new Array(256);
|
|
25296
|
+
const simpleEscapeMap = new Array(256);
|
|
25118
25297
|
for (let i = 0;i < 256; i++) {
|
|
25119
25298
|
simpleEscapeCheck[i] = simpleEscapeSequence(i) ? 1 : 0;
|
|
25120
25299
|
simpleEscapeMap[i] = simpleEscapeSequence(i);
|
|
@@ -25122,13 +25301,13 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25122
25301
|
function State(input, options) {
|
|
25123
25302
|
this.input = input;
|
|
25124
25303
|
this.filename = options["filename"] || null;
|
|
25125
|
-
this.schema = options["schema"] ||
|
|
25304
|
+
this.schema = options["schema"] || DEFAULT_SCHEMA2;
|
|
25126
25305
|
this.onWarning = options["onWarning"] || null;
|
|
25127
25306
|
this.legacy = options["legacy"] || false;
|
|
25128
25307
|
this.json = options["json"] || false;
|
|
25129
25308
|
this.listener = options["listener"] || null;
|
|
25130
25309
|
this.maxDepth = typeof options["maxDepth"] === "number" ? options["maxDepth"] : 100;
|
|
25131
|
-
this.
|
|
25310
|
+
this.maxTotalMergeKeys = typeof options["maxTotalMergeKeys"] === "number" ? options["maxTotalMergeKeys"] : 1e4;
|
|
25132
25311
|
this.implicitTypes = this.schema.compiledImplicit;
|
|
25133
25312
|
this.typeMap = this.schema.compiledTypeMap;
|
|
25134
25313
|
this.length = input.length;
|
|
@@ -25137,6 +25316,7 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25137
25316
|
this.lineStart = 0;
|
|
25138
25317
|
this.lineIndent = 0;
|
|
25139
25318
|
this.depth = 0;
|
|
25319
|
+
this.totalMergeKeys = 0;
|
|
25140
25320
|
this.firstTabInLine = -1;
|
|
25141
25321
|
this.documents = [];
|
|
25142
25322
|
this.anchorMapTransactions = [];
|
|
@@ -25150,29 +25330,31 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25150
25330
|
column: state.position - state.lineStart
|
|
25151
25331
|
};
|
|
25152
25332
|
mark.snippet = makeSnippet(mark);
|
|
25153
|
-
return new
|
|
25333
|
+
return new YAMLException2(message, mark);
|
|
25154
25334
|
}
|
|
25155
25335
|
function throwError(state, message) {
|
|
25156
25336
|
throw generateError(state, message);
|
|
25157
25337
|
}
|
|
25158
25338
|
function throwWarning(state, message) {
|
|
25159
|
-
if (state.onWarning)
|
|
25339
|
+
if (state.onWarning) {
|
|
25160
25340
|
state.onWarning.call(null, generateError(state, message));
|
|
25341
|
+
}
|
|
25161
25342
|
}
|
|
25162
25343
|
function storeAnchor(state, name, value) {
|
|
25163
25344
|
const transactions = state.anchorMapTransactions;
|
|
25164
25345
|
if (transactions.length !== 0) {
|
|
25165
25346
|
const transaction = transactions[transactions.length - 1];
|
|
25166
|
-
if (!_hasOwnProperty.call(transaction, name))
|
|
25347
|
+
if (!_hasOwnProperty.call(transaction, name)) {
|
|
25167
25348
|
transaction[name] = {
|
|
25168
25349
|
existed: _hasOwnProperty.call(state.anchorMap, name),
|
|
25169
25350
|
value: state.anchorMap[name]
|
|
25170
25351
|
};
|
|
25352
|
+
}
|
|
25171
25353
|
}
|
|
25172
25354
|
state.anchorMap[name] = value;
|
|
25173
25355
|
}
|
|
25174
25356
|
function beginAnchorTransaction(state) {
|
|
25175
|
-
state.anchorMapTransactions.push(Object.create(null));
|
|
25357
|
+
state.anchorMapTransactions.push(/* @__PURE__ */ Object.create(null));
|
|
25176
25358
|
}
|
|
25177
25359
|
function commitAnchorTransaction(state) {
|
|
25178
25360
|
const transaction = state.anchorMapTransactions.pop();
|
|
@@ -25183,8 +25365,9 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25183
25365
|
const names = Object.keys(transaction);
|
|
25184
25366
|
for (let index = 0, length = names.length;index < length; index += 1) {
|
|
25185
25367
|
const name = names[index];
|
|
25186
|
-
if (!_hasOwnProperty.call(parent, name))
|
|
25368
|
+
if (!_hasOwnProperty.call(parent, name)) {
|
|
25187
25369
|
parent[name] = transaction[name];
|
|
25370
|
+
}
|
|
25188
25371
|
}
|
|
25189
25372
|
}
|
|
25190
25373
|
function rollbackAnchorTransaction(state) {
|
|
@@ -25192,10 +25375,11 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25192
25375
|
const names = Object.keys(transaction);
|
|
25193
25376
|
for (let index = names.length - 1;index >= 0; index -= 1) {
|
|
25194
25377
|
const entry = transaction[names[index]];
|
|
25195
|
-
if (entry.existed)
|
|
25378
|
+
if (entry.existed) {
|
|
25196
25379
|
state.anchorMap[names[index]] = entry.value;
|
|
25197
|
-
else
|
|
25380
|
+
} else {
|
|
25198
25381
|
delete state.anchorMap[names[index]];
|
|
25382
|
+
}
|
|
25199
25383
|
}
|
|
25200
25384
|
}
|
|
25201
25385
|
function snapshotState(state) {
|
|
@@ -25222,36 +25406,45 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25222
25406
|
state.kind = snapshot.kind;
|
|
25223
25407
|
state.result = snapshot.result;
|
|
25224
25408
|
}
|
|
25225
|
-
|
|
25409
|
+
const directiveHandlers = {
|
|
25226
25410
|
YAML: function handleYamlDirective(state, name, args) {
|
|
25227
|
-
if (state.version !== null)
|
|
25411
|
+
if (state.version !== null) {
|
|
25228
25412
|
throwError(state, "duplication of %YAML directive");
|
|
25229
|
-
|
|
25413
|
+
}
|
|
25414
|
+
if (args.length !== 1) {
|
|
25230
25415
|
throwError(state, "YAML directive accepts exactly one argument");
|
|
25416
|
+
}
|
|
25231
25417
|
const match = /^([0-9]+)\.([0-9]+)$/.exec(args[0]);
|
|
25232
|
-
if (match === null)
|
|
25418
|
+
if (match === null) {
|
|
25233
25419
|
throwError(state, "ill-formed argument of the YAML directive");
|
|
25420
|
+
}
|
|
25234
25421
|
const major = parseInt(match[1], 10);
|
|
25235
25422
|
const minor = parseInt(match[2], 10);
|
|
25236
|
-
if (major !== 1)
|
|
25423
|
+
if (major !== 1) {
|
|
25237
25424
|
throwError(state, "unacceptable YAML version of the document");
|
|
25425
|
+
}
|
|
25238
25426
|
state.version = args[0];
|
|
25239
25427
|
state.checkLineBreaks = minor < 2;
|
|
25240
|
-
if (minor !== 1 && minor !== 2)
|
|
25428
|
+
if (minor !== 1 && minor !== 2) {
|
|
25241
25429
|
throwWarning(state, "unsupported YAML version of the document");
|
|
25430
|
+
}
|
|
25242
25431
|
},
|
|
25243
25432
|
TAG: function handleTagDirective(state, name, args) {
|
|
25244
25433
|
let prefix;
|
|
25245
|
-
if (args.length !== 2)
|
|
25434
|
+
if (args.length !== 2) {
|
|
25246
25435
|
throwError(state, "TAG directive accepts exactly two arguments");
|
|
25436
|
+
}
|
|
25247
25437
|
const handle = args[0];
|
|
25248
25438
|
prefix = args[1];
|
|
25249
|
-
if (!PATTERN_TAG_HANDLE.test(handle))
|
|
25439
|
+
if (!PATTERN_TAG_HANDLE.test(handle)) {
|
|
25250
25440
|
throwError(state, "ill-formed tag handle (first argument) of the TAG directive");
|
|
25251
|
-
|
|
25441
|
+
}
|
|
25442
|
+
if (_hasOwnProperty.call(state.tagMap, handle)) {
|
|
25252
25443
|
throwError(state, 'there is a previously declared suffix for "' + handle + '" tag handle');
|
|
25253
|
-
|
|
25444
|
+
}
|
|
25445
|
+
if (!PATTERN_TAG_URI.test(prefix)) {
|
|
25254
25446
|
throwError(state, "ill-formed tag prefix (second argument) of the TAG directive");
|
|
25447
|
+
}
|
|
25255
25448
|
try {
|
|
25256
25449
|
prefix = decodeURIComponent(prefix);
|
|
25257
25450
|
} catch (err) {
|
|
@@ -25263,23 +25456,29 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25263
25456
|
function captureSegment(state, start, end, checkJson) {
|
|
25264
25457
|
if (start < end) {
|
|
25265
25458
|
const _result = state.input.slice(start, end);
|
|
25266
|
-
if (checkJson)
|
|
25459
|
+
if (checkJson) {
|
|
25267
25460
|
for (let _position = 0, _length = _result.length;_position < _length; _position += 1) {
|
|
25268
25461
|
const _character = _result.charCodeAt(_position);
|
|
25269
|
-
if (!(_character === 9 || _character >= 32 && _character <= 1114111))
|
|
25462
|
+
if (!(_character === 9 || _character >= 32 && _character <= 1114111)) {
|
|
25270
25463
|
throwError(state, "expected valid JSON character");
|
|
25464
|
+
}
|
|
25271
25465
|
}
|
|
25272
|
-
else if (PATTERN_NON_PRINTABLE.test(_result))
|
|
25466
|
+
} else if (PATTERN_NON_PRINTABLE.test(_result)) {
|
|
25273
25467
|
throwError(state, "the stream contains non-printable characters");
|
|
25468
|
+
}
|
|
25274
25469
|
state.result += _result;
|
|
25275
25470
|
}
|
|
25276
25471
|
}
|
|
25277
25472
|
function mergeMappings(state, destination, source, overridableKeys) {
|
|
25278
|
-
if (!
|
|
25473
|
+
if (!common2.isObject(source)) {
|
|
25279
25474
|
throwError(state, "cannot merge mappings; the provided source object is unacceptable");
|
|
25475
|
+
}
|
|
25280
25476
|
const sourceKeys = Object.keys(source);
|
|
25281
25477
|
for (let index = 0, quantity = sourceKeys.length;index < quantity; index += 1) {
|
|
25282
25478
|
const key = sourceKeys[index];
|
|
25479
|
+
if (state.maxTotalMergeKeys !== -1 && ++state.totalMergeKeys > state.maxTotalMergeKeys) {
|
|
25480
|
+
throwError(state, "merge keys exceeded maxTotalMergeKeys (" + state.maxTotalMergeKeys + ")");
|
|
25481
|
+
}
|
|
25283
25482
|
if (!_hasOwnProperty.call(destination, key)) {
|
|
25284
25483
|
setProperty(destination, key, source[key]);
|
|
25285
25484
|
overridableKeys[key] = true;
|
|
@@ -25290,32 +25489,30 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25290
25489
|
if (Array.isArray(keyNode)) {
|
|
25291
25490
|
keyNode = Array.prototype.slice.call(keyNode);
|
|
25292
25491
|
for (let index = 0, quantity = keyNode.length;index < quantity; index += 1) {
|
|
25293
|
-
if (Array.isArray(keyNode[index]))
|
|
25492
|
+
if (Array.isArray(keyNode[index])) {
|
|
25294
25493
|
throwError(state, "nested arrays are not supported inside keys");
|
|
25295
|
-
|
|
25494
|
+
}
|
|
25495
|
+
if (typeof keyNode === "object" && _class(keyNode[index]) === "[object Object]") {
|
|
25296
25496
|
keyNode[index] = "[object Object]";
|
|
25497
|
+
}
|
|
25297
25498
|
}
|
|
25298
25499
|
}
|
|
25299
|
-
if (typeof keyNode === "object" && _class(keyNode) === "[object Object]")
|
|
25500
|
+
if (typeof keyNode === "object" && _class(keyNode) === "[object Object]") {
|
|
25300
25501
|
keyNode = "[object Object]";
|
|
25502
|
+
}
|
|
25301
25503
|
keyNode = String(keyNode);
|
|
25302
|
-
if (_result === null)
|
|
25504
|
+
if (_result === null) {
|
|
25303
25505
|
_result = {};
|
|
25304
|
-
|
|
25506
|
+
}
|
|
25507
|
+
if (keyTag === "tag:yaml.org,2002:merge") {
|
|
25305
25508
|
if (Array.isArray(valueNode)) {
|
|
25306
|
-
if (valueNode.length > state.maxMergeSeqLength)
|
|
25307
|
-
throwError(state, "merge sequence length exceeded maxMergeSeqLength (" + state.maxMergeSeqLength + ")");
|
|
25308
|
-
const seen = /* @__PURE__ */ new Set;
|
|
25309
25509
|
for (let index = 0, quantity = valueNode.length;index < quantity; index += 1) {
|
|
25310
|
-
|
|
25311
|
-
if (seen.has(src2))
|
|
25312
|
-
continue;
|
|
25313
|
-
seen.add(src2);
|
|
25314
|
-
mergeMappings(state, _result, src2, overridableKeys);
|
|
25510
|
+
mergeMappings(state, _result, valueNode[index], overridableKeys);
|
|
25315
25511
|
}
|
|
25316
|
-
} else
|
|
25512
|
+
} else {
|
|
25317
25513
|
mergeMappings(state, _result, valueNode, overridableKeys);
|
|
25318
|
-
|
|
25514
|
+
}
|
|
25515
|
+
} else {
|
|
25319
25516
|
if (!state.json && !_hasOwnProperty.call(overridableKeys, keyNode) && _hasOwnProperty.call(_result, keyNode)) {
|
|
25320
25517
|
state.line = startLine || state.line;
|
|
25321
25518
|
state.lineStart = startLineStart || state.lineStart;
|
|
@@ -25329,14 +25526,16 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25329
25526
|
}
|
|
25330
25527
|
function readLineBreak(state) {
|
|
25331
25528
|
const ch = state.input.charCodeAt(state.position);
|
|
25332
|
-
if (ch === 10)
|
|
25529
|
+
if (ch === 10) {
|
|
25333
25530
|
state.position++;
|
|
25334
|
-
else if (ch === 13) {
|
|
25531
|
+
} else if (ch === 13) {
|
|
25335
25532
|
state.position++;
|
|
25336
|
-
if (state.input.charCodeAt(state.position) === 10)
|
|
25533
|
+
if (state.input.charCodeAt(state.position) === 10) {
|
|
25337
25534
|
state.position++;
|
|
25338
|
-
|
|
25535
|
+
}
|
|
25536
|
+
} else {
|
|
25339
25537
|
throwError(state, "a line break is expected");
|
|
25538
|
+
}
|
|
25340
25539
|
state.line += 1;
|
|
25341
25540
|
state.lineStart = state.position;
|
|
25342
25541
|
state.firstTabInLine = -1;
|
|
@@ -25346,14 +25545,16 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25346
25545
|
let ch = state.input.charCodeAt(state.position);
|
|
25347
25546
|
while (ch !== 0) {
|
|
25348
25547
|
while (isWhiteSpace(ch)) {
|
|
25349
|
-
if (ch === 9 && state.firstTabInLine === -1)
|
|
25548
|
+
if (ch === 9 && state.firstTabInLine === -1) {
|
|
25350
25549
|
state.firstTabInLine = state.position;
|
|
25550
|
+
}
|
|
25351
25551
|
ch = state.input.charCodeAt(++state.position);
|
|
25352
25552
|
}
|
|
25353
|
-
if (allowComments && ch === 35)
|
|
25354
|
-
do
|
|
25553
|
+
if (allowComments && ch === 35) {
|
|
25554
|
+
do {
|
|
25355
25555
|
ch = state.input.charCodeAt(++state.position);
|
|
25356
|
-
while (ch !== 10 && ch !== 13 && ch !== 0);
|
|
25556
|
+
} while (ch !== 10 && ch !== 13 && ch !== 0);
|
|
25557
|
+
}
|
|
25357
25558
|
if (isEol(ch)) {
|
|
25358
25559
|
readLineBreak(state);
|
|
25359
25560
|
ch = state.input.charCodeAt(state.position);
|
|
@@ -25363,11 +25564,13 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25363
25564
|
state.lineIndent++;
|
|
25364
25565
|
ch = state.input.charCodeAt(++state.position);
|
|
25365
25566
|
}
|
|
25366
|
-
} else
|
|
25567
|
+
} else {
|
|
25367
25568
|
break;
|
|
25569
|
+
}
|
|
25368
25570
|
}
|
|
25369
|
-
if (checkIndent !== -1 && lineBreaks !== 0 && state.lineIndent < checkIndent)
|
|
25571
|
+
if (checkIndent !== -1 && lineBreaks !== 0 && state.lineIndent < checkIndent) {
|
|
25370
25572
|
throwWarning(state, "deficient indentation");
|
|
25573
|
+
}
|
|
25371
25574
|
return lineBreaks;
|
|
25372
25575
|
}
|
|
25373
25576
|
function testDocumentSeparator(state) {
|
|
@@ -25376,17 +25579,19 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25376
25579
|
if ((ch === 45 || ch === 46) && ch === state.input.charCodeAt(_position + 1) && ch === state.input.charCodeAt(_position + 2)) {
|
|
25377
25580
|
_position += 3;
|
|
25378
25581
|
ch = state.input.charCodeAt(_position);
|
|
25379
|
-
if (ch === 0 || isWsOrEol(ch))
|
|
25582
|
+
if (ch === 0 || isWsOrEol(ch)) {
|
|
25380
25583
|
return true;
|
|
25584
|
+
}
|
|
25381
25585
|
}
|
|
25382
25586
|
return false;
|
|
25383
25587
|
}
|
|
25384
25588
|
function writeFoldedLines(state, count) {
|
|
25385
|
-
if (count === 1)
|
|
25589
|
+
if (count === 1) {
|
|
25386
25590
|
state.result += " ";
|
|
25387
|
-
else if (count > 1)
|
|
25388
|
-
state.result +=
|
|
25591
|
+
} else if (count > 1) {
|
|
25592
|
+
state.result += common2.repeat(`
|
|
25389
25593
|
`, count - 1);
|
|
25594
|
+
}
|
|
25390
25595
|
}
|
|
25391
25596
|
function readPlainScalar(state, nodeIndent, withinFlowCollection) {
|
|
25392
25597
|
let captureStart;
|
|
@@ -25398,12 +25603,14 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25398
25603
|
const _kind = state.kind;
|
|
25399
25604
|
const _result = state.result;
|
|
25400
25605
|
let ch = state.input.charCodeAt(state.position);
|
|
25401
|
-
if (isWsOrEol(ch) || isFlowIndicator(ch) || ch === 35 || ch === 38 || ch === 42 || ch === 33 || ch === 124 || ch === 62 || ch === 39 || ch === 34 || ch === 37 || ch === 64 || ch === 96)
|
|
25606
|
+
if (isWsOrEol(ch) || isFlowIndicator(ch) || ch === 35 || ch === 38 || ch === 42 || ch === 33 || ch === 124 || ch === 62 || ch === 39 || ch === 34 || ch === 37 || ch === 64 || ch === 96) {
|
|
25402
25607
|
return false;
|
|
25608
|
+
}
|
|
25403
25609
|
if (ch === 63 || ch === 45) {
|
|
25404
25610
|
const following = state.input.charCodeAt(state.position + 1);
|
|
25405
|
-
if (isWsOrEol(following) || withinFlowCollection && isFlowIndicator(following))
|
|
25611
|
+
if (isWsOrEol(following) || withinFlowCollection && isFlowIndicator(following)) {
|
|
25406
25612
|
return false;
|
|
25613
|
+
}
|
|
25407
25614
|
}
|
|
25408
25615
|
state.kind = "scalar";
|
|
25409
25616
|
state.result = "";
|
|
@@ -25412,14 +25619,17 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25412
25619
|
while (ch !== 0) {
|
|
25413
25620
|
if (ch === 58) {
|
|
25414
25621
|
const following = state.input.charCodeAt(state.position + 1);
|
|
25415
|
-
if (isWsOrEol(following) || withinFlowCollection && isFlowIndicator(following))
|
|
25622
|
+
if (isWsOrEol(following) || withinFlowCollection && isFlowIndicator(following)) {
|
|
25416
25623
|
break;
|
|
25624
|
+
}
|
|
25417
25625
|
} else if (ch === 35) {
|
|
25418
|
-
|
|
25626
|
+
const preceding = state.input.charCodeAt(state.position - 1);
|
|
25627
|
+
if (isWsOrEol(preceding)) {
|
|
25419
25628
|
break;
|
|
25420
|
-
|
|
25629
|
+
}
|
|
25630
|
+
} else if (state.position === state.lineStart && testDocumentSeparator(state) || withinFlowCollection && isFlowIndicator(ch)) {
|
|
25421
25631
|
break;
|
|
25422
|
-
else if (isEol(ch)) {
|
|
25632
|
+
} else if (isEol(ch)) {
|
|
25423
25633
|
_line = state.line;
|
|
25424
25634
|
_lineStart = state.lineStart;
|
|
25425
25635
|
_lineIndent = state.lineIndent;
|
|
@@ -25442,13 +25652,15 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25442
25652
|
captureStart = captureEnd = state.position;
|
|
25443
25653
|
hasPendingContent = false;
|
|
25444
25654
|
}
|
|
25445
|
-
if (!isWhiteSpace(ch))
|
|
25655
|
+
if (!isWhiteSpace(ch)) {
|
|
25446
25656
|
captureEnd = state.position + 1;
|
|
25657
|
+
}
|
|
25447
25658
|
ch = state.input.charCodeAt(++state.position);
|
|
25448
25659
|
}
|
|
25449
25660
|
captureSegment(state, captureStart, captureEnd, false);
|
|
25450
|
-
if (state.result)
|
|
25661
|
+
if (state.result) {
|
|
25451
25662
|
return true;
|
|
25663
|
+
}
|
|
25452
25664
|
state.kind = _kind;
|
|
25453
25665
|
state.result = _result;
|
|
25454
25666
|
return false;
|
|
@@ -25457,13 +25669,14 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25457
25669
|
let captureStart;
|
|
25458
25670
|
let captureEnd;
|
|
25459
25671
|
let ch = state.input.charCodeAt(state.position);
|
|
25460
|
-
if (ch !== 39)
|
|
25672
|
+
if (ch !== 39) {
|
|
25461
25673
|
return false;
|
|
25674
|
+
}
|
|
25462
25675
|
state.kind = "scalar";
|
|
25463
25676
|
state.result = "";
|
|
25464
25677
|
state.position++;
|
|
25465
25678
|
captureStart = captureEnd = state.position;
|
|
25466
|
-
while ((ch = state.input.charCodeAt(state.position)) !== 0)
|
|
25679
|
+
while ((ch = state.input.charCodeAt(state.position)) !== 0) {
|
|
25467
25680
|
if (ch === 39) {
|
|
25468
25681
|
captureSegment(state, captureStart, state.position, true);
|
|
25469
25682
|
ch = state.input.charCodeAt(++state.position);
|
|
@@ -25471,19 +25684,22 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25471
25684
|
captureStart = state.position;
|
|
25472
25685
|
state.position++;
|
|
25473
25686
|
captureEnd = state.position;
|
|
25474
|
-
} else
|
|
25687
|
+
} else {
|
|
25475
25688
|
return true;
|
|
25689
|
+
}
|
|
25476
25690
|
} else if (isEol(ch)) {
|
|
25477
25691
|
captureSegment(state, captureStart, captureEnd, true);
|
|
25478
25692
|
writeFoldedLines(state, skipSeparationSpace(state, false, nodeIndent));
|
|
25479
25693
|
captureStart = captureEnd = state.position;
|
|
25480
|
-
} else if (state.position === state.lineStart && testDocumentSeparator(state))
|
|
25694
|
+
} else if (state.position === state.lineStart && testDocumentSeparator(state)) {
|
|
25481
25695
|
throwError(state, "unexpected end of the document within a single quoted scalar");
|
|
25482
|
-
else {
|
|
25696
|
+
} else {
|
|
25483
25697
|
state.position++;
|
|
25484
|
-
if (!isWhiteSpace(ch))
|
|
25698
|
+
if (!isWhiteSpace(ch)) {
|
|
25485
25699
|
captureEnd = state.position;
|
|
25700
|
+
}
|
|
25486
25701
|
}
|
|
25702
|
+
}
|
|
25487
25703
|
throwError(state, "unexpected end of the stream within a single quoted scalar");
|
|
25488
25704
|
}
|
|
25489
25705
|
function readDoubleQuotedScalar(state, nodeIndent) {
|
|
@@ -25491,13 +25707,14 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25491
25707
|
let captureEnd;
|
|
25492
25708
|
let tmp;
|
|
25493
25709
|
let ch = state.input.charCodeAt(state.position);
|
|
25494
|
-
if (ch !== 34)
|
|
25710
|
+
if (ch !== 34) {
|
|
25495
25711
|
return false;
|
|
25712
|
+
}
|
|
25496
25713
|
state.kind = "scalar";
|
|
25497
25714
|
state.result = "";
|
|
25498
25715
|
state.position++;
|
|
25499
25716
|
captureStart = captureEnd = state.position;
|
|
25500
|
-
while ((ch = state.input.charCodeAt(state.position)) !== 0)
|
|
25717
|
+
while ((ch = state.input.charCodeAt(state.position)) !== 0) {
|
|
25501
25718
|
if (ch === 34) {
|
|
25502
25719
|
captureSegment(state, captureStart, state.position, true);
|
|
25503
25720
|
state.position++;
|
|
@@ -25505,9 +25722,9 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25505
25722
|
} else if (ch === 92) {
|
|
25506
25723
|
captureSegment(state, captureStart, state.position, true);
|
|
25507
25724
|
ch = state.input.charCodeAt(++state.position);
|
|
25508
|
-
if (isEol(ch))
|
|
25725
|
+
if (isEol(ch)) {
|
|
25509
25726
|
skipSeparationSpace(state, false, nodeIndent);
|
|
25510
|
-
else if (ch < 256 && simpleEscapeCheck[ch]) {
|
|
25727
|
+
} else if (ch < 256 && simpleEscapeCheck[ch]) {
|
|
25511
25728
|
state.result += simpleEscapeMap[ch];
|
|
25512
25729
|
state.position++;
|
|
25513
25730
|
} else if ((tmp = escapedHexLen(ch)) > 0) {
|
|
@@ -25515,27 +25732,31 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25515
25732
|
let hexResult = 0;
|
|
25516
25733
|
for (;hexLength > 0; hexLength--) {
|
|
25517
25734
|
ch = state.input.charCodeAt(++state.position);
|
|
25518
|
-
if ((tmp = fromHexCode(ch)) >= 0)
|
|
25735
|
+
if ((tmp = fromHexCode(ch)) >= 0) {
|
|
25519
25736
|
hexResult = (hexResult << 4) + tmp;
|
|
25520
|
-
else
|
|
25737
|
+
} else {
|
|
25521
25738
|
throwError(state, "expected hexadecimal character");
|
|
25739
|
+
}
|
|
25522
25740
|
}
|
|
25523
25741
|
state.result += charFromCodepoint(hexResult);
|
|
25524
25742
|
state.position++;
|
|
25525
|
-
} else
|
|
25743
|
+
} else {
|
|
25526
25744
|
throwError(state, "unknown escape sequence");
|
|
25745
|
+
}
|
|
25527
25746
|
captureStart = captureEnd = state.position;
|
|
25528
25747
|
} else if (isEol(ch)) {
|
|
25529
25748
|
captureSegment(state, captureStart, captureEnd, true);
|
|
25530
25749
|
writeFoldedLines(state, skipSeparationSpace(state, false, nodeIndent));
|
|
25531
25750
|
captureStart = captureEnd = state.position;
|
|
25532
|
-
} else if (state.position === state.lineStart && testDocumentSeparator(state))
|
|
25751
|
+
} else if (state.position === state.lineStart && testDocumentSeparator(state)) {
|
|
25533
25752
|
throwError(state, "unexpected end of the document within a double quoted scalar");
|
|
25534
|
-
else {
|
|
25753
|
+
} else {
|
|
25535
25754
|
state.position++;
|
|
25536
|
-
if (!isWhiteSpace(ch))
|
|
25755
|
+
if (!isWhiteSpace(ch)) {
|
|
25537
25756
|
captureEnd = state.position;
|
|
25757
|
+
}
|
|
25538
25758
|
}
|
|
25759
|
+
}
|
|
25539
25760
|
throwError(state, "unexpected end of the stream within a double quoted scalar");
|
|
25540
25761
|
}
|
|
25541
25762
|
function readFlowCollection(state, nodeIndent) {
|
|
@@ -25550,7 +25771,7 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25550
25771
|
let isPair;
|
|
25551
25772
|
let isExplicitPair;
|
|
25552
25773
|
let isMapping;
|
|
25553
|
-
const overridableKeys = Object.create(null);
|
|
25774
|
+
const overridableKeys = /* @__PURE__ */ Object.create(null);
|
|
25554
25775
|
let keyNode;
|
|
25555
25776
|
let keyTag;
|
|
25556
25777
|
let valueNode;
|
|
@@ -25563,10 +25784,12 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25563
25784
|
terminator = 125;
|
|
25564
25785
|
isMapping = true;
|
|
25565
25786
|
_result = {};
|
|
25566
|
-
} else
|
|
25787
|
+
} else {
|
|
25567
25788
|
return false;
|
|
25568
|
-
|
|
25789
|
+
}
|
|
25790
|
+
if (state.anchor !== null) {
|
|
25569
25791
|
storeAnchor(state, state.anchor, _result);
|
|
25792
|
+
}
|
|
25570
25793
|
ch = state.input.charCodeAt(++state.position);
|
|
25571
25794
|
while (ch !== 0) {
|
|
25572
25795
|
skipSeparationSpace(state, true, nodeIndent);
|
|
@@ -25578,14 +25801,16 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25578
25801
|
state.kind = isMapping ? "mapping" : "sequence";
|
|
25579
25802
|
state.result = _result;
|
|
25580
25803
|
return true;
|
|
25581
|
-
} else if (!readNext)
|
|
25804
|
+
} else if (!readNext) {
|
|
25582
25805
|
throwError(state, "missed comma between flow collection entries");
|
|
25583
|
-
else if (ch === 44)
|
|
25806
|
+
} else if (ch === 44) {
|
|
25584
25807
|
throwError(state, "expected the node content, but found ','");
|
|
25808
|
+
}
|
|
25585
25809
|
keyTag = keyNode = valueNode = null;
|
|
25586
25810
|
isPair = isExplicitPair = false;
|
|
25587
25811
|
if (ch === 63) {
|
|
25588
|
-
|
|
25812
|
+
const following = state.input.charCodeAt(state.position + 1);
|
|
25813
|
+
if (isWsOrEol(following)) {
|
|
25589
25814
|
isPair = isExplicitPair = true;
|
|
25590
25815
|
state.position++;
|
|
25591
25816
|
skipSeparationSpace(state, true, nodeIndent);
|
|
@@ -25606,19 +25831,21 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25606
25831
|
composeNode(state, nodeIndent, CONTEXT_FLOW_IN, false, true);
|
|
25607
25832
|
valueNode = state.result;
|
|
25608
25833
|
}
|
|
25609
|
-
if (isMapping)
|
|
25834
|
+
if (isMapping) {
|
|
25610
25835
|
storeMappingPair(state, _result, overridableKeys, keyTag, keyNode, valueNode, _line, _lineStart, _pos);
|
|
25611
|
-
else if (isPair)
|
|
25836
|
+
} else if (isPair) {
|
|
25612
25837
|
_result.push(storeMappingPair(state, null, overridableKeys, keyTag, keyNode, valueNode, _line, _lineStart, _pos));
|
|
25613
|
-
else
|
|
25838
|
+
} else {
|
|
25614
25839
|
_result.push(keyNode);
|
|
25840
|
+
}
|
|
25615
25841
|
skipSeparationSpace(state, true, nodeIndent);
|
|
25616
25842
|
ch = state.input.charCodeAt(state.position);
|
|
25617
25843
|
if (ch === 44) {
|
|
25618
25844
|
readNext = true;
|
|
25619
25845
|
ch = state.input.charCodeAt(++state.position);
|
|
25620
|
-
} else
|
|
25846
|
+
} else {
|
|
25621
25847
|
readNext = false;
|
|
25848
|
+
}
|
|
25622
25849
|
}
|
|
25623
25850
|
throwError(state, "unexpected end of the stream within a flow collection");
|
|
25624
25851
|
}
|
|
@@ -25632,40 +25859,45 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25632
25859
|
let atMoreIndented = false;
|
|
25633
25860
|
let tmp;
|
|
25634
25861
|
let ch = state.input.charCodeAt(state.position);
|
|
25635
|
-
if (ch === 124)
|
|
25862
|
+
if (ch === 124) {
|
|
25636
25863
|
folding = false;
|
|
25637
|
-
else if (ch === 62)
|
|
25864
|
+
} else if (ch === 62) {
|
|
25638
25865
|
folding = true;
|
|
25639
|
-
else
|
|
25866
|
+
} else {
|
|
25640
25867
|
return false;
|
|
25868
|
+
}
|
|
25641
25869
|
state.kind = "scalar";
|
|
25642
25870
|
state.result = "";
|
|
25643
25871
|
while (ch !== 0) {
|
|
25644
25872
|
ch = state.input.charCodeAt(++state.position);
|
|
25645
|
-
if (ch === 43 || ch === 45)
|
|
25646
|
-
if (CHOMPING_CLIP === chomping)
|
|
25873
|
+
if (ch === 43 || ch === 45) {
|
|
25874
|
+
if (CHOMPING_CLIP === chomping) {
|
|
25647
25875
|
chomping = ch === 43 ? CHOMPING_KEEP : CHOMPING_STRIP;
|
|
25648
|
-
else
|
|
25876
|
+
} else {
|
|
25649
25877
|
throwError(state, "repeat of a chomping mode identifier");
|
|
25650
|
-
|
|
25651
|
-
|
|
25878
|
+
}
|
|
25879
|
+
} else if ((tmp = fromDecimalCode(ch)) >= 0) {
|
|
25880
|
+
if (tmp === 0) {
|
|
25652
25881
|
throwError(state, "bad explicit indentation width of a block scalar; it cannot be less than one");
|
|
25653
|
-
else if (!detectedIndent) {
|
|
25882
|
+
} else if (!detectedIndent) {
|
|
25654
25883
|
textIndent = nodeIndent + tmp - 1;
|
|
25655
25884
|
detectedIndent = true;
|
|
25656
|
-
} else
|
|
25885
|
+
} else {
|
|
25657
25886
|
throwError(state, "repeat of an indentation width identifier");
|
|
25658
|
-
|
|
25887
|
+
}
|
|
25888
|
+
} else {
|
|
25659
25889
|
break;
|
|
25890
|
+
}
|
|
25660
25891
|
}
|
|
25661
25892
|
if (isWhiteSpace(ch)) {
|
|
25662
|
-
do
|
|
25893
|
+
do {
|
|
25663
25894
|
ch = state.input.charCodeAt(++state.position);
|
|
25664
|
-
while (isWhiteSpace(ch));
|
|
25665
|
-
if (ch === 35)
|
|
25666
|
-
do
|
|
25895
|
+
} while (isWhiteSpace(ch));
|
|
25896
|
+
if (ch === 35) {
|
|
25897
|
+
do {
|
|
25667
25898
|
ch = state.input.charCodeAt(++state.position);
|
|
25668
|
-
while (!isEol(ch) && ch !== 0);
|
|
25899
|
+
} while (!isEol(ch) && ch !== 0);
|
|
25900
|
+
}
|
|
25669
25901
|
}
|
|
25670
25902
|
while (ch !== 0) {
|
|
25671
25903
|
readLineBreak(state);
|
|
@@ -25675,49 +25907,56 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25675
25907
|
state.lineIndent++;
|
|
25676
25908
|
ch = state.input.charCodeAt(++state.position);
|
|
25677
25909
|
}
|
|
25678
|
-
if (!detectedIndent && state.lineIndent > textIndent)
|
|
25910
|
+
if (!detectedIndent && state.lineIndent > textIndent) {
|
|
25679
25911
|
textIndent = state.lineIndent;
|
|
25912
|
+
}
|
|
25680
25913
|
if (isEol(ch)) {
|
|
25681
25914
|
emptyLines++;
|
|
25682
25915
|
continue;
|
|
25683
25916
|
}
|
|
25684
|
-
if (!detectedIndent && textIndent === 0)
|
|
25917
|
+
if (!detectedIndent && textIndent === 0) {
|
|
25685
25918
|
throwError(state, "missing indentation for block scalar");
|
|
25919
|
+
}
|
|
25686
25920
|
if (state.lineIndent < textIndent) {
|
|
25687
|
-
if (chomping === CHOMPING_KEEP)
|
|
25688
|
-
state.result +=
|
|
25921
|
+
if (chomping === CHOMPING_KEEP) {
|
|
25922
|
+
state.result += common2.repeat(`
|
|
25689
25923
|
`, didReadContent ? 1 + emptyLines : emptyLines);
|
|
25690
|
-
else if (chomping === CHOMPING_CLIP) {
|
|
25691
|
-
if (didReadContent)
|
|
25924
|
+
} else if (chomping === CHOMPING_CLIP) {
|
|
25925
|
+
if (didReadContent) {
|
|
25692
25926
|
state.result += `
|
|
25693
25927
|
`;
|
|
25928
|
+
}
|
|
25694
25929
|
}
|
|
25695
25930
|
break;
|
|
25696
25931
|
}
|
|
25697
|
-
if (folding)
|
|
25932
|
+
if (folding) {
|
|
25698
25933
|
if (isWhiteSpace(ch)) {
|
|
25699
25934
|
atMoreIndented = true;
|
|
25700
|
-
state.result +=
|
|
25935
|
+
state.result += common2.repeat(`
|
|
25701
25936
|
`, didReadContent ? 1 + emptyLines : emptyLines);
|
|
25702
25937
|
} else if (atMoreIndented) {
|
|
25703
25938
|
atMoreIndented = false;
|
|
25704
|
-
state.result +=
|
|
25939
|
+
state.result += common2.repeat(`
|
|
25705
25940
|
`, emptyLines + 1);
|
|
25706
25941
|
} else if (emptyLines === 0) {
|
|
25707
|
-
if (didReadContent)
|
|
25942
|
+
if (didReadContent) {
|
|
25708
25943
|
state.result += " ";
|
|
25709
|
-
|
|
25710
|
-
|
|
25944
|
+
}
|
|
25945
|
+
} else {
|
|
25946
|
+
state.result += common2.repeat(`
|
|
25711
25947
|
`, emptyLines);
|
|
25712
|
-
|
|
25713
|
-
|
|
25948
|
+
}
|
|
25949
|
+
} else {
|
|
25950
|
+
state.result += common2.repeat(`
|
|
25714
25951
|
`, didReadContent ? 1 + emptyLines : emptyLines);
|
|
25952
|
+
}
|
|
25715
25953
|
didReadContent = true;
|
|
25716
25954
|
detectedIndent = true;
|
|
25717
25955
|
emptyLines = 0;
|
|
25718
25956
|
const captureStart = state.position;
|
|
25719
|
-
while (!isEol(ch) && ch !== 0)
|
|
25957
|
+
while (!isEol(ch) && ch !== 0) {
|
|
25720
25958
|
ch = state.input.charCodeAt(++state.position);
|
|
25959
|
+
}
|
|
25721
25960
|
captureSegment(state, captureStart, state.position, false);
|
|
25722
25961
|
}
|
|
25723
25962
|
return true;
|
|
@@ -25729,18 +25968,22 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25729
25968
|
let detected = false;
|
|
25730
25969
|
if (state.firstTabInLine !== -1)
|
|
25731
25970
|
return false;
|
|
25732
|
-
if (state.anchor !== null)
|
|
25971
|
+
if (state.anchor !== null) {
|
|
25733
25972
|
storeAnchor(state, state.anchor, _result);
|
|
25973
|
+
}
|
|
25734
25974
|
let ch = state.input.charCodeAt(state.position);
|
|
25735
25975
|
while (ch !== 0) {
|
|
25736
25976
|
if (state.firstTabInLine !== -1) {
|
|
25737
25977
|
state.position = state.firstTabInLine;
|
|
25738
25978
|
throwError(state, "tab characters must not be used in indentation");
|
|
25739
25979
|
}
|
|
25740
|
-
if (ch !== 45)
|
|
25980
|
+
if (ch !== 45) {
|
|
25741
25981
|
break;
|
|
25742
|
-
|
|
25982
|
+
}
|
|
25983
|
+
const following = state.input.charCodeAt(state.position + 1);
|
|
25984
|
+
if (!isWsOrEol(following)) {
|
|
25743
25985
|
break;
|
|
25986
|
+
}
|
|
25744
25987
|
detected = true;
|
|
25745
25988
|
state.position++;
|
|
25746
25989
|
if (skipSeparationSpace(state, true, -1)) {
|
|
@@ -25755,10 +25998,11 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25755
25998
|
_result.push(state.result);
|
|
25756
25999
|
skipSeparationSpace(state, true, -1);
|
|
25757
26000
|
ch = state.input.charCodeAt(state.position);
|
|
25758
|
-
if ((state.line === _line || state.lineIndent > nodeIndent) && ch !== 0)
|
|
26001
|
+
if ((state.line === _line || state.lineIndent > nodeIndent) && ch !== 0) {
|
|
25759
26002
|
throwError(state, "bad indentation of a sequence entry");
|
|
25760
|
-
else if (state.lineIndent < nodeIndent)
|
|
26003
|
+
} else if (state.lineIndent < nodeIndent) {
|
|
25761
26004
|
break;
|
|
26005
|
+
}
|
|
25762
26006
|
}
|
|
25763
26007
|
if (detected) {
|
|
25764
26008
|
state.tag = _tag;
|
|
@@ -25777,7 +26021,7 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25777
26021
|
const _tag = state.tag;
|
|
25778
26022
|
const _anchor = state.anchor;
|
|
25779
26023
|
const _result = {};
|
|
25780
|
-
const overridableKeys = Object.create(null);
|
|
26024
|
+
const overridableKeys = /* @__PURE__ */ Object.create(null);
|
|
25781
26025
|
let keyTag = null;
|
|
25782
26026
|
let keyNode = null;
|
|
25783
26027
|
let valueNode = null;
|
|
@@ -25785,8 +26029,9 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25785
26029
|
let detected = false;
|
|
25786
26030
|
if (state.firstTabInLine !== -1)
|
|
25787
26031
|
return false;
|
|
25788
|
-
if (state.anchor !== null)
|
|
26032
|
+
if (state.anchor !== null) {
|
|
25789
26033
|
storeAnchor(state, state.anchor, _result);
|
|
26034
|
+
}
|
|
25790
26035
|
let ch = state.input.charCodeAt(state.position);
|
|
25791
26036
|
while (ch !== 0) {
|
|
25792
26037
|
if (!atExplicitKey && state.firstTabInLine !== -1) {
|
|
@@ -25807,24 +26052,28 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25807
26052
|
} else if (atExplicitKey) {
|
|
25808
26053
|
atExplicitKey = false;
|
|
25809
26054
|
allowCompact = true;
|
|
25810
|
-
} else
|
|
26055
|
+
} else {
|
|
25811
26056
|
throwError(state, "incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line");
|
|
26057
|
+
}
|
|
25812
26058
|
state.position += 1;
|
|
25813
26059
|
ch = following;
|
|
25814
26060
|
} else {
|
|
25815
26061
|
_keyLine = state.line;
|
|
25816
26062
|
_keyLineStart = state.lineStart;
|
|
25817
26063
|
_keyPos = state.position;
|
|
25818
|
-
if (!composeNode(state, flowIndent, CONTEXT_FLOW_OUT, false, true))
|
|
26064
|
+
if (!composeNode(state, flowIndent, CONTEXT_FLOW_OUT, false, true)) {
|
|
25819
26065
|
break;
|
|
26066
|
+
}
|
|
25820
26067
|
if (state.line === _line) {
|
|
25821
26068
|
ch = state.input.charCodeAt(state.position);
|
|
25822
|
-
while (isWhiteSpace(ch))
|
|
26069
|
+
while (isWhiteSpace(ch)) {
|
|
25823
26070
|
ch = state.input.charCodeAt(++state.position);
|
|
26071
|
+
}
|
|
25824
26072
|
if (ch === 58) {
|
|
25825
26073
|
ch = state.input.charCodeAt(++state.position);
|
|
25826
|
-
if (!isWsOrEol(ch))
|
|
26074
|
+
if (!isWsOrEol(ch)) {
|
|
25827
26075
|
throwError(state, "a whitespace character is expected after the key-value separator within a block mapping");
|
|
26076
|
+
}
|
|
25828
26077
|
if (atExplicitKey) {
|
|
25829
26078
|
storeMappingPair(state, _result, overridableKeys, keyTag, keyNode, null, _keyLine, _keyLineStart, _keyPos);
|
|
25830
26079
|
keyTag = keyNode = valueNode = null;
|
|
@@ -25834,16 +26083,16 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25834
26083
|
allowCompact = false;
|
|
25835
26084
|
keyTag = state.tag;
|
|
25836
26085
|
keyNode = state.result;
|
|
25837
|
-
} else if (detected)
|
|
26086
|
+
} else if (detected) {
|
|
25838
26087
|
throwError(state, "can not read an implicit mapping pair; a colon is missed");
|
|
25839
|
-
else {
|
|
26088
|
+
} else {
|
|
25840
26089
|
state.tag = _tag;
|
|
25841
26090
|
state.anchor = _anchor;
|
|
25842
26091
|
return true;
|
|
25843
26092
|
}
|
|
25844
|
-
} else if (detected)
|
|
26093
|
+
} else if (detected) {
|
|
25845
26094
|
throwError(state, "can not read a block mapping entry; a multiline key may not be an implicit key");
|
|
25846
|
-
else {
|
|
26095
|
+
} else {
|
|
25847
26096
|
state.tag = _tag;
|
|
25848
26097
|
state.anchor = _anchor;
|
|
25849
26098
|
return true;
|
|
@@ -25855,11 +26104,13 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25855
26104
|
_keyLineStart = state.lineStart;
|
|
25856
26105
|
_keyPos = state.position;
|
|
25857
26106
|
}
|
|
25858
|
-
if (composeNode(state, nodeIndent, CONTEXT_BLOCK_OUT, true, allowCompact))
|
|
25859
|
-
if (atExplicitKey)
|
|
26107
|
+
if (composeNode(state, nodeIndent, CONTEXT_BLOCK_OUT, true, allowCompact)) {
|
|
26108
|
+
if (atExplicitKey) {
|
|
25860
26109
|
keyNode = state.result;
|
|
25861
|
-
else
|
|
26110
|
+
} else {
|
|
25862
26111
|
valueNode = state.result;
|
|
26112
|
+
}
|
|
26113
|
+
}
|
|
25863
26114
|
if (!atExplicitKey) {
|
|
25864
26115
|
storeMappingPair(state, _result, overridableKeys, keyTag, keyNode, valueNode, _keyLine, _keyLineStart, _keyPos);
|
|
25865
26116
|
keyTag = keyNode = valueNode = null;
|
|
@@ -25867,13 +26118,15 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25867
26118
|
skipSeparationSpace(state, true, -1);
|
|
25868
26119
|
ch = state.input.charCodeAt(state.position);
|
|
25869
26120
|
}
|
|
25870
|
-
if ((state.line === _line || state.lineIndent > nodeIndent) && ch !== 0)
|
|
26121
|
+
if ((state.line === _line || state.lineIndent > nodeIndent) && ch !== 0) {
|
|
25871
26122
|
throwError(state, "bad indentation of a mapping entry");
|
|
25872
|
-
else if (state.lineIndent < nodeIndent)
|
|
26123
|
+
} else if (state.lineIndent < nodeIndent) {
|
|
25873
26124
|
break;
|
|
26125
|
+
}
|
|
25874
26126
|
}
|
|
25875
|
-
if (atExplicitKey)
|
|
26127
|
+
if (atExplicitKey) {
|
|
25876
26128
|
storeMappingPair(state, _result, overridableKeys, keyTag, keyNode, null, _keyLine, _keyLineStart, _keyPos);
|
|
26129
|
+
}
|
|
25877
26130
|
if (detected) {
|
|
25878
26131
|
state.tag = _tag;
|
|
25879
26132
|
state.anchor = _anchor;
|
|
@@ -25890,8 +26143,9 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25890
26143
|
let ch = state.input.charCodeAt(state.position);
|
|
25891
26144
|
if (ch !== 33)
|
|
25892
26145
|
return false;
|
|
25893
|
-
if (state.tag !== null)
|
|
26146
|
+
if (state.tag !== null) {
|
|
25894
26147
|
throwError(state, "duplication of a tag property");
|
|
26148
|
+
}
|
|
25895
26149
|
ch = state.input.charCodeAt(++state.position);
|
|
25896
26150
|
if (ch === 60) {
|
|
25897
26151
|
isVerbatim = true;
|
|
@@ -25900,66 +26154,77 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25900
26154
|
isNamed = true;
|
|
25901
26155
|
tagHandle = "!!";
|
|
25902
26156
|
ch = state.input.charCodeAt(++state.position);
|
|
25903
|
-
} else
|
|
26157
|
+
} else {
|
|
25904
26158
|
tagHandle = "!";
|
|
26159
|
+
}
|
|
25905
26160
|
let _position = state.position;
|
|
25906
26161
|
if (isVerbatim) {
|
|
25907
|
-
do
|
|
26162
|
+
do {
|
|
25908
26163
|
ch = state.input.charCodeAt(++state.position);
|
|
25909
|
-
while (ch !== 0 && ch !== 62);
|
|
26164
|
+
} while (ch !== 0 && ch !== 62);
|
|
25910
26165
|
if (state.position < state.length) {
|
|
25911
26166
|
tagName = state.input.slice(_position, state.position);
|
|
25912
26167
|
ch = state.input.charCodeAt(++state.position);
|
|
25913
|
-
} else
|
|
26168
|
+
} else {
|
|
25914
26169
|
throwError(state, "unexpected end of the stream within a verbatim tag");
|
|
26170
|
+
}
|
|
25915
26171
|
} else {
|
|
25916
26172
|
while (ch !== 0 && !isWsOrEol(ch)) {
|
|
25917
|
-
if (ch === 33)
|
|
26173
|
+
if (ch === 33) {
|
|
25918
26174
|
if (!isNamed) {
|
|
25919
26175
|
tagHandle = state.input.slice(_position - 1, state.position + 1);
|
|
25920
|
-
if (!PATTERN_TAG_HANDLE.test(tagHandle))
|
|
26176
|
+
if (!PATTERN_TAG_HANDLE.test(tagHandle)) {
|
|
25921
26177
|
throwError(state, "named tag handle cannot contain such characters");
|
|
26178
|
+
}
|
|
25922
26179
|
isNamed = true;
|
|
25923
26180
|
_position = state.position + 1;
|
|
25924
|
-
} else
|
|
26181
|
+
} else {
|
|
25925
26182
|
throwError(state, "tag suffix cannot contain exclamation marks");
|
|
26183
|
+
}
|
|
26184
|
+
}
|
|
25926
26185
|
ch = state.input.charCodeAt(++state.position);
|
|
25927
26186
|
}
|
|
25928
26187
|
tagName = state.input.slice(_position, state.position);
|
|
25929
|
-
if (PATTERN_FLOW_INDICATORS.test(tagName))
|
|
26188
|
+
if (PATTERN_FLOW_INDICATORS.test(tagName)) {
|
|
25930
26189
|
throwError(state, "tag suffix cannot contain flow indicator characters");
|
|
26190
|
+
}
|
|
25931
26191
|
}
|
|
25932
|
-
if (tagName && !PATTERN_TAG_URI.test(tagName))
|
|
26192
|
+
if (tagName && !PATTERN_TAG_URI.test(tagName)) {
|
|
25933
26193
|
throwError(state, "tag name cannot contain such characters: " + tagName);
|
|
26194
|
+
}
|
|
25934
26195
|
try {
|
|
25935
26196
|
tagName = decodeURIComponent(tagName);
|
|
25936
26197
|
} catch (err) {
|
|
25937
26198
|
throwError(state, "tag name is malformed: " + tagName);
|
|
25938
26199
|
}
|
|
25939
|
-
if (isVerbatim)
|
|
26200
|
+
if (isVerbatim) {
|
|
25940
26201
|
state.tag = tagName;
|
|
25941
|
-
else if (_hasOwnProperty.call(state.tagMap, tagHandle))
|
|
26202
|
+
} else if (_hasOwnProperty.call(state.tagMap, tagHandle)) {
|
|
25942
26203
|
state.tag = state.tagMap[tagHandle] + tagName;
|
|
25943
|
-
else if (tagHandle === "!")
|
|
26204
|
+
} else if (tagHandle === "!") {
|
|
25944
26205
|
state.tag = "!" + tagName;
|
|
25945
|
-
else if (tagHandle === "!!")
|
|
26206
|
+
} else if (tagHandle === "!!") {
|
|
25946
26207
|
state.tag = "tag:yaml.org,2002:" + tagName;
|
|
25947
|
-
else
|
|
26208
|
+
} else {
|
|
25948
26209
|
throwError(state, 'undeclared tag handle "' + tagHandle + '"');
|
|
26210
|
+
}
|
|
25949
26211
|
return true;
|
|
25950
26212
|
}
|
|
25951
26213
|
function readAnchorProperty(state) {
|
|
25952
26214
|
let ch = state.input.charCodeAt(state.position);
|
|
25953
26215
|
if (ch !== 38)
|
|
25954
26216
|
return false;
|
|
25955
|
-
if (state.anchor !== null)
|
|
26217
|
+
if (state.anchor !== null) {
|
|
25956
26218
|
throwError(state, "duplication of an anchor property");
|
|
26219
|
+
}
|
|
25957
26220
|
ch = state.input.charCodeAt(++state.position);
|
|
25958
26221
|
const _position = state.position;
|
|
25959
|
-
while (ch !== 0 && !isWsOrEol(ch) && !isFlowIndicator(ch))
|
|
26222
|
+
while (ch !== 0 && !isWsOrEol(ch) && !isFlowIndicator(ch)) {
|
|
25960
26223
|
ch = state.input.charCodeAt(++state.position);
|
|
25961
|
-
|
|
26224
|
+
}
|
|
26225
|
+
if (state.position === _position) {
|
|
25962
26226
|
throwError(state, "name of an anchor node must contain at least one character");
|
|
26227
|
+
}
|
|
25963
26228
|
state.anchor = state.input.slice(_position, state.position);
|
|
25964
26229
|
return true;
|
|
25965
26230
|
}
|
|
@@ -25969,13 +26234,16 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
25969
26234
|
return false;
|
|
25970
26235
|
ch = state.input.charCodeAt(++state.position);
|
|
25971
26236
|
const _position = state.position;
|
|
25972
|
-
while (ch !== 0 && !isWsOrEol(ch) && !isFlowIndicator(ch))
|
|
26237
|
+
while (ch !== 0 && !isWsOrEol(ch) && !isFlowIndicator(ch)) {
|
|
25973
26238
|
ch = state.input.charCodeAt(++state.position);
|
|
25974
|
-
|
|
26239
|
+
}
|
|
26240
|
+
if (state.position === _position) {
|
|
25975
26241
|
throwError(state, "name of an alias node must contain at least one character");
|
|
26242
|
+
}
|
|
25976
26243
|
const alias = state.input.slice(_position, state.position);
|
|
25977
|
-
if (!_hasOwnProperty.call(state.anchorMap, alias))
|
|
26244
|
+
if (!_hasOwnProperty.call(state.anchorMap, alias)) {
|
|
25978
26245
|
throwError(state, 'unidentified alias "' + alias + '"');
|
|
26246
|
+
}
|
|
25979
26247
|
state.result = state.anchorMap[alias];
|
|
25980
26248
|
skipSeparationSpace(state, true, -1);
|
|
25981
26249
|
return true;
|
|
@@ -26003,14 +26271,16 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
26003
26271
|
let atNewLine = false;
|
|
26004
26272
|
let hasContent = false;
|
|
26005
26273
|
let propertyStart = null;
|
|
26006
|
-
let
|
|
26274
|
+
let type2;
|
|
26007
26275
|
let flowIndent;
|
|
26008
26276
|
let blockIndent;
|
|
26009
|
-
if (state.depth >= state.maxDepth)
|
|
26277
|
+
if (state.depth >= state.maxDepth) {
|
|
26010
26278
|
throwError(state, "nesting exceeded maxDepth (" + state.maxDepth + ")");
|
|
26279
|
+
}
|
|
26011
26280
|
state.depth += 1;
|
|
26012
|
-
if (state.listener !== null)
|
|
26281
|
+
if (state.listener !== null) {
|
|
26013
26282
|
state.listener("open", state);
|
|
26283
|
+
}
|
|
26014
26284
|
state.tag = null;
|
|
26015
26285
|
state.anchor = null;
|
|
26016
26286
|
state.kind = null;
|
|
@@ -26019,110 +26289,131 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
26019
26289
|
if (allowToSeek) {
|
|
26020
26290
|
if (skipSeparationSpace(state, true, -1)) {
|
|
26021
26291
|
atNewLine = true;
|
|
26022
|
-
if (state.lineIndent > parentIndent)
|
|
26292
|
+
if (state.lineIndent > parentIndent) {
|
|
26023
26293
|
indentStatus = 1;
|
|
26024
|
-
else if (state.lineIndent === parentIndent)
|
|
26294
|
+
} else if (state.lineIndent === parentIndent) {
|
|
26025
26295
|
indentStatus = 0;
|
|
26026
|
-
else if (state.lineIndent < parentIndent)
|
|
26296
|
+
} else if (state.lineIndent < parentIndent) {
|
|
26027
26297
|
indentStatus = -1;
|
|
26298
|
+
}
|
|
26028
26299
|
}
|
|
26029
26300
|
}
|
|
26030
|
-
if (indentStatus === 1)
|
|
26301
|
+
if (indentStatus === 1) {
|
|
26031
26302
|
while (true) {
|
|
26032
26303
|
const ch = state.input.charCodeAt(state.position);
|
|
26033
26304
|
const propertyState = snapshotState(state);
|
|
26034
|
-
if (atNewLine && (ch === 33 && state.tag !== null || ch === 38 && state.anchor !== null))
|
|
26305
|
+
if (atNewLine && (ch === 33 && state.tag !== null || ch === 38 && state.anchor !== null)) {
|
|
26035
26306
|
break;
|
|
26036
|
-
|
|
26307
|
+
}
|
|
26308
|
+
if (!readTagProperty(state) && !readAnchorProperty(state)) {
|
|
26037
26309
|
break;
|
|
26038
|
-
|
|
26310
|
+
}
|
|
26311
|
+
if (propertyStart === null) {
|
|
26039
26312
|
propertyStart = propertyState;
|
|
26313
|
+
}
|
|
26040
26314
|
if (skipSeparationSpace(state, true, -1)) {
|
|
26041
26315
|
atNewLine = true;
|
|
26042
26316
|
allowBlockCollections = allowBlockStyles;
|
|
26043
|
-
if (state.lineIndent > parentIndent)
|
|
26317
|
+
if (state.lineIndent > parentIndent) {
|
|
26044
26318
|
indentStatus = 1;
|
|
26045
|
-
else if (state.lineIndent === parentIndent)
|
|
26319
|
+
} else if (state.lineIndent === parentIndent) {
|
|
26046
26320
|
indentStatus = 0;
|
|
26047
|
-
else if (state.lineIndent < parentIndent)
|
|
26321
|
+
} else if (state.lineIndent < parentIndent) {
|
|
26048
26322
|
indentStatus = -1;
|
|
26049
|
-
|
|
26323
|
+
}
|
|
26324
|
+
} else {
|
|
26050
26325
|
allowBlockCollections = false;
|
|
26326
|
+
}
|
|
26051
26327
|
}
|
|
26052
|
-
|
|
26328
|
+
}
|
|
26329
|
+
if (allowBlockCollections) {
|
|
26053
26330
|
allowBlockCollections = atNewLine || allowCompact;
|
|
26331
|
+
}
|
|
26054
26332
|
if (indentStatus === 1 || CONTEXT_BLOCK_OUT === nodeContext) {
|
|
26055
|
-
if (CONTEXT_FLOW_IN === nodeContext || CONTEXT_FLOW_OUT === nodeContext)
|
|
26333
|
+
if (CONTEXT_FLOW_IN === nodeContext || CONTEXT_FLOW_OUT === nodeContext) {
|
|
26056
26334
|
flowIndent = parentIndent;
|
|
26057
|
-
else
|
|
26335
|
+
} else {
|
|
26058
26336
|
flowIndent = parentIndent + 1;
|
|
26337
|
+
}
|
|
26059
26338
|
blockIndent = state.position - state.lineStart;
|
|
26060
|
-
if (indentStatus === 1)
|
|
26061
|
-
if (allowBlockCollections && (readBlockSequence(state, blockIndent) || readBlockMapping(state, blockIndent, flowIndent)) || readFlowCollection(state, flowIndent))
|
|
26339
|
+
if (indentStatus === 1) {
|
|
26340
|
+
if (allowBlockCollections && (readBlockSequence(state, blockIndent) || readBlockMapping(state, blockIndent, flowIndent)) || readFlowCollection(state, flowIndent)) {
|
|
26062
26341
|
hasContent = true;
|
|
26063
|
-
else {
|
|
26342
|
+
} else {
|
|
26064
26343
|
const ch = state.input.charCodeAt(state.position);
|
|
26065
|
-
if (propertyStart !== null && allowBlockStyles && !allowBlockCollections && ch !== 124 && ch !== 62 && tryReadBlockMappingFromProperty(state, propertyStart, propertyStart.position - propertyStart.lineStart, flowIndent))
|
|
26344
|
+
if (propertyStart !== null && allowBlockStyles && !allowBlockCollections && ch !== 124 && ch !== 62 && tryReadBlockMappingFromProperty(state, propertyStart, propertyStart.position - propertyStart.lineStart, flowIndent)) {
|
|
26066
26345
|
hasContent = true;
|
|
26067
|
-
else if (allowBlockScalars && readBlockScalar(state, flowIndent) || readSingleQuotedScalar(state, flowIndent) || readDoubleQuotedScalar(state, flowIndent))
|
|
26346
|
+
} else if (allowBlockScalars && readBlockScalar(state, flowIndent) || readSingleQuotedScalar(state, flowIndent) || readDoubleQuotedScalar(state, flowIndent)) {
|
|
26068
26347
|
hasContent = true;
|
|
26069
|
-
else if (readAlias(state)) {
|
|
26348
|
+
} else if (readAlias(state)) {
|
|
26070
26349
|
hasContent = true;
|
|
26071
|
-
if (state.tag !== null || state.anchor !== null)
|
|
26350
|
+
if (state.tag !== null || state.anchor !== null) {
|
|
26072
26351
|
throwError(state, "alias node should not have any properties");
|
|
26352
|
+
}
|
|
26073
26353
|
} else if (readPlainScalar(state, flowIndent, CONTEXT_FLOW_IN === nodeContext)) {
|
|
26074
26354
|
hasContent = true;
|
|
26075
|
-
if (state.tag === null)
|
|
26355
|
+
if (state.tag === null) {
|
|
26076
26356
|
state.tag = "?";
|
|
26357
|
+
}
|
|
26077
26358
|
}
|
|
26078
|
-
if (state.anchor !== null)
|
|
26359
|
+
if (state.anchor !== null) {
|
|
26079
26360
|
storeAnchor(state, state.anchor, state.result);
|
|
26361
|
+
}
|
|
26080
26362
|
}
|
|
26081
|
-
else if (indentStatus === 0)
|
|
26363
|
+
} else if (indentStatus === 0) {
|
|
26082
26364
|
hasContent = allowBlockCollections && readBlockSequence(state, blockIndent);
|
|
26365
|
+
}
|
|
26083
26366
|
}
|
|
26084
26367
|
if (state.tag === null) {
|
|
26085
|
-
if (state.anchor !== null)
|
|
26368
|
+
if (state.anchor !== null) {
|
|
26086
26369
|
storeAnchor(state, state.anchor, state.result);
|
|
26370
|
+
}
|
|
26087
26371
|
} else if (state.tag === "?") {
|
|
26088
|
-
if (state.result !== null && state.kind !== "scalar")
|
|
26372
|
+
if (state.result !== null && state.kind !== "scalar") {
|
|
26089
26373
|
throwError(state, 'unacceptable node kind for !<?> tag; it should be "scalar", not "' + state.kind + '"');
|
|
26374
|
+
}
|
|
26090
26375
|
for (let typeIndex = 0, typeQuantity = state.implicitTypes.length;typeIndex < typeQuantity; typeIndex += 1) {
|
|
26091
|
-
|
|
26092
|
-
if (
|
|
26093
|
-
state.result =
|
|
26094
|
-
state.tag =
|
|
26095
|
-
if (state.anchor !== null)
|
|
26376
|
+
type2 = state.implicitTypes[typeIndex];
|
|
26377
|
+
if (type2.resolve(state.result)) {
|
|
26378
|
+
state.result = type2.construct(state.result);
|
|
26379
|
+
state.tag = type2.tag;
|
|
26380
|
+
if (state.anchor !== null) {
|
|
26096
26381
|
storeAnchor(state, state.anchor, state.result);
|
|
26382
|
+
}
|
|
26097
26383
|
break;
|
|
26098
26384
|
}
|
|
26099
26385
|
}
|
|
26100
26386
|
} else if (state.tag !== "!") {
|
|
26101
|
-
if (_hasOwnProperty.call(state.typeMap[state.kind || "fallback"], state.tag))
|
|
26102
|
-
|
|
26103
|
-
else {
|
|
26104
|
-
|
|
26387
|
+
if (_hasOwnProperty.call(state.typeMap[state.kind || "fallback"], state.tag)) {
|
|
26388
|
+
type2 = state.typeMap[state.kind || "fallback"][state.tag];
|
|
26389
|
+
} else {
|
|
26390
|
+
type2 = null;
|
|
26105
26391
|
const typeList = state.typeMap.multi[state.kind || "fallback"];
|
|
26106
|
-
for (let typeIndex = 0, typeQuantity = typeList.length;typeIndex < typeQuantity; typeIndex += 1)
|
|
26392
|
+
for (let typeIndex = 0, typeQuantity = typeList.length;typeIndex < typeQuantity; typeIndex += 1) {
|
|
26107
26393
|
if (state.tag.slice(0, typeList[typeIndex].tag.length) === typeList[typeIndex].tag) {
|
|
26108
|
-
|
|
26394
|
+
type2 = typeList[typeIndex];
|
|
26109
26395
|
break;
|
|
26110
26396
|
}
|
|
26397
|
+
}
|
|
26111
26398
|
}
|
|
26112
|
-
if (!
|
|
26399
|
+
if (!type2) {
|
|
26113
26400
|
throwError(state, "unknown tag !<" + state.tag + ">");
|
|
26114
|
-
|
|
26115
|
-
|
|
26116
|
-
|
|
26401
|
+
}
|
|
26402
|
+
if (state.result !== null && type2.kind !== state.kind) {
|
|
26403
|
+
throwError(state, "unacceptable node kind for !<" + state.tag + '> tag; it should be "' + type2.kind + '", not "' + state.kind + '"');
|
|
26404
|
+
}
|
|
26405
|
+
if (!type2.resolve(state.result, state.tag)) {
|
|
26117
26406
|
throwError(state, "cannot resolve a node with !<" + state.tag + "> explicit tag");
|
|
26118
|
-
else {
|
|
26119
|
-
state.result =
|
|
26120
|
-
if (state.anchor !== null)
|
|
26407
|
+
} else {
|
|
26408
|
+
state.result = type2.construct(state.result, state.tag);
|
|
26409
|
+
if (state.anchor !== null) {
|
|
26121
26410
|
storeAnchor(state, state.anchor, state.result);
|
|
26411
|
+
}
|
|
26122
26412
|
}
|
|
26123
26413
|
}
|
|
26124
|
-
if (state.listener !== null)
|
|
26414
|
+
if (state.listener !== null) {
|
|
26125
26415
|
state.listener("close", state);
|
|
26416
|
+
}
|
|
26126
26417
|
state.depth -= 1;
|
|
26127
26418
|
return state.tag !== null || state.anchor !== null || hasContent;
|
|
26128
26419
|
}
|
|
@@ -26132,55 +26423,63 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
26132
26423
|
let ch;
|
|
26133
26424
|
state.version = null;
|
|
26134
26425
|
state.checkLineBreaks = state.legacy;
|
|
26135
|
-
state.tagMap = Object.create(null);
|
|
26136
|
-
state.anchorMap = Object.create(null);
|
|
26426
|
+
state.tagMap = /* @__PURE__ */ Object.create(null);
|
|
26427
|
+
state.anchorMap = /* @__PURE__ */ Object.create(null);
|
|
26137
26428
|
while ((ch = state.input.charCodeAt(state.position)) !== 0) {
|
|
26138
26429
|
skipSeparationSpace(state, true, -1);
|
|
26139
26430
|
ch = state.input.charCodeAt(state.position);
|
|
26140
|
-
if (state.lineIndent > 0 || ch !== 37)
|
|
26431
|
+
if (state.lineIndent > 0 || ch !== 37) {
|
|
26141
26432
|
break;
|
|
26433
|
+
}
|
|
26142
26434
|
hasDirectives = true;
|
|
26143
26435
|
ch = state.input.charCodeAt(++state.position);
|
|
26144
26436
|
let _position = state.position;
|
|
26145
|
-
while (ch !== 0 && !isWsOrEol(ch))
|
|
26437
|
+
while (ch !== 0 && !isWsOrEol(ch)) {
|
|
26146
26438
|
ch = state.input.charCodeAt(++state.position);
|
|
26439
|
+
}
|
|
26147
26440
|
const directiveName = state.input.slice(_position, state.position);
|
|
26148
26441
|
const directiveArgs = [];
|
|
26149
|
-
if (directiveName.length < 1)
|
|
26442
|
+
if (directiveName.length < 1) {
|
|
26150
26443
|
throwError(state, "directive name must not be less than one character in length");
|
|
26444
|
+
}
|
|
26151
26445
|
while (ch !== 0) {
|
|
26152
|
-
while (isWhiteSpace(ch))
|
|
26446
|
+
while (isWhiteSpace(ch)) {
|
|
26153
26447
|
ch = state.input.charCodeAt(++state.position);
|
|
26448
|
+
}
|
|
26154
26449
|
if (ch === 35) {
|
|
26155
|
-
do
|
|
26450
|
+
do {
|
|
26156
26451
|
ch = state.input.charCodeAt(++state.position);
|
|
26157
|
-
while (ch !== 0 && !isEol(ch));
|
|
26452
|
+
} while (ch !== 0 && !isEol(ch));
|
|
26158
26453
|
break;
|
|
26159
26454
|
}
|
|
26160
26455
|
if (isEol(ch))
|
|
26161
26456
|
break;
|
|
26162
26457
|
_position = state.position;
|
|
26163
|
-
while (ch !== 0 && !isWsOrEol(ch))
|
|
26458
|
+
while (ch !== 0 && !isWsOrEol(ch)) {
|
|
26164
26459
|
ch = state.input.charCodeAt(++state.position);
|
|
26460
|
+
}
|
|
26165
26461
|
directiveArgs.push(state.input.slice(_position, state.position));
|
|
26166
26462
|
}
|
|
26167
26463
|
if (ch !== 0)
|
|
26168
26464
|
readLineBreak(state);
|
|
26169
|
-
if (_hasOwnProperty.call(directiveHandlers, directiveName))
|
|
26465
|
+
if (_hasOwnProperty.call(directiveHandlers, directiveName)) {
|
|
26170
26466
|
directiveHandlers[directiveName](state, directiveName, directiveArgs);
|
|
26171
|
-
else
|
|
26467
|
+
} else {
|
|
26172
26468
|
throwWarning(state, 'unknown document directive "' + directiveName + '"');
|
|
26469
|
+
}
|
|
26173
26470
|
}
|
|
26174
26471
|
skipSeparationSpace(state, true, -1);
|
|
26175
26472
|
if (state.lineIndent === 0 && state.input.charCodeAt(state.position) === 45 && state.input.charCodeAt(state.position + 1) === 45 && state.input.charCodeAt(state.position + 2) === 45) {
|
|
26176
26473
|
state.position += 3;
|
|
26177
26474
|
skipSeparationSpace(state, true, -1);
|
|
26178
|
-
} else if (hasDirectives)
|
|
26475
|
+
} else if (hasDirectives) {
|
|
26179
26476
|
throwError(state, "directives end mark is expected");
|
|
26477
|
+
}
|
|
26180
26478
|
composeNode(state, state.lineIndent - 1, CONTEXT_BLOCK_OUT, false, true);
|
|
26181
26479
|
skipSeparationSpace(state, true, -1);
|
|
26182
|
-
if (state.checkLineBreaks && PATTERN_NON_ASCII_LINE_BREAKS.test(state.input.slice(documentStart, state.position)))
|
|
26480
|
+
if (state.checkLineBreaks && PATTERN_NON_ASCII_LINE_BREAKS.test(state.input.slice(documentStart, state.position))) {
|
|
26183
26481
|
throwWarning(state, "non-ASCII line breaks are interpreted as content");
|
|
26482
|
+
}
|
|
26184
26483
|
state.documents.push(state.result);
|
|
26185
26484
|
if (state.position === state.lineStart && testDocumentSeparator(state)) {
|
|
26186
26485
|
if (state.input.charCodeAt(state.position) === 46) {
|
|
@@ -26189,18 +26488,21 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
26189
26488
|
}
|
|
26190
26489
|
return;
|
|
26191
26490
|
}
|
|
26192
|
-
if (state.position < state.length - 1)
|
|
26491
|
+
if (state.position < state.length - 1) {
|
|
26193
26492
|
throwError(state, "end of the stream or a document separator is expected");
|
|
26493
|
+
}
|
|
26194
26494
|
}
|
|
26195
26495
|
function loadDocuments(input, options) {
|
|
26196
26496
|
input = String(input);
|
|
26197
26497
|
options = options || {};
|
|
26198
26498
|
if (input.length !== 0) {
|
|
26199
|
-
if (input.charCodeAt(input.length - 1) !== 10 && input.charCodeAt(input.length - 1) !== 13)
|
|
26499
|
+
if (input.charCodeAt(input.length - 1) !== 10 && input.charCodeAt(input.length - 1) !== 13) {
|
|
26200
26500
|
input += `
|
|
26201
26501
|
`;
|
|
26202
|
-
|
|
26502
|
+
}
|
|
26503
|
+
if (input.charCodeAt(0) === 65279) {
|
|
26203
26504
|
input = input.slice(1);
|
|
26505
|
+
}
|
|
26204
26506
|
}
|
|
26205
26507
|
const state = new State(input, options);
|
|
26206
26508
|
const nullpos = input.indexOf("\x00");
|
|
@@ -26213,64 +26515,74 @@ var require_loader = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
26213
26515
|
state.lineIndent += 1;
|
|
26214
26516
|
state.position += 1;
|
|
26215
26517
|
}
|
|
26216
|
-
while (state.position < state.length - 1)
|
|
26518
|
+
while (state.position < state.length - 1) {
|
|
26217
26519
|
readDocument(state);
|
|
26520
|
+
}
|
|
26218
26521
|
return state.documents;
|
|
26219
26522
|
}
|
|
26220
|
-
function
|
|
26523
|
+
function loadAll2(input, iterator, options) {
|
|
26221
26524
|
if (iterator !== null && typeof iterator === "object" && typeof options === "undefined") {
|
|
26222
26525
|
options = iterator;
|
|
26223
26526
|
iterator = null;
|
|
26224
26527
|
}
|
|
26225
26528
|
const documents = loadDocuments(input, options);
|
|
26226
|
-
if (typeof iterator !== "function")
|
|
26529
|
+
if (typeof iterator !== "function") {
|
|
26227
26530
|
return documents;
|
|
26228
|
-
|
|
26531
|
+
}
|
|
26532
|
+
for (let index = 0, length = documents.length;index < length; index += 1) {
|
|
26229
26533
|
iterator(documents[index]);
|
|
26534
|
+
}
|
|
26230
26535
|
}
|
|
26231
|
-
function
|
|
26536
|
+
function load2(input, options) {
|
|
26232
26537
|
const documents = loadDocuments(input, options);
|
|
26233
|
-
if (documents.length === 0)
|
|
26538
|
+
if (documents.length === 0) {
|
|
26234
26539
|
return;
|
|
26235
|
-
else if (documents.length === 1)
|
|
26540
|
+
} else if (documents.length === 1) {
|
|
26236
26541
|
return documents[0];
|
|
26237
|
-
|
|
26542
|
+
}
|
|
26543
|
+
throw new YAMLException2("expected a single document in the stream, but found more");
|
|
26238
26544
|
}
|
|
26239
|
-
|
|
26240
|
-
|
|
26241
|
-
|
|
26242
|
-
|
|
26243
|
-
|
|
26244
|
-
|
|
26245
|
-
|
|
26246
|
-
|
|
26247
|
-
|
|
26248
|
-
|
|
26249
|
-
|
|
26250
|
-
|
|
26251
|
-
|
|
26252
|
-
|
|
26253
|
-
|
|
26254
|
-
|
|
26255
|
-
|
|
26256
|
-
|
|
26257
|
-
|
|
26258
|
-
|
|
26259
|
-
|
|
26260
|
-
|
|
26261
|
-
|
|
26262
|
-
|
|
26263
|
-
|
|
26264
|
-
|
|
26265
|
-
|
|
26266
|
-
|
|
26267
|
-
|
|
26268
|
-
|
|
26269
|
-
|
|
26270
|
-
|
|
26271
|
-
|
|
26272
|
-
|
|
26273
|
-
|
|
26545
|
+
loader.loadAll = loadAll2;
|
|
26546
|
+
loader.load = load2;
|
|
26547
|
+
return loader;
|
|
26548
|
+
}
|
|
26549
|
+
var dumper = {};
|
|
26550
|
+
var hasRequiredDumper;
|
|
26551
|
+
function requireDumper() {
|
|
26552
|
+
if (hasRequiredDumper)
|
|
26553
|
+
return dumper;
|
|
26554
|
+
hasRequiredDumper = 1;
|
|
26555
|
+
const common2 = requireCommon();
|
|
26556
|
+
const YAMLException2 = requireException();
|
|
26557
|
+
const DEFAULT_SCHEMA2 = require_default();
|
|
26558
|
+
const _toString = Object.prototype.toString;
|
|
26559
|
+
const _hasOwnProperty = Object.prototype.hasOwnProperty;
|
|
26560
|
+
const CHAR_BOM = 65279;
|
|
26561
|
+
const CHAR_TAB = 9;
|
|
26562
|
+
const CHAR_LINE_FEED = 10;
|
|
26563
|
+
const CHAR_CARRIAGE_RETURN = 13;
|
|
26564
|
+
const CHAR_SPACE = 32;
|
|
26565
|
+
const CHAR_EXCLAMATION = 33;
|
|
26566
|
+
const CHAR_DOUBLE_QUOTE = 34;
|
|
26567
|
+
const CHAR_SHARP = 35;
|
|
26568
|
+
const CHAR_PERCENT = 37;
|
|
26569
|
+
const CHAR_AMPERSAND = 38;
|
|
26570
|
+
const CHAR_SINGLE_QUOTE = 39;
|
|
26571
|
+
const CHAR_ASTERISK = 42;
|
|
26572
|
+
const CHAR_COMMA = 44;
|
|
26573
|
+
const CHAR_MINUS = 45;
|
|
26574
|
+
const CHAR_COLON = 58;
|
|
26575
|
+
const CHAR_EQUALS = 61;
|
|
26576
|
+
const CHAR_GREATER_THAN = 62;
|
|
26577
|
+
const CHAR_QUESTION = 63;
|
|
26578
|
+
const CHAR_COMMERCIAL_AT = 64;
|
|
26579
|
+
const CHAR_LEFT_SQUARE_BRACKET = 91;
|
|
26580
|
+
const CHAR_RIGHT_SQUARE_BRACKET = 93;
|
|
26581
|
+
const CHAR_GRAVE_ACCENT = 96;
|
|
26582
|
+
const CHAR_LEFT_CURLY_BRACKET = 123;
|
|
26583
|
+
const CHAR_VERTICAL_LINE = 124;
|
|
26584
|
+
const CHAR_RIGHT_CURLY_BRACKET = 125;
|
|
26585
|
+
const ESCAPE_SEQUENCES = {};
|
|
26274
26586
|
ESCAPE_SEQUENCES[0] = "\\0";
|
|
26275
26587
|
ESCAPE_SEQUENCES[7] = "\\a";
|
|
26276
26588
|
ESCAPE_SEQUENCES[8] = "\\b";
|
|
@@ -26286,7 +26598,7 @@ var require_dumper = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
26286
26598
|
ESCAPE_SEQUENCES[160] = "\\_";
|
|
26287
26599
|
ESCAPE_SEQUENCES[8232] = "\\L";
|
|
26288
26600
|
ESCAPE_SEQUENCES[8233] = "\\P";
|
|
26289
|
-
|
|
26601
|
+
const DEPRECATED_BOOLEANS_SYNTAX = [
|
|
26290
26602
|
"y",
|
|
26291
26603
|
"Y",
|
|
26292
26604
|
"yes",
|
|
@@ -26304,20 +26616,22 @@ var require_dumper = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
26304
26616
|
"Off",
|
|
26305
26617
|
"OFF"
|
|
26306
26618
|
];
|
|
26307
|
-
|
|
26308
|
-
function compileStyleMap(
|
|
26309
|
-
if (
|
|
26619
|
+
const DEPRECATED_BASE60_SYNTAX = /^[-+]?[0-9_]+(?::[0-9_]+)+(?:\.[0-9_]*)?$/;
|
|
26620
|
+
function compileStyleMap(schema2, map2) {
|
|
26621
|
+
if (map2 === null)
|
|
26310
26622
|
return {};
|
|
26311
26623
|
const result = {};
|
|
26312
|
-
const keys = Object.keys(
|
|
26624
|
+
const keys = Object.keys(map2);
|
|
26313
26625
|
for (let index = 0, length = keys.length;index < length; index += 1) {
|
|
26314
26626
|
let tag = keys[index];
|
|
26315
|
-
let style = String(
|
|
26316
|
-
if (tag.slice(0, 2) === "!!")
|
|
26627
|
+
let style = String(map2[tag]);
|
|
26628
|
+
if (tag.slice(0, 2) === "!!") {
|
|
26317
26629
|
tag = "tag:yaml.org,2002:" + tag.slice(2);
|
|
26318
|
-
|
|
26319
|
-
|
|
26320
|
-
|
|
26630
|
+
}
|
|
26631
|
+
const type2 = schema2.compiledTypeMap["fallback"][tag];
|
|
26632
|
+
if (type2 && _hasOwnProperty.call(type2.styleAliases, style)) {
|
|
26633
|
+
style = type2.styleAliases[style];
|
|
26634
|
+
}
|
|
26321
26635
|
result[tag] = style;
|
|
26322
26636
|
}
|
|
26323
26637
|
return result;
|
|
@@ -26335,18 +26649,19 @@ var require_dumper = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
26335
26649
|
} else if (character <= 4294967295) {
|
|
26336
26650
|
handle = "U";
|
|
26337
26651
|
length = 8;
|
|
26338
|
-
} else
|
|
26339
|
-
throw new
|
|
26340
|
-
|
|
26652
|
+
} else {
|
|
26653
|
+
throw new YAMLException2("code point within a string may not be greater than 0xFFFFFFFF");
|
|
26654
|
+
}
|
|
26655
|
+
return "\\" + handle + common2.repeat("0", length - string.length) + string;
|
|
26341
26656
|
}
|
|
26342
|
-
|
|
26343
|
-
|
|
26657
|
+
const QUOTING_TYPE_SINGLE = 1;
|
|
26658
|
+
const QUOTING_TYPE_DOUBLE = 2;
|
|
26344
26659
|
function State(options) {
|
|
26345
|
-
this.schema = options["schema"] ||
|
|
26660
|
+
this.schema = options["schema"] || DEFAULT_SCHEMA2;
|
|
26346
26661
|
this.indent = Math.max(1, options["indent"] || 2);
|
|
26347
26662
|
this.noArrayIndent = options["noArrayIndent"] || false;
|
|
26348
26663
|
this.skipInvalid = options["skipInvalid"] || false;
|
|
26349
|
-
this.flowLevel =
|
|
26664
|
+
this.flowLevel = common2.isNothing(options["flowLevel"]) ? -1 : options["flowLevel"];
|
|
26350
26665
|
this.styleMap = compileStyleMap(this.schema, options["styles"] || null);
|
|
26351
26666
|
this.sortKeys = options["sortKeys"] || false;
|
|
26352
26667
|
this.lineWidth = options["lineWidth"] || 80;
|
|
@@ -26364,7 +26679,7 @@ var require_dumper = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
26364
26679
|
this.usedDuplicates = null;
|
|
26365
26680
|
}
|
|
26366
26681
|
function indentString(string, spaces) {
|
|
26367
|
-
const ind =
|
|
26682
|
+
const ind = common2.repeat(" ", spaces);
|
|
26368
26683
|
let position = 0;
|
|
26369
26684
|
let result = "";
|
|
26370
26685
|
const length = string.length;
|
|
@@ -26388,12 +26703,15 @@ var require_dumper = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
26388
26703
|
}
|
|
26389
26704
|
function generateNextLine(state, level) {
|
|
26390
26705
|
return `
|
|
26391
|
-
` +
|
|
26706
|
+
` + common2.repeat(" ", state.indent * level);
|
|
26392
26707
|
}
|
|
26393
|
-
function testImplicitResolving(state,
|
|
26394
|
-
for (let index = 0, length = state.implicitTypes.length;index < length; index += 1)
|
|
26395
|
-
|
|
26708
|
+
function testImplicitResolving(state, str2) {
|
|
26709
|
+
for (let index = 0, length = state.implicitTypes.length;index < length; index += 1) {
|
|
26710
|
+
const type2 = state.implicitTypes[index];
|
|
26711
|
+
if (type2.resolve(str2)) {
|
|
26396
26712
|
return true;
|
|
26713
|
+
}
|
|
26714
|
+
}
|
|
26397
26715
|
return false;
|
|
26398
26716
|
}
|
|
26399
26717
|
function isWhitespace(c) {
|
|
@@ -26421,19 +26739,21 @@ var require_dumper = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
26421
26739
|
let second;
|
|
26422
26740
|
if (first >= 55296 && first <= 56319 && pos + 1 < string.length) {
|
|
26423
26741
|
second = string.charCodeAt(pos + 1);
|
|
26424
|
-
if (second >= 56320 && second <= 57343)
|
|
26742
|
+
if (second >= 56320 && second <= 57343) {
|
|
26425
26743
|
return (first - 55296) * 1024 + second - 56320 + 65536;
|
|
26744
|
+
}
|
|
26426
26745
|
}
|
|
26427
26746
|
return first;
|
|
26428
26747
|
}
|
|
26429
26748
|
function needIndentIndicator(string) {
|
|
26430
|
-
|
|
26431
|
-
|
|
26432
|
-
|
|
26433
|
-
|
|
26434
|
-
|
|
26435
|
-
|
|
26436
|
-
|
|
26749
|
+
const leadingSpaceRe = /^\n* /;
|
|
26750
|
+
return leadingSpaceRe.test(string);
|
|
26751
|
+
}
|
|
26752
|
+
const STYLE_PLAIN = 1;
|
|
26753
|
+
const STYLE_SINGLE = 2;
|
|
26754
|
+
const STYLE_LITERAL = 3;
|
|
26755
|
+
const STYLE_FOLDED = 4;
|
|
26756
|
+
const STYLE_DOUBLE = 5;
|
|
26437
26757
|
function chooseScalarStyle(string, singleLineOnly, indentPerLevel, lineWidth, testAmbiguousType, quotingType, forceQuotes, inblock) {
|
|
26438
26758
|
let i;
|
|
26439
26759
|
let char = 0;
|
|
@@ -26443,15 +26763,16 @@ var require_dumper = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
26443
26763
|
const shouldTrackWidth = lineWidth !== -1;
|
|
26444
26764
|
let previousLineBreak = -1;
|
|
26445
26765
|
let plain = isPlainSafeFirst(codePointAt(string, 0)) && isPlainSafeLast(codePointAt(string, string.length - 1));
|
|
26446
|
-
if (singleLineOnly || forceQuotes)
|
|
26766
|
+
if (singleLineOnly || forceQuotes) {
|
|
26447
26767
|
for (i = 0;i < string.length; char >= 65536 ? i += 2 : i++) {
|
|
26448
26768
|
char = codePointAt(string, i);
|
|
26449
|
-
if (!isPrintable(char))
|
|
26769
|
+
if (!isPrintable(char)) {
|
|
26450
26770
|
return STYLE_DOUBLE;
|
|
26771
|
+
}
|
|
26451
26772
|
plain = plain && isPlainSafe(char, prevChar, inblock);
|
|
26452
26773
|
prevChar = char;
|
|
26453
26774
|
}
|
|
26454
|
-
else {
|
|
26775
|
+
} else {
|
|
26455
26776
|
for (i = 0;i < string.length; char >= 65536 ? i += 2 : i++) {
|
|
26456
26777
|
char = codePointAt(string, i);
|
|
26457
26778
|
if (char === CHAR_LINE_FEED) {
|
|
@@ -26460,31 +26781,37 @@ var require_dumper = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
26460
26781
|
hasFoldableLine = hasFoldableLine || i - previousLineBreak - 1 > lineWidth && string[previousLineBreak + 1] !== " ";
|
|
26461
26782
|
previousLineBreak = i;
|
|
26462
26783
|
}
|
|
26463
|
-
} else if (!isPrintable(char))
|
|
26784
|
+
} else if (!isPrintable(char)) {
|
|
26464
26785
|
return STYLE_DOUBLE;
|
|
26786
|
+
}
|
|
26465
26787
|
plain = plain && isPlainSafe(char, prevChar, inblock);
|
|
26466
26788
|
prevChar = char;
|
|
26467
26789
|
}
|
|
26468
|
-
hasFoldableLine = hasFoldableLine || shouldTrackWidth && i - previousLineBreak - 1 > lineWidth && string[previousLineBreak + 1] !== " ";
|
|
26790
|
+
hasFoldableLine = hasFoldableLine || shouldTrackWidth && (i - previousLineBreak - 1 > lineWidth && string[previousLineBreak + 1] !== " ");
|
|
26469
26791
|
}
|
|
26470
26792
|
if (!hasLineBreak && !hasFoldableLine) {
|
|
26471
|
-
if (plain && !forceQuotes && !testAmbiguousType(string))
|
|
26793
|
+
if (plain && !forceQuotes && !testAmbiguousType(string)) {
|
|
26472
26794
|
return STYLE_PLAIN;
|
|
26795
|
+
}
|
|
26473
26796
|
return quotingType === QUOTING_TYPE_DOUBLE ? STYLE_DOUBLE : STYLE_SINGLE;
|
|
26474
26797
|
}
|
|
26475
|
-
if (indentPerLevel > 9 && needIndentIndicator(string))
|
|
26798
|
+
if (indentPerLevel > 9 && needIndentIndicator(string)) {
|
|
26476
26799
|
return STYLE_DOUBLE;
|
|
26477
|
-
|
|
26800
|
+
}
|
|
26801
|
+
if (!forceQuotes) {
|
|
26478
26802
|
return hasFoldableLine ? STYLE_FOLDED : STYLE_LITERAL;
|
|
26803
|
+
}
|
|
26479
26804
|
return quotingType === QUOTING_TYPE_DOUBLE ? STYLE_DOUBLE : STYLE_SINGLE;
|
|
26480
26805
|
}
|
|
26481
26806
|
function writeScalar(state, string, level, iskey, inblock) {
|
|
26482
26807
|
state.dump = function() {
|
|
26483
|
-
if (string.length === 0)
|
|
26808
|
+
if (string.length === 0) {
|
|
26484
26809
|
return state.quotingType === QUOTING_TYPE_DOUBLE ? '""' : "''";
|
|
26810
|
+
}
|
|
26485
26811
|
if (!state.noCompatMode) {
|
|
26486
|
-
if (DEPRECATED_BOOLEANS_SYNTAX.indexOf(string) !== -1 || DEPRECATED_BASE60_SYNTAX.test(string))
|
|
26812
|
+
if (DEPRECATED_BOOLEANS_SYNTAX.indexOf(string) !== -1 || DEPRECATED_BASE60_SYNTAX.test(string)) {
|
|
26487
26813
|
return state.quotingType === QUOTING_TYPE_DOUBLE ? '"' + string + '"' : "'" + string + "'";
|
|
26814
|
+
}
|
|
26488
26815
|
}
|
|
26489
26816
|
const indent = state.indent * Math.max(1, level);
|
|
26490
26817
|
const lineWidth = state.lineWidth === -1 ? -1 : Math.max(Math.min(state.lineWidth, 40), state.lineWidth - indent);
|
|
@@ -26502,9 +26829,9 @@ var require_dumper = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
26502
26829
|
case STYLE_FOLDED:
|
|
26503
26830
|
return ">" + blockHeader(string, state.indent) + dropEndingNewline(indentString(foldString(string, lineWidth), indent));
|
|
26504
26831
|
case STYLE_DOUBLE:
|
|
26505
|
-
return '"' + escapeString(string
|
|
26832
|
+
return '"' + escapeString(string) + '"';
|
|
26506
26833
|
default:
|
|
26507
|
-
throw new
|
|
26834
|
+
throw new YAMLException2("impossible error: invalid scalar style");
|
|
26508
26835
|
}
|
|
26509
26836
|
}();
|
|
26510
26837
|
}
|
|
@@ -26512,9 +26839,11 @@ var require_dumper = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
26512
26839
|
const indentIndicator = needIndentIndicator(string) ? String(indentPerLevel) : "";
|
|
26513
26840
|
const clip = string[string.length - 1] === `
|
|
26514
26841
|
`;
|
|
26515
|
-
|
|
26842
|
+
const keep = clip && (string[string.length - 2] === `
|
|
26516
26843
|
` || string === `
|
|
26517
|
-
`)
|
|
26844
|
+
`);
|
|
26845
|
+
const chomp = keep ? "+" : clip ? "" : "-";
|
|
26846
|
+
return indentIndicator + chomp + `
|
|
26518
26847
|
`;
|
|
26519
26848
|
}
|
|
26520
26849
|
function dropEndingNewline(string) {
|
|
@@ -26566,11 +26895,12 @@ var require_dumper = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
26566
26895
|
}
|
|
26567
26896
|
result += `
|
|
26568
26897
|
`;
|
|
26569
|
-
if (line.length - start > width && curr > start)
|
|
26898
|
+
if (line.length - start > width && curr > start) {
|
|
26570
26899
|
result += line.slice(start, curr) + `
|
|
26571
26900
|
` + line.slice(curr + 1);
|
|
26572
|
-
else
|
|
26901
|
+
} else {
|
|
26573
26902
|
result += line.slice(start);
|
|
26903
|
+
}
|
|
26574
26904
|
return result.slice(1);
|
|
26575
26905
|
}
|
|
26576
26906
|
function escapeString(string) {
|
|
@@ -26583,8 +26913,9 @@ var require_dumper = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
26583
26913
|
result += string[i];
|
|
26584
26914
|
if (char >= 65536)
|
|
26585
26915
|
result += string[i + 1];
|
|
26586
|
-
} else
|
|
26916
|
+
} else {
|
|
26587
26917
|
result += escapeSeq || encodeHex(char);
|
|
26918
|
+
}
|
|
26588
26919
|
}
|
|
26589
26920
|
return result;
|
|
26590
26921
|
}
|
|
@@ -26593,8 +26924,9 @@ var require_dumper = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
26593
26924
|
const _tag = state.tag;
|
|
26594
26925
|
for (let index = 0, length = object.length;index < length; index += 1) {
|
|
26595
26926
|
let value = object[index];
|
|
26596
|
-
if (state.replacer)
|
|
26927
|
+
if (state.replacer) {
|
|
26597
26928
|
value = state.replacer.call(object, String(index), value);
|
|
26929
|
+
}
|
|
26598
26930
|
if (writeNode(state, level, value, false, false) || typeof value === "undefined" && writeNode(state, level, null, false, false)) {
|
|
26599
26931
|
if (_result !== "")
|
|
26600
26932
|
_result += "," + (!state.condenseFlow ? " " : "");
|
|
@@ -26609,15 +26941,18 @@ var require_dumper = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
26609
26941
|
const _tag = state.tag;
|
|
26610
26942
|
for (let index = 0, length = object.length;index < length; index += 1) {
|
|
26611
26943
|
let value = object[index];
|
|
26612
|
-
if (state.replacer)
|
|
26944
|
+
if (state.replacer) {
|
|
26613
26945
|
value = state.replacer.call(object, String(index), value);
|
|
26946
|
+
}
|
|
26614
26947
|
if (writeNode(state, level + 1, value, true, true, false, true) || typeof value === "undefined" && writeNode(state, level + 1, null, true, true, false, true)) {
|
|
26615
|
-
if (!compact || _result !== "")
|
|
26948
|
+
if (!compact || _result !== "") {
|
|
26616
26949
|
_result += generateNextLine(state, level);
|
|
26617
|
-
|
|
26950
|
+
}
|
|
26951
|
+
if (state.dump && CHAR_LINE_FEED === state.dump.charCodeAt(0)) {
|
|
26618
26952
|
_result += "-";
|
|
26619
|
-
else
|
|
26953
|
+
} else {
|
|
26620
26954
|
_result += "- ";
|
|
26955
|
+
}
|
|
26621
26956
|
_result += state.dump;
|
|
26622
26957
|
}
|
|
26623
26958
|
}
|
|
@@ -26636,15 +26971,18 @@ var require_dumper = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
26636
26971
|
pairBuffer += '"';
|
|
26637
26972
|
const objectKey = objectKeyList[index];
|
|
26638
26973
|
let objectValue = object[objectKey];
|
|
26639
|
-
if (state.replacer)
|
|
26974
|
+
if (state.replacer) {
|
|
26640
26975
|
objectValue = state.replacer.call(object, objectKey, objectValue);
|
|
26641
|
-
|
|
26976
|
+
}
|
|
26977
|
+
if (!writeNode(state, level, objectKey, false, false)) {
|
|
26642
26978
|
continue;
|
|
26979
|
+
}
|
|
26643
26980
|
if (state.dump.length > 1024)
|
|
26644
26981
|
pairBuffer += "? ";
|
|
26645
26982
|
pairBuffer += state.dump + (state.condenseFlow ? '"' : "") + ":" + (state.condenseFlow ? "" : " ");
|
|
26646
|
-
if (!writeNode(state, level, objectValue, false, false))
|
|
26983
|
+
if (!writeNode(state, level, objectValue, false, false)) {
|
|
26647
26984
|
continue;
|
|
26985
|
+
}
|
|
26648
26986
|
pairBuffer += state.dump;
|
|
26649
26987
|
_result += pairBuffer;
|
|
26650
26988
|
}
|
|
@@ -26655,37 +26993,46 @@ var require_dumper = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
26655
26993
|
let _result = "";
|
|
26656
26994
|
const _tag = state.tag;
|
|
26657
26995
|
const objectKeyList = Object.keys(object);
|
|
26658
|
-
if (state.sortKeys === true)
|
|
26996
|
+
if (state.sortKeys === true) {
|
|
26659
26997
|
objectKeyList.sort();
|
|
26660
|
-
else if (typeof state.sortKeys === "function")
|
|
26998
|
+
} else if (typeof state.sortKeys === "function") {
|
|
26661
26999
|
objectKeyList.sort(state.sortKeys);
|
|
26662
|
-
else if (state.sortKeys)
|
|
26663
|
-
throw new
|
|
27000
|
+
} else if (state.sortKeys) {
|
|
27001
|
+
throw new YAMLException2("sortKeys must be a boolean or a function");
|
|
27002
|
+
}
|
|
26664
27003
|
for (let index = 0, length = objectKeyList.length;index < length; index += 1) {
|
|
26665
27004
|
let pairBuffer = "";
|
|
26666
|
-
if (!compact || _result !== "")
|
|
27005
|
+
if (!compact || _result !== "") {
|
|
26667
27006
|
pairBuffer += generateNextLine(state, level);
|
|
27007
|
+
}
|
|
26668
27008
|
const objectKey = objectKeyList[index];
|
|
26669
27009
|
let objectValue = object[objectKey];
|
|
26670
|
-
if (state.replacer)
|
|
27010
|
+
if (state.replacer) {
|
|
26671
27011
|
objectValue = state.replacer.call(object, objectKey, objectValue);
|
|
26672
|
-
|
|
27012
|
+
}
|
|
27013
|
+
if (!writeNode(state, level + 1, objectKey, true, true, true)) {
|
|
26673
27014
|
continue;
|
|
27015
|
+
}
|
|
26674
27016
|
const explicitPair = state.tag !== null && state.tag !== "?" || state.dump && state.dump.length > 1024;
|
|
26675
|
-
if (explicitPair)
|
|
26676
|
-
if (state.dump && CHAR_LINE_FEED === state.dump.charCodeAt(0))
|
|
27017
|
+
if (explicitPair) {
|
|
27018
|
+
if (state.dump && CHAR_LINE_FEED === state.dump.charCodeAt(0)) {
|
|
26677
27019
|
pairBuffer += "?";
|
|
26678
|
-
else
|
|
27020
|
+
} else {
|
|
26679
27021
|
pairBuffer += "? ";
|
|
27022
|
+
}
|
|
27023
|
+
}
|
|
26680
27024
|
pairBuffer += state.dump;
|
|
26681
|
-
if (explicitPair)
|
|
27025
|
+
if (explicitPair) {
|
|
26682
27026
|
pairBuffer += generateNextLine(state, level);
|
|
26683
|
-
|
|
27027
|
+
}
|
|
27028
|
+
if (!writeNode(state, level + 1, objectValue, true, explicitPair)) {
|
|
26684
27029
|
continue;
|
|
26685
|
-
|
|
27030
|
+
}
|
|
27031
|
+
if (state.dump && CHAR_LINE_FEED === state.dump.charCodeAt(0)) {
|
|
26686
27032
|
pairBuffer += ":";
|
|
26687
|
-
else
|
|
27033
|
+
} else {
|
|
26688
27034
|
pairBuffer += ": ";
|
|
27035
|
+
}
|
|
26689
27036
|
pairBuffer += state.dump;
|
|
26690
27037
|
_result += pairBuffer;
|
|
26691
27038
|
}
|
|
@@ -26695,24 +27042,27 @@ var require_dumper = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
26695
27042
|
function detectType(state, object, explicit) {
|
|
26696
27043
|
const typeList = explicit ? state.explicitTypes : state.implicitTypes;
|
|
26697
27044
|
for (let index = 0, length = typeList.length;index < length; index += 1) {
|
|
26698
|
-
const
|
|
26699
|
-
if ((
|
|
26700
|
-
if (explicit)
|
|
26701
|
-
if (
|
|
26702
|
-
state.tag =
|
|
26703
|
-
else
|
|
26704
|
-
state.tag =
|
|
26705
|
-
|
|
27045
|
+
const type2 = typeList[index];
|
|
27046
|
+
if ((type2.instanceOf || type2.predicate) && (!type2.instanceOf || typeof object === "object" && object instanceof type2.instanceOf) && (!type2.predicate || type2.predicate(object))) {
|
|
27047
|
+
if (explicit) {
|
|
27048
|
+
if (type2.multi && type2.representName) {
|
|
27049
|
+
state.tag = type2.representName(object);
|
|
27050
|
+
} else {
|
|
27051
|
+
state.tag = type2.tag;
|
|
27052
|
+
}
|
|
27053
|
+
} else {
|
|
26706
27054
|
state.tag = "?";
|
|
26707
|
-
|
|
26708
|
-
|
|
27055
|
+
}
|
|
27056
|
+
if (type2.represent) {
|
|
27057
|
+
const style = state.styleMap[type2.tag] || type2.defaultStyle;
|
|
26709
27058
|
let _result;
|
|
26710
|
-
if (_toString.call(
|
|
26711
|
-
_result =
|
|
26712
|
-
else if (_hasOwnProperty.call(
|
|
26713
|
-
_result =
|
|
26714
|
-
else
|
|
26715
|
-
throw new
|
|
27059
|
+
if (_toString.call(type2.represent) === "[object Function]") {
|
|
27060
|
+
_result = type2.represent(object, style);
|
|
27061
|
+
} else if (_hasOwnProperty.call(type2.represent, style)) {
|
|
27062
|
+
_result = type2.represent[style](object, style);
|
|
27063
|
+
} else {
|
|
27064
|
+
throw new YAMLException2("!<" + type2.tag + '> tag resolver accepts not "' + style + '" style');
|
|
27065
|
+
}
|
|
26716
27066
|
state.dump = _result;
|
|
26717
27067
|
}
|
|
26718
27068
|
return true;
|
|
@@ -26723,67 +27073,78 @@ var require_dumper = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
26723
27073
|
function writeNode(state, level, object, block, compact, iskey, isblockseq) {
|
|
26724
27074
|
state.tag = null;
|
|
26725
27075
|
state.dump = object;
|
|
26726
|
-
if (!detectType(state, object, false))
|
|
27076
|
+
if (!detectType(state, object, false)) {
|
|
26727
27077
|
detectType(state, object, true);
|
|
26728
|
-
|
|
27078
|
+
}
|
|
27079
|
+
const type2 = _toString.call(state.dump);
|
|
26729
27080
|
const inblock = block;
|
|
26730
|
-
if (block)
|
|
27081
|
+
if (block) {
|
|
26731
27082
|
block = state.flowLevel < 0 || state.flowLevel > level;
|
|
26732
|
-
|
|
27083
|
+
}
|
|
27084
|
+
const objectOrArray = type2 === "[object Object]" || type2 === "[object Array]";
|
|
26733
27085
|
let duplicateIndex;
|
|
26734
27086
|
let duplicate;
|
|
26735
27087
|
if (objectOrArray) {
|
|
26736
27088
|
duplicateIndex = state.duplicates.indexOf(object);
|
|
26737
27089
|
duplicate = duplicateIndex !== -1;
|
|
26738
27090
|
}
|
|
26739
|
-
if (state.tag !== null && state.tag !== "?" || duplicate || state.indent !== 2 && level > 0)
|
|
27091
|
+
if (state.tag !== null && state.tag !== "?" || duplicate || state.indent !== 2 && level > 0) {
|
|
26740
27092
|
compact = false;
|
|
26741
|
-
|
|
27093
|
+
}
|
|
27094
|
+
if (duplicate && state.usedDuplicates[duplicateIndex]) {
|
|
26742
27095
|
state.dump = "*ref_" + duplicateIndex;
|
|
26743
|
-
else {
|
|
26744
|
-
if (objectOrArray && duplicate && !state.usedDuplicates[duplicateIndex])
|
|
27096
|
+
} else {
|
|
27097
|
+
if (objectOrArray && duplicate && !state.usedDuplicates[duplicateIndex]) {
|
|
26745
27098
|
state.usedDuplicates[duplicateIndex] = true;
|
|
26746
|
-
|
|
27099
|
+
}
|
|
27100
|
+
if (type2 === "[object Object]") {
|
|
26747
27101
|
if (block && Object.keys(state.dump).length !== 0) {
|
|
26748
27102
|
writeBlockMapping(state, level, state.dump, compact);
|
|
26749
|
-
if (duplicate)
|
|
27103
|
+
if (duplicate) {
|
|
26750
27104
|
state.dump = "&ref_" + duplicateIndex + state.dump;
|
|
27105
|
+
}
|
|
26751
27106
|
} else {
|
|
26752
27107
|
writeFlowMapping(state, level, state.dump);
|
|
26753
|
-
if (duplicate)
|
|
27108
|
+
if (duplicate) {
|
|
26754
27109
|
state.dump = "&ref_" + duplicateIndex + " " + state.dump;
|
|
27110
|
+
}
|
|
26755
27111
|
}
|
|
26756
|
-
else if (
|
|
27112
|
+
} else if (type2 === "[object Array]") {
|
|
26757
27113
|
if (block && state.dump.length !== 0) {
|
|
26758
|
-
if (state.noArrayIndent && !isblockseq && level > 0)
|
|
27114
|
+
if (state.noArrayIndent && !isblockseq && level > 0) {
|
|
26759
27115
|
writeBlockSequence(state, level - 1, state.dump, compact);
|
|
26760
|
-
else
|
|
27116
|
+
} else {
|
|
26761
27117
|
writeBlockSequence(state, level, state.dump, compact);
|
|
26762
|
-
|
|
27118
|
+
}
|
|
27119
|
+
if (duplicate) {
|
|
26763
27120
|
state.dump = "&ref_" + duplicateIndex + state.dump;
|
|
27121
|
+
}
|
|
26764
27122
|
} else {
|
|
26765
27123
|
writeFlowSequence(state, level, state.dump);
|
|
26766
|
-
if (duplicate)
|
|
27124
|
+
if (duplicate) {
|
|
26767
27125
|
state.dump = "&ref_" + duplicateIndex + " " + state.dump;
|
|
27126
|
+
}
|
|
26768
27127
|
}
|
|
26769
|
-
else if (
|
|
26770
|
-
if (state.tag !== "?")
|
|
27128
|
+
} else if (type2 === "[object String]") {
|
|
27129
|
+
if (state.tag !== "?") {
|
|
26771
27130
|
writeScalar(state, state.dump, level, iskey, inblock);
|
|
26772
|
-
|
|
27131
|
+
}
|
|
27132
|
+
} else if (type2 === "[object Undefined]") {
|
|
26773
27133
|
return false;
|
|
26774
|
-
else {
|
|
27134
|
+
} else {
|
|
26775
27135
|
if (state.skipInvalid)
|
|
26776
27136
|
return false;
|
|
26777
|
-
throw new
|
|
27137
|
+
throw new YAMLException2("unacceptable kind of an object to dump " + type2);
|
|
26778
27138
|
}
|
|
26779
27139
|
if (state.tag !== null && state.tag !== "?") {
|
|
26780
27140
|
let tagStr = encodeURI(state.tag[0] === "!" ? state.tag.slice(1) : state.tag).replace(/!/g, "%21");
|
|
26781
|
-
if (state.tag[0] === "!")
|
|
27141
|
+
if (state.tag[0] === "!") {
|
|
26782
27142
|
tagStr = "!" + tagStr;
|
|
26783
|
-
else if (tagStr.slice(0, 18) === "tag:yaml.org,2002:")
|
|
27143
|
+
} else if (tagStr.slice(0, 18) === "tag:yaml.org,2002:") {
|
|
26784
27144
|
tagStr = "!!" + tagStr.slice(18);
|
|
26785
|
-
else
|
|
27145
|
+
} else {
|
|
26786
27146
|
tagStr = "!<" + tagStr + ">";
|
|
27147
|
+
}
|
|
26787
27148
|
state.dump = tagStr + " " + state.dump;
|
|
26788
27149
|
}
|
|
26789
27150
|
}
|
|
@@ -26794,83 +27155,110 @@ var require_dumper = /* @__PURE__ */ __commonJSMin((exports, module) => {
|
|
|
26794
27155
|
const duplicatesIndexes = [];
|
|
26795
27156
|
inspectNode(object, objects, duplicatesIndexes);
|
|
26796
27157
|
const length = duplicatesIndexes.length;
|
|
26797
|
-
for (let index = 0;index < length; index += 1)
|
|
27158
|
+
for (let index = 0;index < length; index += 1) {
|
|
26798
27159
|
state.duplicates.push(objects[duplicatesIndexes[index]]);
|
|
27160
|
+
}
|
|
26799
27161
|
state.usedDuplicates = new Array(length);
|
|
26800
27162
|
}
|
|
26801
27163
|
function inspectNode(object, objects, duplicatesIndexes) {
|
|
26802
27164
|
if (object !== null && typeof object === "object") {
|
|
26803
27165
|
const index = objects.indexOf(object);
|
|
26804
27166
|
if (index !== -1) {
|
|
26805
|
-
if (duplicatesIndexes.indexOf(index) === -1)
|
|
27167
|
+
if (duplicatesIndexes.indexOf(index) === -1) {
|
|
26806
27168
|
duplicatesIndexes.push(index);
|
|
27169
|
+
}
|
|
26807
27170
|
} else {
|
|
26808
27171
|
objects.push(object);
|
|
26809
|
-
if (Array.isArray(object))
|
|
26810
|
-
for (let i = 0, length = object.length;i < length; i += 1)
|
|
27172
|
+
if (Array.isArray(object)) {
|
|
27173
|
+
for (let i = 0, length = object.length;i < length; i += 1) {
|
|
26811
27174
|
inspectNode(object[i], objects, duplicatesIndexes);
|
|
26812
|
-
|
|
27175
|
+
}
|
|
27176
|
+
} else {
|
|
26813
27177
|
const objectKeyList = Object.keys(object);
|
|
26814
|
-
for (let i = 0, length = objectKeyList.length;i < length; i += 1)
|
|
27178
|
+
for (let i = 0, length = objectKeyList.length;i < length; i += 1) {
|
|
26815
27179
|
inspectNode(object[objectKeyList[i]], objects, duplicatesIndexes);
|
|
27180
|
+
}
|
|
26816
27181
|
}
|
|
26817
27182
|
}
|
|
26818
27183
|
}
|
|
26819
27184
|
}
|
|
26820
|
-
function
|
|
27185
|
+
function dump2(input, options) {
|
|
26821
27186
|
options = options || {};
|
|
26822
27187
|
const state = new State(options);
|
|
26823
27188
|
if (!state.noRefs)
|
|
26824
27189
|
getDuplicateReferences(input, state);
|
|
26825
27190
|
let value = input;
|
|
26826
|
-
if (state.replacer)
|
|
27191
|
+
if (state.replacer) {
|
|
26827
27192
|
value = state.replacer.call({ "": value }, "", value);
|
|
27193
|
+
}
|
|
26828
27194
|
if (writeNode(state, 0, value, true, true))
|
|
26829
27195
|
return state.dump + `
|
|
26830
27196
|
`;
|
|
26831
27197
|
return "";
|
|
26832
27198
|
}
|
|
26833
|
-
|
|
26834
|
-
|
|
26835
|
-
|
|
26836
|
-
|
|
26837
|
-
|
|
27199
|
+
dumper.dump = dump2;
|
|
27200
|
+
return dumper;
|
|
27201
|
+
}
|
|
27202
|
+
var hasRequiredJsYaml;
|
|
27203
|
+
function requireJsYaml() {
|
|
27204
|
+
if (hasRequiredJsYaml)
|
|
27205
|
+
return jsYaml;
|
|
27206
|
+
hasRequiredJsYaml = 1;
|
|
27207
|
+
const loader2 = requireLoader();
|
|
27208
|
+
const dumper2 = requireDumper();
|
|
26838
27209
|
function renamed(from, to) {
|
|
26839
27210
|
return function() {
|
|
26840
27211
|
throw new Error("Function yaml." + from + " is removed in js-yaml 4. Use yaml." + to + " instead, which is now safe by default.");
|
|
26841
27212
|
};
|
|
26842
27213
|
}
|
|
26843
|
-
|
|
26844
|
-
|
|
26845
|
-
|
|
26846
|
-
|
|
26847
|
-
|
|
26848
|
-
|
|
26849
|
-
|
|
26850
|
-
|
|
26851
|
-
|
|
26852
|
-
|
|
26853
|
-
|
|
26854
|
-
binary:
|
|
26855
|
-
float:
|
|
26856
|
-
map:
|
|
27214
|
+
jsYaml.Type = requireType();
|
|
27215
|
+
jsYaml.Schema = requireSchema();
|
|
27216
|
+
jsYaml.FAILSAFE_SCHEMA = requireFailsafe();
|
|
27217
|
+
jsYaml.JSON_SCHEMA = requireJson();
|
|
27218
|
+
jsYaml.CORE_SCHEMA = requireCore();
|
|
27219
|
+
jsYaml.DEFAULT_SCHEMA = require_default();
|
|
27220
|
+
jsYaml.load = loader2.load;
|
|
27221
|
+
jsYaml.loadAll = loader2.loadAll;
|
|
27222
|
+
jsYaml.dump = dumper2.dump;
|
|
27223
|
+
jsYaml.YAMLException = requireException();
|
|
27224
|
+
jsYaml.types = {
|
|
27225
|
+
binary: requireBinary(),
|
|
27226
|
+
float: requireFloat(),
|
|
27227
|
+
map: requireMap(),
|
|
26857
27228
|
null: require_null(),
|
|
26858
|
-
pairs:
|
|
26859
|
-
set:
|
|
26860
|
-
timestamp:
|
|
26861
|
-
bool:
|
|
26862
|
-
int:
|
|
26863
|
-
merge:
|
|
26864
|
-
omap:
|
|
26865
|
-
seq:
|
|
26866
|
-
str:
|
|
27229
|
+
pairs: requirePairs(),
|
|
27230
|
+
set: requireSet(),
|
|
27231
|
+
timestamp: requireTimestamp(),
|
|
27232
|
+
bool: requireBool(),
|
|
27233
|
+
int: requireInt(),
|
|
27234
|
+
merge: requireMerge(),
|
|
27235
|
+
omap: requireOmap(),
|
|
27236
|
+
seq: requireSeq(),
|
|
27237
|
+
str: requireStr()
|
|
26867
27238
|
};
|
|
26868
|
-
|
|
26869
|
-
|
|
26870
|
-
|
|
26871
|
-
|
|
26872
|
-
|
|
26873
|
-
var
|
|
27239
|
+
jsYaml.safeLoad = renamed("safeLoad", "load");
|
|
27240
|
+
jsYaml.safeLoadAll = renamed("safeLoadAll", "loadAll");
|
|
27241
|
+
jsYaml.safeDump = renamed("safeDump", "dump");
|
|
27242
|
+
return jsYaml;
|
|
27243
|
+
}
|
|
27244
|
+
var jsYamlExports = requireJsYaml();
|
|
27245
|
+
var yaml = /* @__PURE__ */ getDefaultExportFromCjs(jsYamlExports);
|
|
27246
|
+
var {
|
|
27247
|
+
Type,
|
|
27248
|
+
Schema,
|
|
27249
|
+
FAILSAFE_SCHEMA,
|
|
27250
|
+
JSON_SCHEMA,
|
|
27251
|
+
CORE_SCHEMA,
|
|
27252
|
+
DEFAULT_SCHEMA,
|
|
27253
|
+
load,
|
|
27254
|
+
loadAll,
|
|
27255
|
+
dump,
|
|
27256
|
+
YAMLException,
|
|
27257
|
+
types,
|
|
27258
|
+
safeLoad,
|
|
27259
|
+
safeLoadAll,
|
|
27260
|
+
safeDump
|
|
27261
|
+
} = yaml;
|
|
26874
27262
|
|
|
26875
27263
|
// ../../common/src/logger.ts
|
|
26876
27264
|
init_src();
|
|
@@ -26947,11 +27335,11 @@ class SimpleLogger {
|
|
|
26947
27335
|
const path3 = this.logFilePath || getGlobalLogFilePath();
|
|
26948
27336
|
if (!path3)
|
|
26949
27337
|
return;
|
|
26950
|
-
const
|
|
27338
|
+
const timestamp2 = new Date().toISOString();
|
|
26951
27339
|
this.pendingWrites = Promise.all([
|
|
26952
27340
|
this.pendingWrites,
|
|
26953
27341
|
this.pendingInit
|
|
26954
|
-
]).then(() => getFileSystem().appendFile(path3, `${
|
|
27342
|
+
]).then(() => getFileSystem().appendFile(path3, `${timestamp2} ${formatted}`).catch(() => {}));
|
|
26955
27343
|
}
|
|
26956
27344
|
debug(message, ...args) {
|
|
26957
27345
|
if (this.level > 0 /* DEBUG */)
|
|
@@ -27067,6 +27455,7 @@ function getLogFilePath() {
|
|
|
27067
27455
|
// ../../common/src/output-format-context.ts
|
|
27068
27456
|
var formatSlot = singleton("OutputFormat");
|
|
27069
27457
|
var formatExplicitSlot = singleton("OutputFormatExplicit");
|
|
27458
|
+
var helpRequestedSlot = singleton("HelpRequested");
|
|
27070
27459
|
var filterSlot = singleton("OutputFilter");
|
|
27071
27460
|
function getOutputFormat() {
|
|
27072
27461
|
return formatSlot.get("json");
|
|
@@ -27344,10 +27733,10 @@ class LoggerTelemetryProvider {
|
|
|
27344
27733
|
success
|
|
27345
27734
|
})));
|
|
27346
27735
|
}
|
|
27347
|
-
async trackDependency(name,
|
|
27736
|
+
async trackDependency(name, type2, duration, success, properties) {
|
|
27348
27737
|
logger.debug(formatMessage("Dependency", name, this.enrich({
|
|
27349
27738
|
...properties,
|
|
27350
|
-
type,
|
|
27739
|
+
type: type2,
|
|
27351
27740
|
duration: `${duration}ms`,
|
|
27352
27741
|
success
|
|
27353
27742
|
})));
|
|
@@ -27505,11 +27894,36 @@ class NodeContextStorage {
|
|
|
27505
27894
|
return this.storage.getStore();
|
|
27506
27895
|
}
|
|
27507
27896
|
}
|
|
27897
|
+
// ../../common/src/telemetry/trace-context.ts
|
|
27898
|
+
var TELEMETRY_TRACEPARENT_ENV = "TRACEPARENT";
|
|
27899
|
+
var TRACEPARENT_PATTERN = /^00-([0-9a-f]{32})-([0-9a-f]{16})-[0-9a-f]{2}$/;
|
|
27900
|
+
function getProcessEnv() {
|
|
27901
|
+
return globalThis.process?.env;
|
|
27902
|
+
}
|
|
27903
|
+
function parseInboundTraceparent(value) {
|
|
27904
|
+
if (!value) {
|
|
27905
|
+
return;
|
|
27906
|
+
}
|
|
27907
|
+
const match = TRACEPARENT_PATTERN.exec(value.trim().toLowerCase());
|
|
27908
|
+
if (!match) {
|
|
27909
|
+
return;
|
|
27910
|
+
}
|
|
27911
|
+
const [, traceId, parentSpanId] = match;
|
|
27912
|
+
if (/^0+$/.test(traceId) || /^0+$/.test(parentSpanId)) {
|
|
27913
|
+
return;
|
|
27914
|
+
}
|
|
27915
|
+
return { traceId, parentSpanId };
|
|
27916
|
+
}
|
|
27917
|
+
function getInboundTraceContext() {
|
|
27918
|
+
return parseInboundTraceparent(getProcessEnv()?.[TELEMETRY_TRACEPARENT_ENV]);
|
|
27919
|
+
}
|
|
27920
|
+
|
|
27508
27921
|
// ../../common/src/telemetry/session-id.ts
|
|
27509
27922
|
var TELEMETRY_SESSION_ID_ENV = "UIPATH_SESSION_ID";
|
|
27510
27923
|
var TELEMETRY_SESSION_ID_PROPERTY = "session_id";
|
|
27511
27924
|
var telemetrySessionIdSlot = singleton("TelemetrySessionId");
|
|
27512
|
-
|
|
27925
|
+
var telemetryOperationIdSlot = singleton("TelemetryOperationId");
|
|
27926
|
+
function getProcessEnv2() {
|
|
27513
27927
|
return globalThis.process?.env;
|
|
27514
27928
|
}
|
|
27515
27929
|
function normalizeSessionId(value) {
|
|
@@ -27520,12 +27934,159 @@ function normalizeSessionId(value) {
|
|
|
27520
27934
|
return trimmed || undefined;
|
|
27521
27935
|
}
|
|
27522
27936
|
function getConfiguredTelemetrySessionId() {
|
|
27523
|
-
return normalizeSessionId(
|
|
27937
|
+
return normalizeSessionId(getProcessEnv2()?.[TELEMETRY_SESSION_ID_ENV]);
|
|
27524
27938
|
}
|
|
27525
27939
|
function resolveTelemetrySessionId(existingSessionId) {
|
|
27526
27940
|
return getConfiguredTelemetrySessionId() ?? normalizeSessionId(existingSessionId);
|
|
27527
27941
|
}
|
|
27942
|
+
function getTelemetryOperationId() {
|
|
27943
|
+
const existing = telemetryOperationIdSlot.get();
|
|
27944
|
+
if (existing) {
|
|
27945
|
+
return existing;
|
|
27946
|
+
}
|
|
27947
|
+
const inboundTraceId = getInboundTraceContext()?.traceId;
|
|
27948
|
+
const generated = inboundTraceId ?? crypto.randomUUID().replaceAll("-", "");
|
|
27949
|
+
telemetryOperationIdSlot.set(generated);
|
|
27950
|
+
return generated;
|
|
27951
|
+
}
|
|
27952
|
+
// ../../common/src/telemetry/pii-redactor.ts
|
|
27953
|
+
var REDACTED = "[REDACTED]";
|
|
27954
|
+
var MAX_VALUE_LENGTH = 200;
|
|
27955
|
+
var SENSITIVE_NAME_TOKENS = new Set([
|
|
27956
|
+
"token",
|
|
27957
|
+
"tokens",
|
|
27958
|
+
"secret",
|
|
27959
|
+
"secrets",
|
|
27960
|
+
"password",
|
|
27961
|
+
"passwords",
|
|
27962
|
+
"pwd",
|
|
27963
|
+
"credential",
|
|
27964
|
+
"credentials",
|
|
27965
|
+
"auth",
|
|
27966
|
+
"authentication",
|
|
27967
|
+
"authorization",
|
|
27968
|
+
"authority",
|
|
27969
|
+
"cert",
|
|
27970
|
+
"certificate",
|
|
27971
|
+
"certificates"
|
|
27972
|
+
]);
|
|
27973
|
+
var SENSITIVE_KEY_PREFIXES = new Set([
|
|
27974
|
+
"api",
|
|
27975
|
+
"access",
|
|
27976
|
+
"client",
|
|
27977
|
+
"private",
|
|
27978
|
+
"public",
|
|
27979
|
+
"signing",
|
|
27980
|
+
"encryption",
|
|
27981
|
+
"session",
|
|
27982
|
+
"master",
|
|
27983
|
+
"shared",
|
|
27984
|
+
"root",
|
|
27985
|
+
"ssh",
|
|
27986
|
+
"rsa",
|
|
27987
|
+
"aes",
|
|
27988
|
+
"hmac",
|
|
27989
|
+
"oauth"
|
|
27990
|
+
]);
|
|
27991
|
+
var UUID_PATTERN = /\b[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}\b/gi;
|
|
27992
|
+
var EMAIL_PATTERN = /\b[^\s@]+@[A-Za-z0-9.-]+\.[A-Za-z]{2,}\b/g;
|
|
27993
|
+
var JWT_PATTERN = /\beyJ[A-Za-z0-9_-]{10,}\.[A-Za-z0-9_-]+\.[A-Za-z0-9_-]+/g;
|
|
27994
|
+
var LONG_TOKEN_PATTERN = /\b[A-Za-z0-9_-]{40,}\b/g;
|
|
27995
|
+
var USER_HOME_PATTERN = /([/\\])(Users|home)([/\\])([^/\\]+)/gi;
|
|
27996
|
+
var URL_PATTERN = /\bhttps?:\/\/[^\s,;]+/gi;
|
|
27997
|
+
var URL_TRAILING_PUNCT = /[.,;:!?)\]}>'"]+$/;
|
|
27998
|
+
function shortHash(input) {
|
|
27999
|
+
let hash = 2166136261;
|
|
28000
|
+
for (let i = 0;i < input.length; i++) {
|
|
28001
|
+
hash ^= input.charCodeAt(i);
|
|
28002
|
+
hash = Math.imul(hash, 16777619);
|
|
28003
|
+
}
|
|
28004
|
+
return (hash >>> 0).toString(16).padStart(8, "0");
|
|
28005
|
+
}
|
|
28006
|
+
function redactUrl(raw) {
|
|
28007
|
+
try {
|
|
28008
|
+
const url = new URL(raw);
|
|
28009
|
+
return `${url.protocol}//${url.host}`;
|
|
28010
|
+
} catch {
|
|
28011
|
+
return `url#${shortHash(raw)}`;
|
|
28012
|
+
}
|
|
28013
|
+
}
|
|
28014
|
+
function redactValueDetectors(value) {
|
|
28015
|
+
let out = value;
|
|
28016
|
+
out = out.replace(JWT_PATTERN, () => REDACTED);
|
|
28017
|
+
out = out.replace(URL_PATTERN, (match) => {
|
|
28018
|
+
const trailing = match.match(URL_TRAILING_PUNCT)?.[0] ?? "";
|
|
28019
|
+
const core2 = trailing ? match.slice(0, -trailing.length) : match;
|
|
28020
|
+
return `${redactUrl(core2)}${trailing}`;
|
|
28021
|
+
});
|
|
28022
|
+
out = out.replace(USER_HOME_PATTERN, (_match, sep1, folder, sep2) => `${sep1}${folder}${sep2}<user>`);
|
|
28023
|
+
out = out.replace(EMAIL_PATTERN, (match) => `email#${shortHash(match)}`);
|
|
28024
|
+
out = out.replace(UUID_PATTERN, (match) => `uuid#${shortHash(match)}`);
|
|
28025
|
+
out = out.replace(LONG_TOKEN_PATTERN, () => REDACTED);
|
|
28026
|
+
if (out.length > MAX_VALUE_LENGTH) {
|
|
28027
|
+
out = `${out.slice(0, MAX_VALUE_LENGTH)}…`;
|
|
28028
|
+
}
|
|
28029
|
+
return out;
|
|
28030
|
+
}
|
|
28031
|
+
function redactValue(value) {
|
|
28032
|
+
return redactValueDetectors(value);
|
|
28033
|
+
}
|
|
28034
|
+
function redactError(error) {
|
|
28035
|
+
const safe = new Error(redactValueDetectors(error.message ?? ""));
|
|
28036
|
+
safe.name = error.name;
|
|
28037
|
+
safe.stack = typeof error.stack === "string" ? redactValueDetectors(error.stack) : undefined;
|
|
28038
|
+
return safe;
|
|
28039
|
+
}
|
|
28040
|
+
function nameTokens(name) {
|
|
28041
|
+
return name.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/([A-Z]+)([A-Z][a-z])/g, "$1 $2").split(/[\s._-]+/).map((t) => t.toLowerCase()).filter(Boolean);
|
|
28042
|
+
}
|
|
28043
|
+
function isSensitiveName(name) {
|
|
28044
|
+
const tokens = nameTokens(name);
|
|
28045
|
+
for (let i = 0;i < tokens.length; i++) {
|
|
28046
|
+
const token = tokens[i];
|
|
28047
|
+
if (SENSITIVE_NAME_TOKENS.has(token)) {
|
|
28048
|
+
return true;
|
|
28049
|
+
}
|
|
28050
|
+
if (token === "key" || token === "keys") {
|
|
28051
|
+
const prev = tokens[i - 1];
|
|
28052
|
+
if (prev && SENSITIVE_KEY_PREFIXES.has(prev)) {
|
|
28053
|
+
return true;
|
|
28054
|
+
}
|
|
28055
|
+
}
|
|
28056
|
+
}
|
|
28057
|
+
return false;
|
|
28058
|
+
}
|
|
28059
|
+
function redactProperty(name, value) {
|
|
28060
|
+
if (value === undefined || value === null) {
|
|
28061
|
+
return;
|
|
28062
|
+
}
|
|
28063
|
+
if (isSensitiveName(name)) {
|
|
28064
|
+
return REDACTED;
|
|
28065
|
+
}
|
|
28066
|
+
if (typeof value === "boolean" || typeof value === "number") {
|
|
28067
|
+
return value;
|
|
28068
|
+
}
|
|
28069
|
+
if (typeof value !== "string") {
|
|
28070
|
+
return "[OBJECT]";
|
|
28071
|
+
}
|
|
28072
|
+
return redactValueDetectors(value);
|
|
28073
|
+
}
|
|
28074
|
+
function redactProperties(properties) {
|
|
28075
|
+
const out = {};
|
|
28076
|
+
for (const [name, value] of Object.entries(properties)) {
|
|
28077
|
+
const redacted = redactProperty(name, value);
|
|
28078
|
+
if (redacted !== undefined) {
|
|
28079
|
+
out[name] = redacted;
|
|
28080
|
+
}
|
|
28081
|
+
}
|
|
28082
|
+
return out;
|
|
28083
|
+
}
|
|
28084
|
+
|
|
27528
28085
|
// ../../common/src/telemetry/telemetry-service.ts
|
|
28086
|
+
var TELEMETRY_OPERATION_ID_PROPERTY = "uip.trace.operation_id";
|
|
28087
|
+
var TELEMETRY_PARENT_ID_PROPERTY = "uip.trace.parent_id";
|
|
28088
|
+
var TELEMETRY_SPAN_ID_PROPERTY = "uip.trace.span_id";
|
|
28089
|
+
|
|
27529
28090
|
class TelemetryService {
|
|
27530
28091
|
telemetryProvider;
|
|
27531
28092
|
contextStorage;
|
|
@@ -27552,11 +28113,15 @@ class TelemetryService {
|
|
|
27552
28113
|
trackException(error, properties) {
|
|
27553
28114
|
const context = this.getCurrentContext();
|
|
27554
28115
|
const enrichedProperties = this.enrichPropertiesWithContext(properties, context);
|
|
27555
|
-
this.telemetryProvider.trackException(error, enrichedProperties);
|
|
28116
|
+
this.telemetryProvider.trackException(redactError(error), enrichedProperties);
|
|
27556
28117
|
}
|
|
27557
28118
|
async trackRequest(name, fn, properties) {
|
|
28119
|
+
const parentContext = this.getCurrentContext();
|
|
28120
|
+
const operationId = parentContext?.operationId ?? this.operationId ?? getTelemetryOperationId();
|
|
28121
|
+
const parentId = parentContext ? parentContext.id : this.inboundParentIdFor(operationId);
|
|
27558
28122
|
const context = {
|
|
27559
|
-
operationId
|
|
28123
|
+
operationId,
|
|
28124
|
+
...parentId !== undefined ? { parentId } : {},
|
|
27560
28125
|
id: this.generateId()
|
|
27561
28126
|
};
|
|
27562
28127
|
const startTime = performance.now();
|
|
@@ -27574,7 +28139,46 @@ class TelemetryService {
|
|
|
27574
28139
|
throw error;
|
|
27575
28140
|
}
|
|
27576
28141
|
}
|
|
27577
|
-
|
|
28142
|
+
trackRequestResult(name, durationMs, success, properties, context) {
|
|
28143
|
+
const requestContext = context ?? {
|
|
28144
|
+
operationId: this.operationId ?? getTelemetryOperationId(),
|
|
28145
|
+
id: this.generateId()
|
|
28146
|
+
};
|
|
28147
|
+
const enrichedProperties = this.enrichPropertiesWithContext(properties, requestContext);
|
|
28148
|
+
this.telemetryProvider.trackRequest(name, durationMs, success, enrichedProperties);
|
|
28149
|
+
}
|
|
28150
|
+
createRequestContext() {
|
|
28151
|
+
const operationId = this.operationId ?? getTelemetryOperationId();
|
|
28152
|
+
const parentId = this.inboundParentIdFor(operationId);
|
|
28153
|
+
return {
|
|
28154
|
+
operationId,
|
|
28155
|
+
...parentId !== undefined ? { parentId } : {},
|
|
28156
|
+
id: this.generateId()
|
|
28157
|
+
};
|
|
28158
|
+
}
|
|
28159
|
+
inboundParentIdFor(operationId) {
|
|
28160
|
+
const inbound = getInboundTraceContext();
|
|
28161
|
+
return inbound && inbound.traceId === operationId ? inbound.parentSpanId : undefined;
|
|
28162
|
+
}
|
|
28163
|
+
runWithContext(context, fn) {
|
|
28164
|
+
return this.contextStorage.run(context, fn);
|
|
28165
|
+
}
|
|
28166
|
+
createDependencyContext() {
|
|
28167
|
+
const parentContext = this.getCurrentContext();
|
|
28168
|
+
if (!parentContext) {
|
|
28169
|
+
return;
|
|
28170
|
+
}
|
|
28171
|
+
return {
|
|
28172
|
+
operationId: parentContext.operationId,
|
|
28173
|
+
parentId: parentContext.id,
|
|
28174
|
+
id: this.generateId()
|
|
28175
|
+
};
|
|
28176
|
+
}
|
|
28177
|
+
trackDependencyResult(name, type2, durationMs, success, properties, context, resultCode) {
|
|
28178
|
+
const enrichedProperties = this.enrichPropertiesWithContext(properties, context);
|
|
28179
|
+
this.telemetryProvider.trackDependency(redactValue(name), type2, durationMs, success, enrichedProperties, resultCode);
|
|
28180
|
+
}
|
|
28181
|
+
async trackDependencyOperation(name, type2, fn, properties) {
|
|
27578
28182
|
const parentContext = this.getCurrentContext();
|
|
27579
28183
|
if (!parentContext) {
|
|
27580
28184
|
throw new Error("trackDependencyOperation must be called within a trackRequest block.");
|
|
@@ -27589,13 +28193,13 @@ class TelemetryService {
|
|
|
27589
28193
|
const result = await this.contextStorage.run(childContext, fn);
|
|
27590
28194
|
const durationMs = performance.now() - startTime;
|
|
27591
28195
|
const enrichedProperties = this.enrichPropertiesWithContext(properties, childContext);
|
|
27592
|
-
await this.telemetryProvider.trackDependency(name,
|
|
28196
|
+
await this.telemetryProvider.trackDependency(name, type2, durationMs, true, enrichedProperties);
|
|
27593
28197
|
return result;
|
|
27594
28198
|
} catch (error) {
|
|
27595
28199
|
const durationMs = performance.now() - startTime;
|
|
27596
28200
|
const err = error instanceof Error ? error : new Error(String(error));
|
|
27597
28201
|
const enrichedProperties = this.enrichPropertiesWithContext({ ...properties, errorMessage: err.message }, childContext);
|
|
27598
|
-
await this.telemetryProvider.trackDependency(name,
|
|
28202
|
+
await this.telemetryProvider.trackDependency(name, type2, durationMs, false, enrichedProperties);
|
|
27599
28203
|
throw error;
|
|
27600
28204
|
}
|
|
27601
28205
|
}
|
|
@@ -27610,8 +28214,12 @@ class TelemetryService {
|
|
|
27610
28214
|
...getExecutionContextTelemetryProperties(),
|
|
27611
28215
|
...globalProperties,
|
|
27612
28216
|
...this.defaultProperties,
|
|
27613
|
-
...properties,
|
|
27614
|
-
...context
|
|
28217
|
+
...redactProperties(properties ?? {}),
|
|
28218
|
+
...context ? {
|
|
28219
|
+
[TELEMETRY_OPERATION_ID_PROPERTY]: context.operationId,
|
|
28220
|
+
...context.parentId !== undefined ? { [TELEMETRY_PARENT_ID_PROPERTY]: context.parentId } : {},
|
|
28221
|
+
[TELEMETRY_SPAN_ID_PROPERTY]: context.id
|
|
28222
|
+
} : {}
|
|
27615
28223
|
};
|
|
27616
28224
|
if (sessionId === undefined) {
|
|
27617
28225
|
delete enriched[TELEMETRY_SESSION_ID_PROPERTY];
|
|
@@ -27621,7 +28229,16 @@ class TelemetryService {
|
|
|
27621
28229
|
return enriched;
|
|
27622
28230
|
}
|
|
27623
28231
|
generateId() {
|
|
27624
|
-
|
|
28232
|
+
const bytes = new Uint8Array(8);
|
|
28233
|
+
let hex = "";
|
|
28234
|
+
do {
|
|
28235
|
+
crypto.getRandomValues(bytes);
|
|
28236
|
+
hex = "";
|
|
28237
|
+
for (const byte of bytes) {
|
|
28238
|
+
hex += byte.toString(16).padStart(2, "0");
|
|
28239
|
+
}
|
|
28240
|
+
} while (/^0+$/.test(hex));
|
|
28241
|
+
return hex;
|
|
27625
28242
|
}
|
|
27626
28243
|
}
|
|
27627
28244
|
// ../../common/src/telemetry/node-appinsights-telemetry-provider.ts
|
|
@@ -27802,8 +28419,8 @@ function printOutput(data, format = "json", logFn, asciiSafe = false) {
|
|
|
27802
28419
|
}
|
|
27803
28420
|
switch (format) {
|
|
27804
28421
|
case "json": {
|
|
27805
|
-
const
|
|
27806
|
-
logFn(asciiSafe ? escapeNonAscii(
|
|
28422
|
+
const json2 = JSON.stringify(data, null, 2);
|
|
28423
|
+
logFn(asciiSafe ? escapeNonAscii(json2) : json2);
|
|
27807
28424
|
break;
|
|
27808
28425
|
}
|
|
27809
28426
|
case "yaml":
|
|
@@ -28128,6 +28745,9 @@ var OutputFormatter;
|
|
|
28128
28745
|
if (opts?.warning) {
|
|
28129
28746
|
data.Warning = opts.warning;
|
|
28130
28747
|
}
|
|
28748
|
+
if (opts?.pagination) {
|
|
28749
|
+
data.Pagination = opts.pagination;
|
|
28750
|
+
}
|
|
28131
28751
|
success(data);
|
|
28132
28752
|
}
|
|
28133
28753
|
OutputFormatter.emitList = emitList;
|
|
@@ -28136,8 +28756,8 @@ var OutputFormatter;
|
|
|
28136
28756
|
const sink = getOutputSink();
|
|
28137
28757
|
const normalized = toPascalCaseData(data);
|
|
28138
28758
|
if (format === "json") {
|
|
28139
|
-
const
|
|
28140
|
-
const safe = needsAsciiSafeJson(sink) ? escapeNonAscii(
|
|
28759
|
+
const json2 = JSON.stringify(normalized);
|
|
28760
|
+
const safe = needsAsciiSafeJson(sink) ? escapeNonAscii(json2) : json2;
|
|
28141
28761
|
sink.writeErr(`${safe}
|
|
28142
28762
|
`);
|
|
28143
28763
|
} else {
|
|
@@ -28323,134 +28943,11 @@ function buildCommandTelemetryAttribution(commandPath, skillSource) {
|
|
|
28323
28943
|
};
|
|
28324
28944
|
}
|
|
28325
28945
|
|
|
28326
|
-
// ../../common/src/telemetry/pii-redactor.ts
|
|
28327
|
-
var REDACTED = "[REDACTED]";
|
|
28328
|
-
var MAX_VALUE_LENGTH = 200;
|
|
28329
|
-
var SENSITIVE_NAME_TOKENS = new Set([
|
|
28330
|
-
"token",
|
|
28331
|
-
"tokens",
|
|
28332
|
-
"secret",
|
|
28333
|
-
"secrets",
|
|
28334
|
-
"password",
|
|
28335
|
-
"passwords",
|
|
28336
|
-
"pwd",
|
|
28337
|
-
"credential",
|
|
28338
|
-
"credentials",
|
|
28339
|
-
"auth",
|
|
28340
|
-
"authentication",
|
|
28341
|
-
"authorization",
|
|
28342
|
-
"authority",
|
|
28343
|
-
"cert",
|
|
28344
|
-
"certificate",
|
|
28345
|
-
"certificates"
|
|
28346
|
-
]);
|
|
28347
|
-
var SENSITIVE_KEY_PREFIXES = new Set([
|
|
28348
|
-
"api",
|
|
28349
|
-
"access",
|
|
28350
|
-
"client",
|
|
28351
|
-
"private",
|
|
28352
|
-
"public",
|
|
28353
|
-
"signing",
|
|
28354
|
-
"encryption",
|
|
28355
|
-
"session",
|
|
28356
|
-
"master",
|
|
28357
|
-
"shared",
|
|
28358
|
-
"root",
|
|
28359
|
-
"ssh",
|
|
28360
|
-
"rsa",
|
|
28361
|
-
"aes",
|
|
28362
|
-
"hmac",
|
|
28363
|
-
"oauth"
|
|
28364
|
-
]);
|
|
28365
|
-
var UUID_PATTERN = /\b[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}\b/gi;
|
|
28366
|
-
var EMAIL_PATTERN = /\b[^\s@]+@[A-Za-z0-9.-]+\.[A-Za-z]{2,}\b/g;
|
|
28367
|
-
var JWT_PATTERN = /\beyJ[A-Za-z0-9_-]{10,}\.[A-Za-z0-9_-]+\.[A-Za-z0-9_-]+/g;
|
|
28368
|
-
var LONG_TOKEN_PATTERN = /\b[A-Za-z0-9_-]{40,}\b/g;
|
|
28369
|
-
var USER_HOME_PATTERN = /([/\\])(Users|home)([/\\])([^/\\]+)/gi;
|
|
28370
|
-
var URL_PATTERN = /\bhttps?:\/\/[^\s,;]+/gi;
|
|
28371
|
-
var URL_TRAILING_PUNCT = /[.,;:!?)\]}>'"]+$/;
|
|
28372
|
-
function shortHash(input) {
|
|
28373
|
-
let hash = 2166136261;
|
|
28374
|
-
for (let i = 0;i < input.length; i++) {
|
|
28375
|
-
hash ^= input.charCodeAt(i);
|
|
28376
|
-
hash = Math.imul(hash, 16777619);
|
|
28377
|
-
}
|
|
28378
|
-
return (hash >>> 0).toString(16).padStart(8, "0");
|
|
28379
|
-
}
|
|
28380
|
-
function redactUrl(raw) {
|
|
28381
|
-
try {
|
|
28382
|
-
const url = new URL(raw);
|
|
28383
|
-
return `${url.protocol}//${url.host}`;
|
|
28384
|
-
} catch {
|
|
28385
|
-
return `url#${shortHash(raw)}`;
|
|
28386
|
-
}
|
|
28387
|
-
}
|
|
28388
|
-
function redactValueDetectors(value) {
|
|
28389
|
-
let out = value;
|
|
28390
|
-
out = out.replace(JWT_PATTERN, () => REDACTED);
|
|
28391
|
-
out = out.replace(URL_PATTERN, (match) => {
|
|
28392
|
-
const trailing = match.match(URL_TRAILING_PUNCT)?.[0] ?? "";
|
|
28393
|
-
const core = trailing ? match.slice(0, -trailing.length) : match;
|
|
28394
|
-
return `${redactUrl(core)}${trailing}`;
|
|
28395
|
-
});
|
|
28396
|
-
out = out.replace(USER_HOME_PATTERN, (_match, sep1, folder, sep2) => `${sep1}${folder}${sep2}<user>`);
|
|
28397
|
-
out = out.replace(EMAIL_PATTERN, (match) => `email#${shortHash(match)}`);
|
|
28398
|
-
out = out.replace(UUID_PATTERN, (match) => `uuid#${shortHash(match)}`);
|
|
28399
|
-
out = out.replace(LONG_TOKEN_PATTERN, () => REDACTED);
|
|
28400
|
-
if (out.length > MAX_VALUE_LENGTH) {
|
|
28401
|
-
out = `${out.slice(0, MAX_VALUE_LENGTH)}…`;
|
|
28402
|
-
}
|
|
28403
|
-
return out;
|
|
28404
|
-
}
|
|
28405
|
-
function nameTokens(name) {
|
|
28406
|
-
return name.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/([A-Z]+)([A-Z][a-z])/g, "$1 $2").split(/[\s_-]+/).map((t) => t.toLowerCase()).filter(Boolean);
|
|
28407
|
-
}
|
|
28408
|
-
function isSensitiveName(name) {
|
|
28409
|
-
const tokens = nameTokens(name);
|
|
28410
|
-
for (let i = 0;i < tokens.length; i++) {
|
|
28411
|
-
const token = tokens[i];
|
|
28412
|
-
if (SENSITIVE_NAME_TOKENS.has(token)) {
|
|
28413
|
-
return true;
|
|
28414
|
-
}
|
|
28415
|
-
if (token === "key" || token === "keys") {
|
|
28416
|
-
const prev = tokens[i - 1];
|
|
28417
|
-
if (prev && SENSITIVE_KEY_PREFIXES.has(prev)) {
|
|
28418
|
-
return true;
|
|
28419
|
-
}
|
|
28420
|
-
}
|
|
28421
|
-
}
|
|
28422
|
-
return false;
|
|
28423
|
-
}
|
|
28424
|
-
function redactProperty(name, value) {
|
|
28425
|
-
if (value === undefined || value === null) {
|
|
28426
|
-
return;
|
|
28427
|
-
}
|
|
28428
|
-
if (isSensitiveName(name)) {
|
|
28429
|
-
return REDACTED;
|
|
28430
|
-
}
|
|
28431
|
-
if (typeof value === "boolean" || typeof value === "number") {
|
|
28432
|
-
return value;
|
|
28433
|
-
}
|
|
28434
|
-
if (typeof value !== "string") {
|
|
28435
|
-
return "[OBJECT]";
|
|
28436
|
-
}
|
|
28437
|
-
return redactValueDetectors(value);
|
|
28438
|
-
}
|
|
28439
|
-
function redactProperties(properties) {
|
|
28440
|
-
const out = {};
|
|
28441
|
-
for (const [name, value] of Object.entries(properties)) {
|
|
28442
|
-
const redacted = redactProperty(name, value);
|
|
28443
|
-
if (redacted !== undefined) {
|
|
28444
|
-
out[name] = redacted;
|
|
28445
|
-
}
|
|
28446
|
-
}
|
|
28447
|
-
return out;
|
|
28448
|
-
}
|
|
28449
|
-
|
|
28450
28946
|
// ../../common/src/trackedAction.ts
|
|
28451
28947
|
var pollSignalSlot = singleton("PollSignal");
|
|
28452
28948
|
var cliErrorCodeValues = new Set(CLI_ERROR_CODES);
|
|
28453
28949
|
var retryHintValues = new Set(RETRY_HINTS);
|
|
28950
|
+
var TELEMETRY_COMMAND_ARG_PREFIX = "uip.cmd.arg.";
|
|
28454
28951
|
var processContext = {
|
|
28455
28952
|
exit: (code) => {
|
|
28456
28953
|
process.exitCode = code;
|
|
@@ -28461,22 +28958,18 @@ var processContext = {
|
|
|
28461
28958
|
};
|
|
28462
28959
|
function extractCommandParams(cmd) {
|
|
28463
28960
|
const params = {};
|
|
28961
|
+
const add2 = (name, value) => {
|
|
28962
|
+
if (name && value !== undefined) {
|
|
28963
|
+
params[`${TELEMETRY_COMMAND_ARG_PREFIX}${name}`] = value;
|
|
28964
|
+
}
|
|
28965
|
+
};
|
|
28464
28966
|
const registered = cmd.registeredArguments ?? [];
|
|
28465
28967
|
const processed = cmd.processedArgs ?? [];
|
|
28466
28968
|
for (let i = 0;i < registered.length; i++) {
|
|
28467
|
-
|
|
28468
|
-
if (value === undefined) {
|
|
28469
|
-
continue;
|
|
28470
|
-
}
|
|
28471
|
-
const name = registered[i].name();
|
|
28472
|
-
if (name) {
|
|
28473
|
-
params[name] = value;
|
|
28474
|
-
}
|
|
28969
|
+
add2(registered[i].name(), processed[i]);
|
|
28475
28970
|
}
|
|
28476
28971
|
for (const [key, value] of Object.entries(cmd.opts())) {
|
|
28477
|
-
|
|
28478
|
-
params[key] = value;
|
|
28479
|
-
}
|
|
28972
|
+
add2(key, value);
|
|
28480
28973
|
}
|
|
28481
28974
|
return params;
|
|
28482
28975
|
}
|
|
@@ -28519,11 +29012,12 @@ Command2.prototype.trackedAction = function(context, fn, properties) {
|
|
|
28519
29012
|
return this.action(async (...args) => {
|
|
28520
29013
|
const telemetryName = deriveCommandPath(command);
|
|
28521
29014
|
const props = typeof properties === "function" ? properties(...args) : properties;
|
|
29015
|
+
const requestContext = telemetry.createRequestContext();
|
|
28522
29016
|
const startTime = performance.now();
|
|
28523
29017
|
let errorMessage2;
|
|
28524
29018
|
let fallbackExitCode = EXIT_CODES.Success;
|
|
28525
29019
|
clearRecordedCommandFailureTelemetry();
|
|
28526
|
-
const [error] = await catchError2(fn(...args));
|
|
29020
|
+
const [error] = await catchError2(telemetry.runWithContext(requestContext, () => fn(...args)));
|
|
28527
29021
|
if (error) {
|
|
28528
29022
|
errorMessage2 = error instanceof Error ? error.message : String(error);
|
|
28529
29023
|
logger.debug(`[trackedAction] ${telemetryName} failed: ${errorMessage2}`);
|
|
@@ -28559,16 +29053,21 @@ Command2.prototype.trackedAction = function(context, fn, properties) {
|
|
|
28559
29053
|
recordedFailure,
|
|
28560
29054
|
pollSignal: context.pollSignal
|
|
28561
29055
|
});
|
|
28562
|
-
|
|
28563
|
-
|
|
29056
|
+
const commandParams = extractCommandParams(command);
|
|
29057
|
+
if (props) {
|
|
29058
|
+
for (const key of Object.keys(props)) {
|
|
29059
|
+
delete commandParams[`${TELEMETRY_COMMAND_ARG_PREFIX}${key}`];
|
|
29060
|
+
}
|
|
29061
|
+
}
|
|
29062
|
+
const baseProperties = redactProperties({
|
|
29063
|
+
...commandParams,
|
|
28564
29064
|
...props,
|
|
28565
29065
|
...buildCommandTelemetryAttribution(telemetryName, process.env.UIPATH_SKILL),
|
|
28566
29066
|
command: "true",
|
|
28567
|
-
duration: String(durationMs),
|
|
28568
|
-
success: String(success),
|
|
28569
29067
|
...terminalTelemetry,
|
|
28570
29068
|
...errorMessage2 ? { errorMessage: errorMessage2 } : {}
|
|
28571
|
-
})
|
|
29069
|
+
});
|
|
29070
|
+
telemetry.trackRequestResult(telemetryName, durationMs, success, baseProperties, requestContext);
|
|
28572
29071
|
});
|
|
28573
29072
|
};
|
|
28574
29073
|
// ../../common/src/console-guard.ts
|
|
@@ -28578,6 +29077,7 @@ var savedOriginalsSlot = singleton("ConsoleGuardOriginals");
|
|
|
28578
29077
|
var DEFAULT_AUTH_TIMEOUT_MS2 = 5 * 60 * 1000;
|
|
28579
29078
|
// ../../common/src/interactivity-context.ts
|
|
28580
29079
|
var modeSlot = singleton("InteractivityMode");
|
|
29080
|
+
var interactiveFlagSlot = singleton("InteractiveFlag");
|
|
28581
29081
|
// ../../common/src/option-aliases.ts
|
|
28582
29082
|
import { Option } from "commander";
|
|
28583
29083
|
// ../../common/src/option-validators.ts
|
|
@@ -28642,7 +29142,6 @@ var shippedKeysSlot = singleton("ShipSucceededDedupeKeys");
|
|
|
28642
29142
|
// ../../common/src/tool-provider.ts
|
|
28643
29143
|
var factorySlot = singleton("PackagerFactoryProvider");
|
|
28644
29144
|
// src/commands/_shared.ts
|
|
28645
|
-
import { isIPv4 } from "node:net";
|
|
28646
29145
|
init_src();
|
|
28647
29146
|
var LOGIN_INSTRUCTIONS = "Ensure you are logged in with 'uip login' and have access to the Access Policy Management service.";
|
|
28648
29147
|
var NON_NEGATIVE_INTEGER_RE = /^\d+$/;
|
|
@@ -28743,6 +29242,11 @@ async function fetchCurrentIp(loginValidity) {
|
|
|
28743
29242
|
const ip = typeof candidate === "string" ? candidate : undefined;
|
|
28744
29243
|
return { body, ip };
|
|
28745
29244
|
}
|
|
29245
|
+
var IPV4_SEGMENT = "(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9]?[0-9])";
|
|
29246
|
+
var IPV4_REGEX = new RegExp(`^(?:${IPV4_SEGMENT}\\.){3}${IPV4_SEGMENT}$`);
|
|
29247
|
+
function isIPv4(value) {
|
|
29248
|
+
return typeof value === "string" && IPV4_REGEX.test(value);
|
|
29249
|
+
}
|
|
28746
29250
|
function ipInCidr(ip, cidr) {
|
|
28747
29251
|
if (!isIPv4(ip))
|
|
28748
29252
|
return false;
|
|
@@ -29781,4 +30285,4 @@ export {
|
|
|
29781
30285
|
metadata
|
|
29782
30286
|
};
|
|
29783
30287
|
|
|
29784
|
-
//# debugId=
|
|
30288
|
+
//# debugId=1130589CB7AFD95364756E2164756E21
|