diff --git a/dist/index.js b/dist/index.js index 457f3fb..58194a1 100644 --- a/dist/index.js +++ b/dist/index.js @@ -523,7 +523,7 @@ exports.CacheService = exports.GetCacheEntryDownloadURLResponse = exports.GetCac // @generated by protobuf-ts 2.9.1 with parameter long_type_string,client_none,generate_dependencies // @generated from protobuf file "results/api/v1/cache.proto" (package "github.actions.results.api.v1", syntax proto3) // tslint:disable -const runtime_rpc_1 = __nccwpck_require__(64610); +const runtime_rpc_1 = __nccwpck_require__(42229); const runtime_1 = __nccwpck_require__(66765); const runtime_2 = __nccwpck_require__(66765); const runtime_3 = __nccwpck_require__(66765); @@ -7820,7 +7820,7 @@ exports.DuplexStreamingCall = DuplexStreamingCall; /***/ }), -/***/ 64610: +/***/ 42229: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -9302,7 +9302,7 @@ exports.BinaryReader = BinaryReader; /***/ }), -/***/ 37954: +/***/ 15573: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -9945,7 +9945,7 @@ var binary_reader_1 = __nccwpck_require__(68386); Object.defineProperty(exports, "BinaryReader", ({ enumerable: true, get: function () { return binary_reader_1.BinaryReader; } })); Object.defineProperty(exports, "binaryReadOptions", ({ enumerable: true, get: function () { return binary_reader_1.binaryReadOptions; } })); // Standard IBinaryWriter implementation -var binary_writer_1 = __nccwpck_require__(37954); +var binary_writer_1 = __nccwpck_require__(15573); Object.defineProperty(exports, "BinaryWriter", ({ enumerable: true, get: function () { return binary_writer_1.BinaryWriter; } })); Object.defineProperty(exports, "binaryWriteOptions", ({ enumerable: true, get: function () { return binary_writer_1.binaryWriteOptions; } })); // Int64 and UInt64 implementations required for the binary format @@ -10171,7 +10171,7 @@ const reflection_merge_partial_1 = __nccwpck_require__(81713); const json_typings_1 = __nccwpck_require__(11978); const json_format_contract_1 = __nccwpck_require__(57738); const reflection_equals_1 = __nccwpck_require__(29808); -const binary_writer_1 = __nccwpck_require__(37954); +const binary_writer_1 = __nccwpck_require__(15573); const binary_reader_1 = __nccwpck_require__(68386); const baseDescriptors = Object.getOwnPropertyDescriptors(Object.getPrototypeOf({})); const messageTypeDescriptor = baseDescriptors[message_type_contract_1.MESSAGE_TYPE] = {}; @@ -44522,7 +44522,7 @@ Object.defineProperty(exports, "AbortError", ({ enumerable: true, get: function /***/ }), -/***/ 25647: +/***/ 28678: /***/ ((__unused_webpack_module, exports) => { @@ -44535,7 +44535,6 @@ exports.AzureKeyCredential = void 0; * the underlying key value. */ class AzureKeyCredential { - _key; /** * The value of the key to be used in authentication */ @@ -44571,7 +44570,7 @@ exports.AzureKeyCredential = AzureKeyCredential; /***/ }), -/***/ 42492: +/***/ 23711: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -44580,14 +44579,12 @@ exports.AzureKeyCredential = AzureKeyCredential; Object.defineProperty(exports, "__esModule", ({ value: true })); exports.AzureNamedKeyCredential = void 0; exports.isNamedKeyCredential = isNamedKeyCredential; -const core_util_1 = __nccwpck_require__(60643); +const core_util_1 = __nccwpck_require__(91276); /** * A static name/key-based credential that supports updating * the underlying name and key values. */ class AzureNamedKeyCredential { - _key; - _name; /** * The value of the key to be used in authentication. */ @@ -44646,7 +44643,7 @@ function isNamedKeyCredential(credential) { /***/ }), -/***/ 29517: +/***/ 60560: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -44655,13 +44652,12 @@ function isNamedKeyCredential(credential) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.AzureSASCredential = void 0; exports.isSASCredential = isSASCredential; -const core_util_1 = __nccwpck_require__(60643); +const core_util_1 = __nccwpck_require__(91276); /** * A static-signature-based credential that supports updating * the underlying signature value. */ class AzureSASCredential { - _signature; /** * The value of the shared access signature to be used in authentication */ @@ -44708,29 +44704,29 @@ function isSASCredential(credential) { /***/ }), -/***/ 10734: +/***/ 46113: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.isTokenCredential = exports.isSASCredential = exports.AzureSASCredential = exports.isNamedKeyCredential = exports.AzureNamedKeyCredential = exports.isKeyCredential = exports.AzureKeyCredential = void 0; -var azureKeyCredential_js_1 = __nccwpck_require__(25647); +var azureKeyCredential_js_1 = __nccwpck_require__(28678); Object.defineProperty(exports, "AzureKeyCredential", ({ enumerable: true, get: function () { return azureKeyCredential_js_1.AzureKeyCredential; } })); -var keyCredential_js_1 = __nccwpck_require__(16480); +var keyCredential_js_1 = __nccwpck_require__(72515); Object.defineProperty(exports, "isKeyCredential", ({ enumerable: true, get: function () { return keyCredential_js_1.isKeyCredential; } })); -var azureNamedKeyCredential_js_1 = __nccwpck_require__(42492); +var azureNamedKeyCredential_js_1 = __nccwpck_require__(23711); Object.defineProperty(exports, "AzureNamedKeyCredential", ({ enumerable: true, get: function () { return azureNamedKeyCredential_js_1.AzureNamedKeyCredential; } })); Object.defineProperty(exports, "isNamedKeyCredential", ({ enumerable: true, get: function () { return azureNamedKeyCredential_js_1.isNamedKeyCredential; } })); -var azureSASCredential_js_1 = __nccwpck_require__(29517); +var azureSASCredential_js_1 = __nccwpck_require__(60560); Object.defineProperty(exports, "AzureSASCredential", ({ enumerable: true, get: function () { return azureSASCredential_js_1.AzureSASCredential; } })); Object.defineProperty(exports, "isSASCredential", ({ enumerable: true, get: function () { return azureSASCredential_js_1.isSASCredential; } })); -var tokenCredential_js_1 = __nccwpck_require__(81574); +var tokenCredential_js_1 = __nccwpck_require__(2545); Object.defineProperty(exports, "isTokenCredential", ({ enumerable: true, get: function () { return tokenCredential_js_1.isTokenCredential; } })); //# sourceMappingURL=index.js.map /***/ }), -/***/ 16480: +/***/ 72515: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -44738,7 +44734,7 @@ Object.defineProperty(exports, "isTokenCredential", ({ enumerable: true, get: fu // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.isKeyCredential = isKeyCredential; -const core_util_1 = __nccwpck_require__(60643); +const core_util_1 = __nccwpck_require__(91276); /** * Tests an object to determine whether it implements KeyCredential. * @@ -44751,7 +44747,7 @@ function isKeyCredential(credential) { /***/ }), -/***/ 81574: +/***/ 2545: /***/ ((__unused_webpack_module, exports) => { @@ -44797,7 +44793,7 @@ function isTokenCredential(credential) { /***/ }), -/***/ 5022: +/***/ 90247: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -44806,8 +44802,8 @@ function isTokenCredential(credential) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.parseCAEChallenge = parseCAEChallenge; exports.authorizeRequestOnClaimChallenge = authorizeRequestOnClaimChallenge; -const log_js_1 = __nccwpck_require__(54006); -const base64_js_1 = __nccwpck_require__(15465); +const log_js_1 = __nccwpck_require__(64341); +const base64_js_1 = __nccwpck_require__(36732); /** * Converts: `Bearer a="b", c="d", Bearer d="e", f="g"`. * Into: `[ { a: 'b', c: 'd' }, { d: 'e', f: 'g' } ]`. @@ -44820,7 +44816,7 @@ function parseCAEChallenge(challenges) { const challengeParts = `${challenge.trim()}, `.split('", ').filter((x) => x); const keyValuePairs = challengeParts.map((keyValue) => (([key, value]) => ({ [key]: value }))(keyValue.trim().split('="'))); // Key-value pairs to plain object: - return keyValuePairs.reduce((a, b) => ({ ...a, ...b }), {}); + return keyValuePairs.reduce((a, b) => (Object.assign(Object.assign({}, a), b)), {}); }); } /** @@ -44853,6 +44849,7 @@ function parseCAEChallenge(challenges) { * ``` */ async function authorizeRequestOnClaimChallenge(onChallengeOptions) { + var _a; const { scopes, response } = onChallengeOptions; const logger = onChallengeOptions.logger || log_js_1.logger; const challenge = response.headers.get("WWW-Authenticate"); @@ -44872,14 +44869,14 @@ async function authorizeRequestOnClaimChallenge(onChallengeOptions) { if (!accessToken) { return false; } - onChallengeOptions.request.headers.set("Authorization", `${accessToken.tokenType ?? "Bearer"} ${accessToken.token}`); + onChallengeOptions.request.headers.set("Authorization", `${(_a = accessToken.tokenType) !== null && _a !== void 0 ? _a : "Bearer"} ${accessToken.token}`); return true; } //# sourceMappingURL=authorizeRequestOnClaimChallenge.js.map /***/ }), -/***/ 64890: +/***/ 62785: /***/ ((__unused_webpack_module, exports) => { @@ -44911,6 +44908,7 @@ function isUuid(text) { * Handling has specific features for storage that departs to the general AAD challenge docs. **/ const authorizeRequestOnTenantChallenge = async (challengeOptions) => { + var _a; const requestOptions = requestToOptions(challengeOptions.request); const challenge = getChallenge(challengeOptions.response); if (challenge) { @@ -44920,14 +44918,11 @@ const authorizeRequestOnTenantChallenge = async (challengeOptions) => { if (!tenantId) { return false; } - const accessToken = await challengeOptions.getAccessToken(challengeScopes, { - ...requestOptions, - tenantId, - }); + const accessToken = await challengeOptions.getAccessToken(challengeScopes, Object.assign(Object.assign({}, requestOptions), { tenantId })); if (!accessToken) { return false; } - challengeOptions.request.headers.set(Constants.HeaderConstants.AUTHORIZATION, `${accessToken.tokenType ?? "Bearer"} ${accessToken.token}`); + challengeOptions.request.headers.set(Constants.HeaderConstants.AUTHORIZATION, `${(_a = accessToken.tokenType) !== null && _a !== void 0 ? _a : "Bearer"} ${accessToken.token}`); return true; } return false; @@ -44987,7 +44982,7 @@ function parseChallenge(challenge) { const challengeParts = `${bearerChallenge.trim()} `.split(" ").filter((x) => x); const keyValuePairs = challengeParts.map((keyValue) => (([key, value]) => ({ [key]: value }))(keyValue.trim().split("="))); // Key-value pairs to plain object: - return keyValuePairs.reduce((a, b) => ({ ...a, ...b }), {}); + return keyValuePairs.reduce((a, b) => (Object.assign(Object.assign({}, a), b)), {}); } /** * Extracts the options form a Pipeline Request for later re-use @@ -45005,7 +45000,7 @@ function requestToOptions(request) { /***/ }), -/***/ 15465: +/***/ 36732: /***/ ((__unused_webpack_module, exports) => { @@ -45053,7 +45048,7 @@ function decodeStringToString(value) { /***/ }), -/***/ 59515: +/***/ 76268: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -45062,10 +45057,10 @@ function decodeStringToString(value) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.deserializationPolicyName = void 0; exports.deserializationPolicy = deserializationPolicy; -const interfaces_js_1 = __nccwpck_require__(5150); -const core_rest_pipeline_1 = __nccwpck_require__(64839); -const serializer_js_1 = __nccwpck_require__(54414); -const operationHelpers_js_1 = __nccwpck_require__(75108); +const interfaces_js_1 = __nccwpck_require__(38839); +const core_rest_pipeline_1 = __nccwpck_require__(54786); +const serializer_js_1 = __nccwpck_require__(25019); +const operationHelpers_js_1 = __nccwpck_require__(93609); const defaultJsonContentTypes = ["application/json", "text/json"]; const defaultXmlContentTypes = ["application/xml", "application/atom+xml"]; /** @@ -45076,15 +45071,16 @@ exports.deserializationPolicyName = "deserializationPolicy"; * This policy handles parsing out responses according to OperationSpecs on the request. */ function deserializationPolicy(options = {}) { - const jsonContentTypes = options.expectedContentTypes?.json ?? defaultJsonContentTypes; - const xmlContentTypes = options.expectedContentTypes?.xml ?? defaultXmlContentTypes; + var _a, _b, _c, _d, _e, _f, _g; + const jsonContentTypes = (_b = (_a = options.expectedContentTypes) === null || _a === void 0 ? void 0 : _a.json) !== null && _b !== void 0 ? _b : defaultJsonContentTypes; + const xmlContentTypes = (_d = (_c = options.expectedContentTypes) === null || _c === void 0 ? void 0 : _c.xml) !== null && _d !== void 0 ? _d : defaultXmlContentTypes; const parseXML = options.parseXML; const serializerOptions = options.serializerOptions; const updatedOptions = { xml: { - rootName: serializerOptions?.xml.rootName ?? "", - includeRoot: serializerOptions?.xml.includeRoot ?? false, - xmlCharKey: serializerOptions?.xml.xmlCharKey ?? interfaces_js_1.XML_CHARKEY, + rootName: (_e = serializerOptions === null || serializerOptions === void 0 ? void 0 : serializerOptions.xml.rootName) !== null && _e !== void 0 ? _e : "", + includeRoot: (_f = serializerOptions === null || serializerOptions === void 0 ? void 0 : serializerOptions.xml.includeRoot) !== null && _f !== void 0 ? _f : false, + xmlCharKey: (_g = serializerOptions === null || serializerOptions === void 0 ? void 0 : serializerOptions.xml.xmlCharKey) !== null && _g !== void 0 ? _g : interfaces_js_1.XML_CHARKEY, }, }; return { @@ -45099,13 +45095,13 @@ function getOperationResponseMap(parsedResponse) { let result; const request = parsedResponse.request; const operationInfo = (0, operationHelpers_js_1.getOperationRequestInfo)(request); - const operationSpec = operationInfo?.operationSpec; + const operationSpec = operationInfo === null || operationInfo === void 0 ? void 0 : operationInfo.operationSpec; if (operationSpec) { - if (!operationInfo?.operationResponseGetter) { + if (!(operationInfo === null || operationInfo === void 0 ? void 0 : operationInfo.operationResponseGetter)) { result = operationSpec.responses[parsedResponse.status]; } else { - result = operationInfo?.operationResponseGetter(operationSpec, parsedResponse); + result = operationInfo === null || operationInfo === void 0 ? void 0 : operationInfo.operationResponseGetter(operationSpec, parsedResponse); } } return result; @@ -45113,7 +45109,7 @@ function getOperationResponseMap(parsedResponse) { function shouldDeserializeResponse(parsedResponse) { const request = parsedResponse.request; const operationInfo = (0, operationHelpers_js_1.getOperationRequestInfo)(request); - const shouldDeserialize = operationInfo?.shouldDeserialize; + const shouldDeserialize = operationInfo === null || operationInfo === void 0 ? void 0 : operationInfo.shouldDeserialize; let result; if (shouldDeserialize === undefined) { result = true; @@ -45132,7 +45128,7 @@ async function deserializeResponseBody(jsonContentTypes, xmlContentTypes, respon return parsedResponse; } const operationInfo = (0, operationHelpers_js_1.getOperationRequestInfo)(parsedResponse.request); - const operationSpec = operationInfo?.operationSpec; + const operationSpec = operationInfo === null || operationInfo === void 0 ? void 0 : operationInfo.operationSpec; if (!operationSpec || !operationSpec.responses) { return parsedResponse; } @@ -45183,6 +45179,7 @@ function isOperationSpecEmpty(operationSpec) { (expectedStatusCodes.length === 1 && expectedStatusCodes[0] === "default")); } function handleErrorResponse(parsedResponse, operationSpec, responseSpec, options) { + var _a, _b, _c, _d, _e; const isSuccessByStatus = 200 <= parsedResponse.status && parsedResponse.status < 300; const isExpectedStatusCode = isOperationSpecEmpty(operationSpec) ? isSuccessByStatus @@ -45197,8 +45194,8 @@ function handleErrorResponse(parsedResponse, operationSpec, responseSpec, option return { error: null, shouldReturnResponse: false }; } } - const errorResponseSpec = responseSpec ?? operationSpec.responses.default; - const initialErrorMessage = parsedResponse.request.streamResponseStatusCodes?.has(parsedResponse.status) + const errorResponseSpec = responseSpec !== null && responseSpec !== void 0 ? responseSpec : operationSpec.responses.default; + const initialErrorMessage = ((_a = parsedResponse.request.streamResponseStatusCodes) === null || _a === void 0 ? void 0 : _a.has(parsedResponse.status)) ? `Unexpected status code: ${parsedResponse.status}` : parsedResponse.bodyAsText; const error = new core_rest_pipeline_1.RestError(initialErrorMessage, { @@ -45210,11 +45207,11 @@ function handleErrorResponse(parsedResponse, operationSpec, responseSpec, option // and the parsed body doesn't look like an error object, // we should fail so we just throw the parsed response if (!errorResponseSpec && - !(parsedResponse.parsedBody?.error?.code && parsedResponse.parsedBody?.error?.message)) { + !(((_c = (_b = parsedResponse.parsedBody) === null || _b === void 0 ? void 0 : _b.error) === null || _c === void 0 ? void 0 : _c.code) && ((_e = (_d = parsedResponse.parsedBody) === null || _d === void 0 ? void 0 : _d.error) === null || _e === void 0 ? void 0 : _e.message))) { throw error; } - const defaultBodyMapper = errorResponseSpec?.bodyMapper; - const defaultHeadersMapper = errorResponseSpec?.headersMapper; + const defaultBodyMapper = errorResponseSpec === null || errorResponseSpec === void 0 ? void 0 : errorResponseSpec.bodyMapper; + const defaultHeadersMapper = errorResponseSpec === null || errorResponseSpec === void 0 ? void 0 : errorResponseSpec.headersMapper; try { // If error response has a body, try to deserialize it using default body mapper. // Then try to extract error code & message from it @@ -45253,7 +45250,8 @@ function handleErrorResponse(parsedResponse, operationSpec, responseSpec, option return { error, shouldReturnResponse: false }; } async function parse(jsonContentTypes, xmlContentTypes, operationResponse, opts, parseXML) { - if (!operationResponse.request.streamResponseStatusCodes?.has(operationResponse.status) && + var _a; + if (!((_a = operationResponse.request.streamResponseStatusCodes) === null || _a === void 0 ? void 0 : _a.has(operationResponse.status)) && operationResponse.bodyAsText) { const text = operationResponse.bodyAsText; const contentType = operationResponse.headers.get("Content-Type") || ""; @@ -45293,7 +45291,7 @@ async function parse(jsonContentTypes, xmlContentTypes, operationResponse, opts, /***/ }), -/***/ 59855: +/***/ 33368: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -45301,7 +45299,7 @@ async function parse(jsonContentTypes, xmlContentTypes, operationResponse, opts, // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.getCachedDefaultHttpClient = getCachedDefaultHttpClient; -const core_rest_pipeline_1 = __nccwpck_require__(64839); +const core_rest_pipeline_1 = __nccwpck_require__(54786); let cachedHttpClient; function getCachedDefaultHttpClient() { if (!cachedHttpClient) { @@ -45313,7 +45311,7 @@ function getCachedDefaultHttpClient() { /***/ }), -/***/ 32588: +/***/ 9235: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -45321,31 +45319,31 @@ function getCachedDefaultHttpClient() { // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.authorizeRequestOnTenantChallenge = exports.authorizeRequestOnClaimChallenge = exports.serializationPolicyName = exports.serializationPolicy = exports.deserializationPolicyName = exports.deserializationPolicy = exports.XML_CHARKEY = exports.XML_ATTRKEY = exports.createClientPipeline = exports.ServiceClient = exports.MapperTypeNames = exports.createSerializer = void 0; -var serializer_js_1 = __nccwpck_require__(54414); +var serializer_js_1 = __nccwpck_require__(25019); Object.defineProperty(exports, "createSerializer", ({ enumerable: true, get: function () { return serializer_js_1.createSerializer; } })); Object.defineProperty(exports, "MapperTypeNames", ({ enumerable: true, get: function () { return serializer_js_1.MapperTypeNames; } })); -var serviceClient_js_1 = __nccwpck_require__(63572); +var serviceClient_js_1 = __nccwpck_require__(37435); Object.defineProperty(exports, "ServiceClient", ({ enumerable: true, get: function () { return serviceClient_js_1.ServiceClient; } })); -var pipeline_js_1 = __nccwpck_require__(44324); +var pipeline_js_1 = __nccwpck_require__(13225); Object.defineProperty(exports, "createClientPipeline", ({ enumerable: true, get: function () { return pipeline_js_1.createClientPipeline; } })); -var interfaces_js_1 = __nccwpck_require__(5150); +var interfaces_js_1 = __nccwpck_require__(38839); Object.defineProperty(exports, "XML_ATTRKEY", ({ enumerable: true, get: function () { return interfaces_js_1.XML_ATTRKEY; } })); Object.defineProperty(exports, "XML_CHARKEY", ({ enumerable: true, get: function () { return interfaces_js_1.XML_CHARKEY; } })); -var deserializationPolicy_js_1 = __nccwpck_require__(59515); +var deserializationPolicy_js_1 = __nccwpck_require__(76268); Object.defineProperty(exports, "deserializationPolicy", ({ enumerable: true, get: function () { return deserializationPolicy_js_1.deserializationPolicy; } })); Object.defineProperty(exports, "deserializationPolicyName", ({ enumerable: true, get: function () { return deserializationPolicy_js_1.deserializationPolicyName; } })); -var serializationPolicy_js_1 = __nccwpck_require__(98054); +var serializationPolicy_js_1 = __nccwpck_require__(65873); Object.defineProperty(exports, "serializationPolicy", ({ enumerable: true, get: function () { return serializationPolicy_js_1.serializationPolicy; } })); Object.defineProperty(exports, "serializationPolicyName", ({ enumerable: true, get: function () { return serializationPolicy_js_1.serializationPolicyName; } })); -var authorizeRequestOnClaimChallenge_js_1 = __nccwpck_require__(5022); +var authorizeRequestOnClaimChallenge_js_1 = __nccwpck_require__(90247); Object.defineProperty(exports, "authorizeRequestOnClaimChallenge", ({ enumerable: true, get: function () { return authorizeRequestOnClaimChallenge_js_1.authorizeRequestOnClaimChallenge; } })); -var authorizeRequestOnTenantChallenge_js_1 = __nccwpck_require__(64890); +var authorizeRequestOnTenantChallenge_js_1 = __nccwpck_require__(62785); Object.defineProperty(exports, "authorizeRequestOnTenantChallenge", ({ enumerable: true, get: function () { return authorizeRequestOnTenantChallenge_js_1.authorizeRequestOnTenantChallenge; } })); //# sourceMappingURL=index.js.map /***/ }), -/***/ 6350: +/***/ 58739: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -45354,7 +45352,7 @@ Object.defineProperty(exports, "authorizeRequestOnTenantChallenge", ({ enumerabl Object.defineProperty(exports, "__esModule", ({ value: true })); exports.getStreamingResponseStatusCodes = getStreamingResponseStatusCodes; exports.getPathStringFromParameter = getPathStringFromParameter; -const serializer_js_1 = __nccwpck_require__(54414); +const serializer_js_1 = __nccwpck_require__(25019); /** * Gets the list of status codes for streaming responses. * @internal @@ -45394,7 +45392,7 @@ function getPathStringFromParameter(parameter) { /***/ }), -/***/ 5150: +/***/ 38839: /***/ ((__unused_webpack_module, exports) => { @@ -45414,7 +45412,7 @@ exports.XML_CHARKEY = "_"; /***/ }), -/***/ 54006: +/***/ 64341: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -45428,7 +45426,7 @@ exports.logger = (0, logger_1.createClientLogger)("core-client"); /***/ }), -/***/ 75108: +/***/ 93609: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -45437,7 +45435,7 @@ exports.logger = (0, logger_1.createClientLogger)("core-client"); Object.defineProperty(exports, "__esModule", ({ value: true })); exports.getOperationArgumentValueFromParameter = getOperationArgumentValueFromParameter; exports.getOperationRequestInfo = getOperationRequestInfo; -const state_js_1 = __nccwpck_require__(86925); +const state_js_1 = __nccwpck_require__(48166); /** * @internal * Retrieves the value to use for a given operation argument @@ -45532,7 +45530,7 @@ function getOperationRequestInfo(request) { /***/ }), -/***/ 44324: +/***/ 13225: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -45540,9 +45538,9 @@ function getOperationRequestInfo(request) { // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.createClientPipeline = createClientPipeline; -const deserializationPolicy_js_1 = __nccwpck_require__(59515); -const core_rest_pipeline_1 = __nccwpck_require__(64839); -const serializationPolicy_js_1 = __nccwpck_require__(98054); +const deserializationPolicy_js_1 = __nccwpck_require__(76268); +const core_rest_pipeline_1 = __nccwpck_require__(54786); +const serializationPolicy_js_1 = __nccwpck_require__(65873); /** * Creates a new Pipeline for use with a Service Client. * Adds in deserializationPolicy by default. @@ -45550,7 +45548,7 @@ const serializationPolicy_js_1 = __nccwpck_require__(98054); * @param options - Options to customize the created pipeline. */ function createClientPipeline(options = {}) { - const pipeline = (0, core_rest_pipeline_1.createPipelineFromOptions)(options ?? {}); + const pipeline = (0, core_rest_pipeline_1.createPipelineFromOptions)(options !== null && options !== void 0 ? options : {}); if (options.credentialOptions) { pipeline.addPolicy((0, core_rest_pipeline_1.bearerTokenAuthenticationPolicy)({ credential: options.credentialOptions.credential, @@ -45567,7 +45565,7 @@ function createClientPipeline(options = {}) { /***/ }), -/***/ 98054: +/***/ 65873: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -45578,10 +45576,10 @@ exports.serializationPolicyName = void 0; exports.serializationPolicy = serializationPolicy; exports.serializeHeaders = serializeHeaders; exports.serializeRequestBody = serializeRequestBody; -const interfaces_js_1 = __nccwpck_require__(5150); -const operationHelpers_js_1 = __nccwpck_require__(75108); -const serializer_js_1 = __nccwpck_require__(54414); -const interfaceHelpers_js_1 = __nccwpck_require__(6350); +const interfaces_js_1 = __nccwpck_require__(38839); +const operationHelpers_js_1 = __nccwpck_require__(93609); +const serializer_js_1 = __nccwpck_require__(25019); +const interfaceHelpers_js_1 = __nccwpck_require__(58739); /** * The programmatic identifier of the serializationPolicy. */ @@ -45596,8 +45594,8 @@ function serializationPolicy(options = {}) { name: exports.serializationPolicyName, async sendRequest(request, next) { const operationInfo = (0, operationHelpers_js_1.getOperationRequestInfo)(request); - const operationSpec = operationInfo?.operationSpec; - const operationArguments = operationInfo?.operationArguments; + const operationSpec = operationInfo === null || operationInfo === void 0 ? void 0 : operationInfo.operationSpec; + const operationArguments = operationInfo === null || operationInfo === void 0 ? void 0 : operationInfo.operationArguments; if (operationSpec && operationArguments) { serializeHeaders(request, operationArguments, operationSpec); serializeRequestBody(request, operationArguments, operationSpec, stringifyXML); @@ -45610,6 +45608,7 @@ function serializationPolicy(options = {}) { * @internal */ function serializeHeaders(request, operationArguments, operationSpec) { + var _a, _b; if (operationSpec.headerParameters) { for (const headerParameter of operationSpec.headerParameters) { let headerValue = (0, operationHelpers_js_1.getOperationArgumentValueFromParameter)(operationArguments, headerParameter); @@ -45628,7 +45627,7 @@ function serializeHeaders(request, operationArguments, operationSpec) { } } } - const customHeaders = operationArguments.options?.requestOptions?.customHeaders; + const customHeaders = (_b = (_a = operationArguments.options) === null || _a === void 0 ? void 0 : _a.requestOptions) === null || _b === void 0 ? void 0 : _b.customHeaders; if (customHeaders) { for (const customHeaderName of Object.keys(customHeaders)) { request.headers.set(customHeaderName, customHeaders[customHeaderName]); @@ -45641,12 +45640,13 @@ function serializeHeaders(request, operationArguments, operationSpec) { function serializeRequestBody(request, operationArguments, operationSpec, stringifyXML = function () { throw new Error("XML serialization unsupported!"); }) { - const serializerOptions = operationArguments.options?.serializerOptions; + var _a, _b, _c, _d, _e; + const serializerOptions = (_a = operationArguments.options) === null || _a === void 0 ? void 0 : _a.serializerOptions; const updatedOptions = { xml: { - rootName: serializerOptions?.xml.rootName ?? "", - includeRoot: serializerOptions?.xml.includeRoot ?? false, - xmlCharKey: serializerOptions?.xml.xmlCharKey ?? interfaces_js_1.XML_CHARKEY, + rootName: (_b = serializerOptions === null || serializerOptions === void 0 ? void 0 : serializerOptions.xml.rootName) !== null && _b !== void 0 ? _b : "", + includeRoot: (_c = serializerOptions === null || serializerOptions === void 0 ? void 0 : serializerOptions.xml.includeRoot) !== null && _c !== void 0 ? _c : false, + xmlCharKey: (_d = serializerOptions === null || serializerOptions === void 0 ? void 0 : serializerOptions.xml.xmlCharKey) !== null && _d !== void 0 ? _d : interfaces_js_1.XML_CHARKEY, }, }; const xmlCharKey = updatedOptions.xml.xmlCharKey; @@ -45676,7 +45676,7 @@ function serializeRequestBody(request, operationArguments, operationSpec, string } } else if (typeName === serializer_js_1.MapperTypeNames.String && - (operationSpec.contentType?.match("text/plain") || operationSpec.mediaType === "text")) { + (((_e = operationSpec.contentType) === null || _e === void 0 ? void 0 : _e.match("text/plain")) || operationSpec.mediaType === "text")) { // the String serializer has validated that request body is a string // so just send the string. return; @@ -45730,7 +45730,7 @@ function prepareXMLRootList(obj, elementName, xmlNamespaceKey, xmlNamespace) { /***/ }), -/***/ 54414: +/***/ 25019: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -45740,12 +45740,10 @@ Object.defineProperty(exports, "__esModule", ({ value: true })); exports.MapperTypeNames = void 0; exports.createSerializer = createSerializer; const tslib_1 = __nccwpck_require__(31577); -const base64 = tslib_1.__importStar(__nccwpck_require__(15465)); -const interfaces_js_1 = __nccwpck_require__(5150); -const utils_js_1 = __nccwpck_require__(18757); +const base64 = tslib_1.__importStar(__nccwpck_require__(36732)); +const interfaces_js_1 = __nccwpck_require__(38839); +const utils_js_1 = __nccwpck_require__(40398); class SerializerImpl { - modelMappers; - isXML; constructor(modelMappers = {}, isXML = false) { this.modelMappers = modelMappers; this.isXML = isXML; @@ -45812,11 +45810,12 @@ class SerializerImpl { * @returns A valid serialized Javascript object */ serialize(mapper, object, objectName, options = { xml: {} }) { + var _a, _b, _c; const updatedOptions = { xml: { - rootName: options.xml.rootName ?? "", - includeRoot: options.xml.includeRoot ?? false, - xmlCharKey: options.xml.xmlCharKey ?? interfaces_js_1.XML_CHARKEY, + rootName: (_a = options.xml.rootName) !== null && _a !== void 0 ? _a : "", + includeRoot: (_b = options.xml.includeRoot) !== null && _b !== void 0 ? _b : false, + xmlCharKey: (_c = options.xml.xmlCharKey) !== null && _c !== void 0 ? _c : interfaces_js_1.XML_CHARKEY, }, }; let payload = {}; @@ -45898,13 +45897,14 @@ class SerializerImpl { * @returns A valid deserialized Javascript object */ deserialize(mapper, responseBody, objectName, options = { xml: {} }) { + var _a, _b, _c, _d; const updatedOptions = { xml: { - rootName: options.xml.rootName ?? "", - includeRoot: options.xml.includeRoot ?? false, - xmlCharKey: options.xml.xmlCharKey ?? interfaces_js_1.XML_CHARKEY, + rootName: (_a = options.xml.rootName) !== null && _a !== void 0 ? _a : "", + includeRoot: (_b = options.xml.includeRoot) !== null && _b !== void 0 ? _b : false, + xmlCharKey: (_c = options.xml.xmlCharKey) !== null && _c !== void 0 ? _c : interfaces_js_1.XML_CHARKEY, }, - ignoreUnknownProperties: options.ignoreUnknownProperties ?? false, + ignoreUnknownProperties: (_d = options.ignoreUnknownProperties) !== null && _d !== void 0 ? _d : false, }; if (responseBody === undefined || responseBody === null) { if (this.isXML && mapper.type.name === "Sequence" && !mapper.xmlIsWrapped) { @@ -46170,6 +46170,7 @@ function serializeDateTypes(typeName, value, objectName) { return value; } function serializeSequenceType(serializer, mapper, object, objectName, isXml, options) { + var _a; if (!Array.isArray(object)) { throw new Error(`${objectName} must be of type Array.`); } @@ -46182,7 +46183,7 @@ function serializeSequenceType(serializer, mapper, object, objectName, isXml, op // not have *all* properties declared (like uberParent), // so let's try to look up the full definition by name. if (elementType.type.name === "Composite" && elementType.type.className) { - elementType = serializer.modelMappers[elementType.type.className] ?? elementType; + elementType = (_a = serializer.modelMappers[elementType.type.className]) !== null && _a !== void 0 ? _a : elementType; } const tempArray = []; for (let i = 0; i < object.length; i++) { @@ -46192,7 +46193,7 @@ function serializeSequenceType(serializer, mapper, object, objectName, isXml, op ? `xmlns:${elementType.xmlNamespacePrefix}` : "xmlns"; if (elementType.type.name === "Composite") { - tempArray[i] = { ...serializedValue }; + tempArray[i] = Object.assign({}, serializedValue); tempArray[i][interfaces_js_1.XML_ATTRKEY] = { [xmlnsKey]: elementType.xmlNamespace }; } else { @@ -46241,7 +46242,7 @@ function resolveAdditionalProperties(serializer, mapper, objectName) { const additionalProperties = mapper.type.additionalProperties; if (!additionalProperties && mapper.type.className) { const modelMapper = resolveReferencedMapper(serializer, mapper, objectName); - return modelMapper?.type.additionalProperties; + return modelMapper === null || modelMapper === void 0 ? void 0 : modelMapper.type.additionalProperties; } return additionalProperties; } @@ -46270,7 +46271,7 @@ function resolveModelProperties(serializer, mapper, objectName) { if (!modelMapper) { throw new Error(`mapper() cannot be null or undefined for model "${mapper.type.className}".`); } - modelProps = modelMapper?.type.modelProperties; + modelProps = modelMapper === null || modelMapper === void 0 ? void 0 : modelMapper.type.modelProperties; if (!modelProps) { throw new Error(`modelProperties cannot be null or undefined in the ` + `mapper "${JSON.stringify(modelMapper)}" of type "${mapper.type.className}" for object "${objectName}".`); @@ -46318,10 +46319,7 @@ function serializeCompositeType(serializer, mapper, object, objectName, isXml, o const xmlnsKey = mapper.xmlNamespacePrefix ? `xmlns:${mapper.xmlNamespacePrefix}` : "xmlns"; - parentObject[interfaces_js_1.XML_ATTRKEY] = { - ...parentObject[interfaces_js_1.XML_ATTRKEY], - [xmlnsKey]: mapper.xmlNamespace, - }; + parentObject[interfaces_js_1.XML_ATTRKEY] = Object.assign(Object.assign({}, parentObject[interfaces_js_1.XML_ATTRKEY]), { [xmlnsKey]: mapper.xmlNamespace }); } const propertyObjectName = propertyMapper.serializedName !== "" ? objectName + "." + propertyMapper.serializedName @@ -46379,7 +46377,7 @@ function getXmlObjectValue(propertyMapper, serializedValue, isXml, options) { return serializedValue; } else { - const result = { ...serializedValue }; + const result = Object.assign({}, serializedValue); result[interfaces_js_1.XML_ATTRKEY] = xmlNamespace; return result; } @@ -46393,7 +46391,8 @@ function isSpecialXmlProperty(propertyName, options) { return [interfaces_js_1.XML_ATTRKEY, options.xml.xmlCharKey].includes(propertyName); } function deserializeCompositeType(serializer, mapper, responseBody, objectName, options) { - const xmlCharKey = options.xml.xmlCharKey ?? interfaces_js_1.XML_CHARKEY; + var _a, _b; + const xmlCharKey = (_a = options.xml.xmlCharKey) !== null && _a !== void 0 ? _a : interfaces_js_1.XML_CHARKEY; if (getPolymorphicDiscriminatorRecursively(serializer, mapper)) { mapper = getPolymorphicMapper(serializer, mapper, responseBody, "serializedName"); } @@ -46452,7 +46451,7 @@ function deserializeCompositeType(serializer, mapper, responseBody, objectName, xmlName is "Cors" and xmlElementName is"CorsRule". */ const wrapped = responseBody[xmlName]; - const elementList = wrapped?.[xmlElementName] ?? []; + const elementList = (_b = wrapped === null || wrapped === void 0 ? void 0 : wrapped[xmlElementName]) !== null && _b !== void 0 ? _b : []; instance[key] = serializer.deserialize(propertyMapper, elementList, propertyObjectName, options); handledPropertyNames.push(xmlName); } @@ -46560,6 +46559,7 @@ function deserializeDictionaryType(serializer, mapper, responseBody, objectName, return responseBody; } function deserializeSequenceType(serializer, mapper, responseBody, objectName, options) { + var _a; let element = mapper.type.element; if (!element || typeof element !== "object") { throw new Error(`element" metadata for an Array must be defined in the ` + @@ -46574,7 +46574,7 @@ function deserializeSequenceType(serializer, mapper, responseBody, objectName, o // not have *all* properties declared (like uberParent), // so let's try to look up the full definition by name. if (element.type.name === "Composite" && element.type.className) { - element = serializer.modelMappers[element.type.className] ?? element; + element = (_a = serializer.modelMappers[element.type.className]) !== null && _a !== void 0 ? _a : element; } const tempArray = []; for (let i = 0; i < responseBody.length; i++) { @@ -46607,6 +46607,7 @@ function getIndexDiscriminator(discriminators, discriminatorValue, typeName) { return undefined; } function getPolymorphicMapper(serializer, mapper, object, polymorphicPropertyName) { + var _a; const polymorphicDiscriminator = getPolymorphicDiscriminatorRecursively(serializer, mapper); if (polymorphicDiscriminator) { let discriminatorName = polymorphicDiscriminator[polymorphicPropertyName]; @@ -46616,7 +46617,7 @@ function getPolymorphicMapper(serializer, mapper, object, polymorphicPropertyNam discriminatorName = discriminatorName.replace(/\\/gi, ""); } const discriminatorValue = object[discriminatorName]; - const typeName = mapper.type.uberParent ?? mapper.type.className; + const typeName = (_a = mapper.type.uberParent) !== null && _a !== void 0 ? _a : mapper.type.className; if (typeof discriminatorValue === "string" && typeName) { const polymorphicMapper = getIndexDiscriminator(serializer.modelMappers.discriminators, discriminatorValue, typeName); if (polymorphicMapper) { @@ -46662,7 +46663,7 @@ exports.MapperTypeNames = { /***/ }), -/***/ 63572: +/***/ 37435: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -46670,54 +46671,33 @@ exports.MapperTypeNames = { // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.ServiceClient = void 0; -const core_rest_pipeline_1 = __nccwpck_require__(64839); -const pipeline_js_1 = __nccwpck_require__(44324); -const utils_js_1 = __nccwpck_require__(18757); -const httpClientCache_js_1 = __nccwpck_require__(59855); -const operationHelpers_js_1 = __nccwpck_require__(75108); -const urlHelpers_js_1 = __nccwpck_require__(93292); -const interfaceHelpers_js_1 = __nccwpck_require__(6350); -const log_js_1 = __nccwpck_require__(54006); +const core_rest_pipeline_1 = __nccwpck_require__(54786); +const pipeline_js_1 = __nccwpck_require__(13225); +const utils_js_1 = __nccwpck_require__(40398); +const httpClientCache_js_1 = __nccwpck_require__(33368); +const operationHelpers_js_1 = __nccwpck_require__(93609); +const urlHelpers_js_1 = __nccwpck_require__(52825); +const interfaceHelpers_js_1 = __nccwpck_require__(58739); +const log_js_1 = __nccwpck_require__(64341); /** * Initializes a new instance of the ServiceClient. */ class ServiceClient { - /** - * If specified, this is the base URI that requests will be made against for this ServiceClient. - * If it is not specified, then all OperationSpecs must contain a baseUrl property. - */ - _endpoint; - /** - * The default request content type for the service. - * Used if no requestContentType is present on an OperationSpec. - */ - _requestContentType; - /** - * Set to true if the request is sent over HTTP instead of HTTPS - */ - _allowInsecureConnection; - /** - * The HTTP client that will be used to send requests. - */ - _httpClient; - /** - * The pipeline used by this client to make requests - */ - pipeline; /** * The ServiceClient constructor * @param options - The service client options that govern the behavior of the client. */ constructor(options = {}) { + var _a, _b; this._requestContentType = options.requestContentType; - this._endpoint = options.endpoint ?? options.baseUri; + this._endpoint = (_a = options.endpoint) !== null && _a !== void 0 ? _a : options.baseUri; if (options.baseUri) { log_js_1.logger.warning("The baseUri option for SDK Clients has been deprecated, please use endpoint instead."); } this._allowInsecureConnection = options.allowInsecureConnection; this._httpClient = options.httpClient || (0, httpClientCache_js_1.getCachedDefaultHttpClient)(); this.pipeline = options.pipeline || createDefaultPipeline(options); - if (options.additionalPolicies?.length) { + if ((_b = options.additionalPolicies) === null || _b === void 0 ? void 0 : _b.length) { for (const { policy, position } of options.additionalPolicies) { // Sign happens after Retry and is commonly needed to occur // before policies that intercept post-retry. @@ -46796,17 +46776,17 @@ class ServiceClient { try { const rawResponse = await this.sendRequest(request); const flatResponse = (0, utils_js_1.flattenResponse)(rawResponse, operationSpec.responses[rawResponse.status]); - if (options?.onResponse) { + if (options === null || options === void 0 ? void 0 : options.onResponse) { options.onResponse(rawResponse, flatResponse); } return flatResponse; } catch (error) { - if (typeof error === "object" && error?.response) { + if (typeof error === "object" && (error === null || error === void 0 ? void 0 : error.response)) { const rawResponse = error.response; const flatResponse = (0, utils_js_1.flattenResponse)(rawResponse, operationSpec.responses[error.statusCode] || operationSpec.responses["default"]); error.details = flatResponse; - if (options?.onResponse) { + if (options === null || options === void 0 ? void 0 : options.onResponse) { options.onResponse(rawResponse, flatResponse, error); } } @@ -46820,10 +46800,7 @@ function createDefaultPipeline(options) { const credentialOptions = options.credential && credentialScopes ? { credentialScopes, credential: options.credential } : undefined; - return (0, pipeline_js_1.createClientPipeline)({ - ...options, - credentialOptions, - }); + return (0, pipeline_js_1.createClientPipeline)(Object.assign(Object.assign({}, options), { credentialOptions })); } function getCredentialScopes(options) { if (options.credentialScopes) { @@ -46844,7 +46821,7 @@ function getCredentialScopes(options) { /***/ }), -/***/ 86925: +/***/ 48166: /***/ ((__unused_webpack_module, exports) => { @@ -46862,7 +46839,7 @@ exports.state = { /***/ }), -/***/ 93292: +/***/ 52825: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -46871,8 +46848,8 @@ exports.state = { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.getRequestUrl = getRequestUrl; exports.appendQueryParams = appendQueryParams; -const operationHelpers_js_1 = __nccwpck_require__(75108); -const interfaceHelpers_js_1 = __nccwpck_require__(6350); +const operationHelpers_js_1 = __nccwpck_require__(93609); +const interfaceHelpers_js_1 = __nccwpck_require__(58739); const CollectionFormatToDelimiterMap = { CSV: ",", SSV: " ", @@ -46921,8 +46898,9 @@ function replaceAll(input, replacements) { return result; } function calculateUrlReplacements(operationSpec, operationArguments, fallbackObject) { + var _a; const result = new Map(); - if (operationSpec.urlParameters?.length) { + if ((_a = operationSpec.urlParameters) === null || _a === void 0 ? void 0 : _a.length) { for (const urlParameter of operationSpec.urlParameters) { let urlParameterValue = (0, operationHelpers_js_1.getOperationArgumentValueFromParameter)(operationArguments, urlParameter, fallbackObject); const parameterPathString = (0, interfaceHelpers_js_1.getPathStringFromParameter)(urlParameter); @@ -46966,9 +46944,10 @@ function appendPath(url, pathToAppend) { return parsedUrl.toString(); } function calculateQueryParameters(operationSpec, operationArguments, fallbackObject) { + var _a; const result = new Map(); const sequenceParams = new Set(); - if (operationSpec.queryParameters?.length) { + if ((_a = operationSpec.queryParameters) === null || _a === void 0 ? void 0 : _a.length) { for (const queryParameter of operationSpec.queryParameters) { if (queryParameter.mapper.type.name === "Sequence" && queryParameter.mapper.serializedName) { sequenceParams.add(queryParameter.mapper.serializedName); @@ -47105,7 +47084,7 @@ function appendQueryParams(url, queryParams, sequenceParams, noOverwrite = false /***/ }), -/***/ 18757: +/***/ 40398: /***/ ((__unused_webpack_module, exports) => { @@ -47128,7 +47107,7 @@ function isPrimitiveBody(value, mapperTypeName) { (typeof value === "string" || typeof value === "number" || typeof value === "boolean" || - mapperTypeName?.match(/^(Date|DateTime|DateTimeRfc1123|UnixTime|ByteArray|Base64Url)$/i) !== + (mapperTypeName === null || mapperTypeName === void 0 ? void 0 : mapperTypeName.match(/^(Date|DateTime|DateTimeRfc1123|UnixTime|ByteArray|Base64Url)$/i)) !== null || value === undefined || value === null)); @@ -47165,21 +47144,14 @@ function isValidUuid(uuid) { * @internal */ function handleNullableResponseAndWrappableBody(responseObject) { - const combinedHeadersAndBody = { - ...responseObject.headers, - ...responseObject.body, - }; + const combinedHeadersAndBody = Object.assign(Object.assign({}, responseObject.headers), responseObject.body); if (responseObject.hasNullableType && Object.getOwnPropertyNames(combinedHeadersAndBody).length === 0) { return responseObject.shouldWrapBody ? { body: null } : null; } else { return responseObject.shouldWrapBody - ? { - ...responseObject.headers, - body: responseObject.body, - } - : combinedHeadersAndBody; + ? Object.assign(Object.assign({}, responseObject.headers), { body: responseObject.body }) : combinedHeadersAndBody; } } /** @@ -47191,35 +47163,29 @@ function handleNullableResponseAndWrappableBody(responseObject) { * @internal */ function flattenResponse(fullResponse, responseSpec) { + var _a, _b; const parsedHeaders = fullResponse.parsedHeaders; // head methods never have a body, but we return a boolean set to body property // to indicate presence/absence of the resource if (fullResponse.request.method === "HEAD") { - return { - ...parsedHeaders, - body: fullResponse.parsedBody, - }; + return Object.assign(Object.assign({}, parsedHeaders), { body: fullResponse.parsedBody }); } const bodyMapper = responseSpec && responseSpec.bodyMapper; - const isNullable = Boolean(bodyMapper?.nullable); - const expectedBodyTypeName = bodyMapper?.type.name; + const isNullable = Boolean(bodyMapper === null || bodyMapper === void 0 ? void 0 : bodyMapper.nullable); + const expectedBodyTypeName = bodyMapper === null || bodyMapper === void 0 ? void 0 : bodyMapper.type.name; /** If the body is asked for, we look at the expected body type to handle it */ if (expectedBodyTypeName === "Stream") { - return { - ...parsedHeaders, - blobBody: fullResponse.blobBody, - readableStreamBody: fullResponse.readableStreamBody, - }; + return Object.assign(Object.assign({}, parsedHeaders), { blobBody: fullResponse.blobBody, readableStreamBody: fullResponse.readableStreamBody }); } const modelProperties = (expectedBodyTypeName === "Composite" && bodyMapper.type.modelProperties) || {}; const isPageableResponse = Object.keys(modelProperties).some((k) => modelProperties[k].serializedName === ""); if (expectedBodyTypeName === "Sequence" || isPageableResponse) { - const arrayResponse = fullResponse.parsedBody ?? []; + const arrayResponse = (_a = fullResponse.parsedBody) !== null && _a !== void 0 ? _a : []; for (const key of Object.keys(modelProperties)) { if (modelProperties[key].serializedName) { - arrayResponse[key] = fullResponse.parsedBody?.[key]; + arrayResponse[key] = (_b = fullResponse.parsedBody) === null || _b === void 0 ? void 0 : _b[key]; } } if (parsedHeaders) { @@ -47245,7 +47211,7 @@ function flattenResponse(fullResponse, responseSpec) { /***/ }), -/***/ 46495: +/***/ 47828: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -47253,21 +47219,22 @@ function flattenResponse(fullResponse, responseSpec) { // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.ExtendedServiceClient = void 0; -const disableKeepAlivePolicy_js_1 = __nccwpck_require__(79030); -const core_rest_pipeline_1 = __nccwpck_require__(64839); -const core_client_1 = __nccwpck_require__(32588); -const response_js_1 = __nccwpck_require__(40158); +const disableKeepAlivePolicy_js_1 = __nccwpck_require__(87215); +const core_rest_pipeline_1 = __nccwpck_require__(54786); +const core_client_1 = __nccwpck_require__(9235); +const response_js_1 = __nccwpck_require__(37209); /** * Client to provide compatability between core V1 & V2. */ class ExtendedServiceClient extends core_client_1.ServiceClient { constructor(options) { + var _a, _b; super(options); - if (options.keepAliveOptions?.enable === false && + if (((_a = options.keepAliveOptions) === null || _a === void 0 ? void 0 : _a.enable) === false && !(0, disableKeepAlivePolicy_js_1.pipelineContainsDisableKeepAlivePolicy)(this.pipeline)) { this.pipeline.addPolicy((0, disableKeepAlivePolicy_js_1.createDisableKeepAlivePolicy)()); } - if (options.redirectOptions?.handleRedirects === false) { + if (((_b = options.redirectOptions) === null || _b === void 0 ? void 0 : _b.handleRedirects) === false) { this.pipeline.removePolicy({ name: core_rest_pipeline_1.redirectPolicyName, }); @@ -47281,7 +47248,8 @@ class ExtendedServiceClient extends core_client_1.ServiceClient { * @returns */ async sendOperationRequest(operationArguments, operationSpec) { - const userProvidedCallBack = operationArguments?.options?.onResponse; + var _a; + const userProvidedCallBack = (_a = operationArguments === null || operationArguments === void 0 ? void 0 : operationArguments.options) === null || _a === void 0 ? void 0 : _a.onResponse; let lastResponse; function onResponse(rawResponse, flatResponse, error) { lastResponse = rawResponse; @@ -47289,10 +47257,7 @@ class ExtendedServiceClient extends core_client_1.ServiceClient { userProvidedCallBack(rawResponse, flatResponse, error); } } - operationArguments.options = { - ...operationArguments.options, - onResponse, - }; + operationArguments.options = Object.assign(Object.assign({}, operationArguments.options), { onResponse }); const result = await super.sendOperationRequest(operationArguments, operationSpec); if (lastResponse) { Object.defineProperty(result, "_response", { @@ -47307,7 +47272,7 @@ exports.ExtendedServiceClient = ExtendedServiceClient; /***/ }), -/***/ 61519: +/***/ 1582: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -47315,8 +47280,8 @@ exports.ExtendedServiceClient = ExtendedServiceClient; // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.convertHttpClient = convertHttpClient; -const response_js_1 = __nccwpck_require__(40158); -const util_js_1 = __nccwpck_require__(57777); +const response_js_1 = __nccwpck_require__(37209); +const util_js_1 = __nccwpck_require__(24970); /** * Converts a RequestPolicy based HttpClient to a PipelineRequest based HttpClient. * @param requestPolicyClient - A HttpClient compatible with core-http @@ -47334,7 +47299,7 @@ function convertHttpClient(requestPolicyClient) { /***/ }), -/***/ 37385: +/***/ 62464: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -47347,23 +47312,23 @@ exports.toHttpHeadersLike = exports.convertHttpClient = exports.disableKeepAlive * * @packageDocumentation */ -var extendedClient_js_1 = __nccwpck_require__(46495); +var extendedClient_js_1 = __nccwpck_require__(47828); Object.defineProperty(exports, "ExtendedServiceClient", ({ enumerable: true, get: function () { return extendedClient_js_1.ExtendedServiceClient; } })); -var requestPolicyFactoryPolicy_js_1 = __nccwpck_require__(43179); +var requestPolicyFactoryPolicy_js_1 = __nccwpck_require__(83533); Object.defineProperty(exports, "requestPolicyFactoryPolicyName", ({ enumerable: true, get: function () { return requestPolicyFactoryPolicy_js_1.requestPolicyFactoryPolicyName; } })); Object.defineProperty(exports, "createRequestPolicyFactoryPolicy", ({ enumerable: true, get: function () { return requestPolicyFactoryPolicy_js_1.createRequestPolicyFactoryPolicy; } })); Object.defineProperty(exports, "HttpPipelineLogLevel", ({ enumerable: true, get: function () { return requestPolicyFactoryPolicy_js_1.HttpPipelineLogLevel; } })); -var disableKeepAlivePolicy_js_1 = __nccwpck_require__(79030); +var disableKeepAlivePolicy_js_1 = __nccwpck_require__(87215); Object.defineProperty(exports, "disableKeepAlivePolicyName", ({ enumerable: true, get: function () { return disableKeepAlivePolicy_js_1.disableKeepAlivePolicyName; } })); -var httpClientAdapter_js_1 = __nccwpck_require__(61519); +var httpClientAdapter_js_1 = __nccwpck_require__(1582); Object.defineProperty(exports, "convertHttpClient", ({ enumerable: true, get: function () { return httpClientAdapter_js_1.convertHttpClient; } })); -var util_js_1 = __nccwpck_require__(57777); +var util_js_1 = __nccwpck_require__(24970); Object.defineProperty(exports, "toHttpHeadersLike", ({ enumerable: true, get: function () { return util_js_1.toHttpHeadersLike; } })); //# sourceMappingURL=index.js.map /***/ }), -/***/ 79030: +/***/ 87215: /***/ ((__unused_webpack_module, exports) => { @@ -47393,7 +47358,7 @@ function pipelineContainsDisableKeepAlivePolicy(pipeline) { /***/ }), -/***/ 43179: +/***/ 83533: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -47402,8 +47367,8 @@ function pipelineContainsDisableKeepAlivePolicy(pipeline) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.requestPolicyFactoryPolicyName = exports.HttpPipelineLogLevel = void 0; exports.createRequestPolicyFactoryPolicy = createRequestPolicyFactoryPolicy; -const util_js_1 = __nccwpck_require__(57777); -const response_js_1 = __nccwpck_require__(40158); +const util_js_1 = __nccwpck_require__(24970); +const response_js_1 = __nccwpck_require__(37209); /** * An enum for compatibility with RequestPolicy */ @@ -47454,7 +47419,7 @@ function createRequestPolicyFactoryPolicy(factories) { /***/ }), -/***/ 40158: +/***/ 37209: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -47463,8 +47428,8 @@ function createRequestPolicyFactoryPolicy(factories) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.toCompatResponse = toCompatResponse; exports.toPipelineResponse = toPipelineResponse; -const core_rest_pipeline_1 = __nccwpck_require__(64839); -const util_js_1 = __nccwpck_require__(57777); +const core_rest_pipeline_1 = __nccwpck_require__(54786); +const util_js_1 = __nccwpck_require__(24970); const originalResponse = Symbol("Original FullOperationResponse"); /** * A helper to convert response objects from the new pipeline back to the old one. @@ -47474,7 +47439,7 @@ const originalResponse = Symbol("Original FullOperationResponse"); function toCompatResponse(response, options) { let request = (0, util_js_1.toWebResourceLike)(response.request); let headers = (0, util_js_1.toHttpHeadersLike)(response.headers); - if (options?.createProxy) { + if (options === null || options === void 0 ? void 0 : options.createProxy) { return new Proxy(response, { get(target, prop, receiver) { if (prop === "headers") { @@ -47500,11 +47465,8 @@ function toCompatResponse(response, options) { }); } else { - return { - ...response, - request, - headers, - }; + return Object.assign(Object.assign({}, response), { request, + headers }); } } /** @@ -47520,18 +47482,14 @@ function toPipelineResponse(compatResponse) { return response; } else { - return { - ...compatResponse, - headers, - request: (0, util_js_1.toPipelineRequest)(compatResponse.request), - }; + return Object.assign(Object.assign({}, compatResponse), { headers, request: (0, util_js_1.toPipelineRequest)(compatResponse.request) }); } } //# sourceMappingURL=response.js.map /***/ }), -/***/ 57777: +/***/ 24970: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -47542,7 +47500,7 @@ exports.HttpHeaders = void 0; exports.toPipelineRequest = toPipelineRequest; exports.toWebResourceLike = toWebResourceLike; exports.toHttpHeadersLike = toHttpHeadersLike; -const core_rest_pipeline_1 = __nccwpck_require__(64839); +const core_rest_pipeline_1 = __nccwpck_require__(54786); // We use a custom symbol to cache a reference to the original request without // exposing it on the public interface. const originalRequestSymbol = Symbol("Original PipelineRequest"); @@ -47586,7 +47544,8 @@ function toPipelineRequest(webResource, options = {}) { } } function toWebResourceLike(request, options) { - const originalRequest = options?.originalRequest ?? request; + var _a; + const originalRequest = (_a = options === null || options === void 0 ? void 0 : options.originalRequest) !== null && _a !== void 0 ? _a : request; const webResource = { url: request.url, method: request.method, @@ -47614,7 +47573,7 @@ function toWebResourceLike(request, options) { /** do nothing */ }, }; - if (options?.createProxy) { + if (options === null || options === void 0 ? void 0 : options.createProxy) { return new Proxy(webResource, { get(target, prop, receiver) { if (prop === originalRequestSymbol) { @@ -47680,7 +47639,6 @@ function getHeaderKey(headerName) { * A collection of HTTP header key/value pairs. */ class HttpHeaders { - _headersMap; constructor(rawHeaders) { this._headersMap = {}; if (rawHeaders) { @@ -48984,7 +48942,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true })); exports.buildCreatePoller = void 0; const operation_js_1 = __nccwpck_require__(90804); const constants_js_1 = __nccwpck_require__(52216); -const core_util_1 = __nccwpck_require__(60643); +const core_util_1 = __nccwpck_require__(91276); const createStateProxy = () => ({ /** * The state at this point is created to be of type OperationState. @@ -49154,7 +49112,7 @@ exports.buildCreatePoller = buildCreatePoller; /***/ }), -/***/ 11210: +/***/ 19: /***/ ((__unused_webpack_module, exports) => { @@ -49162,13 +49120,13 @@ exports.buildCreatePoller = buildCreatePoller; // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.DEFAULT_RETRY_POLICY_COUNT = exports.SDK_VERSION = void 0; -exports.SDK_VERSION = "1.22.1"; +exports.SDK_VERSION = "1.22.0"; exports.DEFAULT_RETRY_POLICY_COUNT = 3; //# sourceMappingURL=constants.js.map /***/ }), -/***/ 94603: +/***/ 10582: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -49176,26 +49134,27 @@ exports.DEFAULT_RETRY_POLICY_COUNT = 3; // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.createPipelineFromOptions = createPipelineFromOptions; -const logPolicy_js_1 = __nccwpck_require__(39614); -const pipeline_js_1 = __nccwpck_require__(16365); -const redirectPolicy_js_1 = __nccwpck_require__(16798); -const userAgentPolicy_js_1 = __nccwpck_require__(69072); -const multipartPolicy_js_1 = __nccwpck_require__(79608); -const decompressResponsePolicy_js_1 = __nccwpck_require__(73758); -const defaultRetryPolicy_js_1 = __nccwpck_require__(88135); -const formDataPolicy_js_1 = __nccwpck_require__(66160); -const core_util_1 = __nccwpck_require__(60643); -const proxyPolicy_js_1 = __nccwpck_require__(16236); -const setClientRequestIdPolicy_js_1 = __nccwpck_require__(34275); -const agentPolicy_js_1 = __nccwpck_require__(2845); -const tlsPolicy_js_1 = __nccwpck_require__(34741); -const tracingPolicy_js_1 = __nccwpck_require__(30558); -const wrapAbortSignalLikePolicy_js_1 = __nccwpck_require__(25801); +const logPolicy_js_1 = __nccwpck_require__(84557); +const pipeline_js_1 = __nccwpck_require__(75310); +const redirectPolicy_js_1 = __nccwpck_require__(83871); +const userAgentPolicy_js_1 = __nccwpck_require__(49335); +const multipartPolicy_js_1 = __nccwpck_require__(43879); +const decompressResponsePolicy_js_1 = __nccwpck_require__(16791); +const defaultRetryPolicy_js_1 = __nccwpck_require__(60962); +const formDataPolicy_js_1 = __nccwpck_require__(91201); +const core_util_1 = __nccwpck_require__(91276); +const proxyPolicy_js_1 = __nccwpck_require__(59847); +const setClientRequestIdPolicy_js_1 = __nccwpck_require__(81150); +const agentPolicy_js_1 = __nccwpck_require__(53138); +const tlsPolicy_js_1 = __nccwpck_require__(53230); +const tracingPolicy_js_1 = __nccwpck_require__(25373); +const wrapAbortSignalLikePolicy_js_1 = __nccwpck_require__(15922); /** * Create a new pipeline with a default set of customizable policies. * @param options - Options to configure a custom pipeline. */ function createPipelineFromOptions(options) { + var _a; const pipeline = (0, pipeline_js_1.createEmptyPipeline)(); if (core_util_1.isNodeLike) { if (options.agent) { @@ -49210,13 +49169,13 @@ function createPipelineFromOptions(options) { pipeline.addPolicy((0, wrapAbortSignalLikePolicy_js_1.wrapAbortSignalLikePolicy)()); pipeline.addPolicy((0, formDataPolicy_js_1.formDataPolicy)(), { beforePolicies: [multipartPolicy_js_1.multipartPolicyName] }); pipeline.addPolicy((0, userAgentPolicy_js_1.userAgentPolicy)(options.userAgentOptions)); - pipeline.addPolicy((0, setClientRequestIdPolicy_js_1.setClientRequestIdPolicy)(options.telemetryOptions?.clientRequestIdHeaderName)); + pipeline.addPolicy((0, setClientRequestIdPolicy_js_1.setClientRequestIdPolicy)((_a = options.telemetryOptions) === null || _a === void 0 ? void 0 : _a.clientRequestIdHeaderName)); // The multipart policy is added after policies with no phase, so that // policies can be added between it and formDataPolicy to modify // properties (e.g., making the boundary constant in recorded tests). pipeline.addPolicy((0, multipartPolicy_js_1.multipartPolicy)(), { afterPhase: "Deserialize" }); pipeline.addPolicy((0, defaultRetryPolicy_js_1.defaultRetryPolicy)(options.retryOptions), { phase: "Retry" }); - pipeline.addPolicy((0, tracingPolicy_js_1.tracingPolicy)({ ...options.userAgentOptions, ...options.loggingOptions }), { + pipeline.addPolicy((0, tracingPolicy_js_1.tracingPolicy)(Object.assign(Object.assign({}, options.userAgentOptions), options.loggingOptions)), { afterPhase: "Retry", }); if (core_util_1.isNodeLike) { @@ -49231,7 +49190,7 @@ function createPipelineFromOptions(options) { /***/ }), -/***/ 45445: +/***/ 46896: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -49239,8 +49198,8 @@ function createPipelineFromOptions(options) { // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.createDefaultHttpClient = createDefaultHttpClient; -const ts_http_runtime_1 = __nccwpck_require__(54855); -const wrapAbortSignal_js_1 = __nccwpck_require__(47694); +const ts_http_runtime_1 = __nccwpck_require__(67810); +const wrapAbortSignal_js_1 = __nccwpck_require__(79049); /** * Create the correct HttpClient for the current environment. */ @@ -49259,7 +49218,7 @@ function createDefaultHttpClient() { return await client.sendRequest(request); } finally { - cleanup?.(); + cleanup === null || cleanup === void 0 ? void 0 : cleanup(); } }, }; @@ -49268,7 +49227,7 @@ function createDefaultHttpClient() { /***/ }), -/***/ 65257: +/***/ 18536: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -49276,7 +49235,7 @@ function createDefaultHttpClient() { // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.createHttpHeaders = createHttpHeaders; -const ts_http_runtime_1 = __nccwpck_require__(54855); +const ts_http_runtime_1 = __nccwpck_require__(67810); /** * Creates an object that satisfies the `HttpHeaders` interface. * @param rawHeaders - A simple object representing initial headers @@ -49288,7 +49247,7 @@ function createHttpHeaders(rawHeaders) { /***/ }), -/***/ 64839: +/***/ 54786: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -49296,83 +49255,83 @@ function createHttpHeaders(rawHeaders) { // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.createFileFromStream = exports.createFile = exports.agentPolicyName = exports.agentPolicy = exports.auxiliaryAuthenticationHeaderPolicyName = exports.auxiliaryAuthenticationHeaderPolicy = exports.ndJsonPolicyName = exports.ndJsonPolicy = exports.bearerTokenAuthenticationPolicyName = exports.bearerTokenAuthenticationPolicy = exports.formDataPolicyName = exports.formDataPolicy = exports.tlsPolicyName = exports.tlsPolicy = exports.userAgentPolicyName = exports.userAgentPolicy = exports.defaultRetryPolicy = exports.tracingPolicyName = exports.tracingPolicy = exports.retryPolicy = exports.throttlingRetryPolicyName = exports.throttlingRetryPolicy = exports.systemErrorRetryPolicyName = exports.systemErrorRetryPolicy = exports.redirectPolicyName = exports.redirectPolicy = exports.getDefaultProxySettings = exports.proxyPolicyName = exports.proxyPolicy = exports.multipartPolicyName = exports.multipartPolicy = exports.logPolicyName = exports.logPolicy = exports.setClientRequestIdPolicyName = exports.setClientRequestIdPolicy = exports.exponentialRetryPolicyName = exports.exponentialRetryPolicy = exports.decompressResponsePolicyName = exports.decompressResponsePolicy = exports.isRestError = exports.RestError = exports.createPipelineRequest = exports.createHttpHeaders = exports.createDefaultHttpClient = exports.createPipelineFromOptions = exports.createEmptyPipeline = void 0; -var pipeline_js_1 = __nccwpck_require__(16365); +var pipeline_js_1 = __nccwpck_require__(75310); Object.defineProperty(exports, "createEmptyPipeline", ({ enumerable: true, get: function () { return pipeline_js_1.createEmptyPipeline; } })); -var createPipelineFromOptions_js_1 = __nccwpck_require__(94603); +var createPipelineFromOptions_js_1 = __nccwpck_require__(10582); Object.defineProperty(exports, "createPipelineFromOptions", ({ enumerable: true, get: function () { return createPipelineFromOptions_js_1.createPipelineFromOptions; } })); -var defaultHttpClient_js_1 = __nccwpck_require__(45445); +var defaultHttpClient_js_1 = __nccwpck_require__(46896); Object.defineProperty(exports, "createDefaultHttpClient", ({ enumerable: true, get: function () { return defaultHttpClient_js_1.createDefaultHttpClient; } })); -var httpHeaders_js_1 = __nccwpck_require__(65257); +var httpHeaders_js_1 = __nccwpck_require__(18536); Object.defineProperty(exports, "createHttpHeaders", ({ enumerable: true, get: function () { return httpHeaders_js_1.createHttpHeaders; } })); -var pipelineRequest_js_1 = __nccwpck_require__(89372); +var pipelineRequest_js_1 = __nccwpck_require__(22181); Object.defineProperty(exports, "createPipelineRequest", ({ enumerable: true, get: function () { return pipelineRequest_js_1.createPipelineRequest; } })); -var restError_js_1 = __nccwpck_require__(69867); +var restError_js_1 = __nccwpck_require__(15186); Object.defineProperty(exports, "RestError", ({ enumerable: true, get: function () { return restError_js_1.RestError; } })); Object.defineProperty(exports, "isRestError", ({ enumerable: true, get: function () { return restError_js_1.isRestError; } })); -var decompressResponsePolicy_js_1 = __nccwpck_require__(73758); +var decompressResponsePolicy_js_1 = __nccwpck_require__(16791); Object.defineProperty(exports, "decompressResponsePolicy", ({ enumerable: true, get: function () { return decompressResponsePolicy_js_1.decompressResponsePolicy; } })); Object.defineProperty(exports, "decompressResponsePolicyName", ({ enumerable: true, get: function () { return decompressResponsePolicy_js_1.decompressResponsePolicyName; } })); -var exponentialRetryPolicy_js_1 = __nccwpck_require__(85985); +var exponentialRetryPolicy_js_1 = __nccwpck_require__(72332); Object.defineProperty(exports, "exponentialRetryPolicy", ({ enumerable: true, get: function () { return exponentialRetryPolicy_js_1.exponentialRetryPolicy; } })); Object.defineProperty(exports, "exponentialRetryPolicyName", ({ enumerable: true, get: function () { return exponentialRetryPolicy_js_1.exponentialRetryPolicyName; } })); -var setClientRequestIdPolicy_js_1 = __nccwpck_require__(34275); +var setClientRequestIdPolicy_js_1 = __nccwpck_require__(81150); Object.defineProperty(exports, "setClientRequestIdPolicy", ({ enumerable: true, get: function () { return setClientRequestIdPolicy_js_1.setClientRequestIdPolicy; } })); Object.defineProperty(exports, "setClientRequestIdPolicyName", ({ enumerable: true, get: function () { return setClientRequestIdPolicy_js_1.setClientRequestIdPolicyName; } })); -var logPolicy_js_1 = __nccwpck_require__(39614); +var logPolicy_js_1 = __nccwpck_require__(84557); Object.defineProperty(exports, "logPolicy", ({ enumerable: true, get: function () { return logPolicy_js_1.logPolicy; } })); Object.defineProperty(exports, "logPolicyName", ({ enumerable: true, get: function () { return logPolicy_js_1.logPolicyName; } })); -var multipartPolicy_js_1 = __nccwpck_require__(79608); +var multipartPolicy_js_1 = __nccwpck_require__(43879); Object.defineProperty(exports, "multipartPolicy", ({ enumerable: true, get: function () { return multipartPolicy_js_1.multipartPolicy; } })); Object.defineProperty(exports, "multipartPolicyName", ({ enumerable: true, get: function () { return multipartPolicy_js_1.multipartPolicyName; } })); -var proxyPolicy_js_1 = __nccwpck_require__(16236); +var proxyPolicy_js_1 = __nccwpck_require__(59847); Object.defineProperty(exports, "proxyPolicy", ({ enumerable: true, get: function () { return proxyPolicy_js_1.proxyPolicy; } })); Object.defineProperty(exports, "proxyPolicyName", ({ enumerable: true, get: function () { return proxyPolicy_js_1.proxyPolicyName; } })); Object.defineProperty(exports, "getDefaultProxySettings", ({ enumerable: true, get: function () { return proxyPolicy_js_1.getDefaultProxySettings; } })); -var redirectPolicy_js_1 = __nccwpck_require__(16798); +var redirectPolicy_js_1 = __nccwpck_require__(83871); Object.defineProperty(exports, "redirectPolicy", ({ enumerable: true, get: function () { return redirectPolicy_js_1.redirectPolicy; } })); Object.defineProperty(exports, "redirectPolicyName", ({ enumerable: true, get: function () { return redirectPolicy_js_1.redirectPolicyName; } })); -var systemErrorRetryPolicy_js_1 = __nccwpck_require__(67655); +var systemErrorRetryPolicy_js_1 = __nccwpck_require__(41374); Object.defineProperty(exports, "systemErrorRetryPolicy", ({ enumerable: true, get: function () { return systemErrorRetryPolicy_js_1.systemErrorRetryPolicy; } })); Object.defineProperty(exports, "systemErrorRetryPolicyName", ({ enumerable: true, get: function () { return systemErrorRetryPolicy_js_1.systemErrorRetryPolicyName; } })); -var throttlingRetryPolicy_js_1 = __nccwpck_require__(63663); +var throttlingRetryPolicy_js_1 = __nccwpck_require__(6444); Object.defineProperty(exports, "throttlingRetryPolicy", ({ enumerable: true, get: function () { return throttlingRetryPolicy_js_1.throttlingRetryPolicy; } })); Object.defineProperty(exports, "throttlingRetryPolicyName", ({ enumerable: true, get: function () { return throttlingRetryPolicy_js_1.throttlingRetryPolicyName; } })); -var retryPolicy_js_1 = __nccwpck_require__(22526); +var retryPolicy_js_1 = __nccwpck_require__(16269); Object.defineProperty(exports, "retryPolicy", ({ enumerable: true, get: function () { return retryPolicy_js_1.retryPolicy; } })); -var tracingPolicy_js_1 = __nccwpck_require__(30558); +var tracingPolicy_js_1 = __nccwpck_require__(25373); Object.defineProperty(exports, "tracingPolicy", ({ enumerable: true, get: function () { return tracingPolicy_js_1.tracingPolicy; } })); Object.defineProperty(exports, "tracingPolicyName", ({ enumerable: true, get: function () { return tracingPolicy_js_1.tracingPolicyName; } })); -var defaultRetryPolicy_js_1 = __nccwpck_require__(88135); +var defaultRetryPolicy_js_1 = __nccwpck_require__(60962); Object.defineProperty(exports, "defaultRetryPolicy", ({ enumerable: true, get: function () { return defaultRetryPolicy_js_1.defaultRetryPolicy; } })); -var userAgentPolicy_js_1 = __nccwpck_require__(69072); +var userAgentPolicy_js_1 = __nccwpck_require__(49335); Object.defineProperty(exports, "userAgentPolicy", ({ enumerable: true, get: function () { return userAgentPolicy_js_1.userAgentPolicy; } })); Object.defineProperty(exports, "userAgentPolicyName", ({ enumerable: true, get: function () { return userAgentPolicy_js_1.userAgentPolicyName; } })); -var tlsPolicy_js_1 = __nccwpck_require__(34741); +var tlsPolicy_js_1 = __nccwpck_require__(53230); Object.defineProperty(exports, "tlsPolicy", ({ enumerable: true, get: function () { return tlsPolicy_js_1.tlsPolicy; } })); Object.defineProperty(exports, "tlsPolicyName", ({ enumerable: true, get: function () { return tlsPolicy_js_1.tlsPolicyName; } })); -var formDataPolicy_js_1 = __nccwpck_require__(66160); +var formDataPolicy_js_1 = __nccwpck_require__(91201); Object.defineProperty(exports, "formDataPolicy", ({ enumerable: true, get: function () { return formDataPolicy_js_1.formDataPolicy; } })); Object.defineProperty(exports, "formDataPolicyName", ({ enumerable: true, get: function () { return formDataPolicy_js_1.formDataPolicyName; } })); -var bearerTokenAuthenticationPolicy_js_1 = __nccwpck_require__(95782); +var bearerTokenAuthenticationPolicy_js_1 = __nccwpck_require__(13733); Object.defineProperty(exports, "bearerTokenAuthenticationPolicy", ({ enumerable: true, get: function () { return bearerTokenAuthenticationPolicy_js_1.bearerTokenAuthenticationPolicy; } })); Object.defineProperty(exports, "bearerTokenAuthenticationPolicyName", ({ enumerable: true, get: function () { return bearerTokenAuthenticationPolicy_js_1.bearerTokenAuthenticationPolicyName; } })); -var ndJsonPolicy_js_1 = __nccwpck_require__(99866); +var ndJsonPolicy_js_1 = __nccwpck_require__(90227); Object.defineProperty(exports, "ndJsonPolicy", ({ enumerable: true, get: function () { return ndJsonPolicy_js_1.ndJsonPolicy; } })); Object.defineProperty(exports, "ndJsonPolicyName", ({ enumerable: true, get: function () { return ndJsonPolicy_js_1.ndJsonPolicyName; } })); -var auxiliaryAuthenticationHeaderPolicy_js_1 = __nccwpck_require__(12861); +var auxiliaryAuthenticationHeaderPolicy_js_1 = __nccwpck_require__(41566); Object.defineProperty(exports, "auxiliaryAuthenticationHeaderPolicy", ({ enumerable: true, get: function () { return auxiliaryAuthenticationHeaderPolicy_js_1.auxiliaryAuthenticationHeaderPolicy; } })); Object.defineProperty(exports, "auxiliaryAuthenticationHeaderPolicyName", ({ enumerable: true, get: function () { return auxiliaryAuthenticationHeaderPolicy_js_1.auxiliaryAuthenticationHeaderPolicyName; } })); -var agentPolicy_js_1 = __nccwpck_require__(2845); +var agentPolicy_js_1 = __nccwpck_require__(53138); Object.defineProperty(exports, "agentPolicy", ({ enumerable: true, get: function () { return agentPolicy_js_1.agentPolicy; } })); Object.defineProperty(exports, "agentPolicyName", ({ enumerable: true, get: function () { return agentPolicy_js_1.agentPolicyName; } })); -var file_js_1 = __nccwpck_require__(13168); +var file_js_1 = __nccwpck_require__(99273); Object.defineProperty(exports, "createFile", ({ enumerable: true, get: function () { return file_js_1.createFile; } })); Object.defineProperty(exports, "createFileFromStream", ({ enumerable: true, get: function () { return file_js_1.createFileFromStream; } })); //# sourceMappingURL=index.js.map /***/ }), -/***/ 51449: +/***/ 43016: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -49386,7 +49345,7 @@ exports.logger = (0, logger_1.createClientLogger)("core-rest-pipeline"); /***/ }), -/***/ 16365: +/***/ 75310: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -49394,7 +49353,7 @@ exports.logger = (0, logger_1.createClientLogger)("core-rest-pipeline"); // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.createEmptyPipeline = createEmptyPipeline; -const ts_http_runtime_1 = __nccwpck_require__(54855); +const ts_http_runtime_1 = __nccwpck_require__(67810); /** * Creates a totally empty pipeline. * Useful for testing or creating a custom one. @@ -49406,7 +49365,7 @@ function createEmptyPipeline() { /***/ }), -/***/ 89372: +/***/ 22181: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -49414,7 +49373,7 @@ function createEmptyPipeline() { // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.createPipelineRequest = createPipelineRequest; -const ts_http_runtime_1 = __nccwpck_require__(54855); +const ts_http_runtime_1 = __nccwpck_require__(67810); /** * Creates a new pipeline request with the given options. * This method is to allow for the easy setting of default values and not required. @@ -49430,7 +49389,7 @@ function createPipelineRequest(options) { /***/ }), -/***/ 2845: +/***/ 53138: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -49439,7 +49398,7 @@ function createPipelineRequest(options) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.agentPolicyName = void 0; exports.agentPolicy = agentPolicy; -const policies_1 = __nccwpck_require__(37717); +const policies_1 = __nccwpck_require__(25068); /** * Name of the Agent Policy */ @@ -49454,7 +49413,7 @@ function agentPolicy(agent) { /***/ }), -/***/ 12861: +/***/ 41566: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -49463,20 +49422,21 @@ function agentPolicy(agent) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.auxiliaryAuthenticationHeaderPolicyName = void 0; exports.auxiliaryAuthenticationHeaderPolicy = auxiliaryAuthenticationHeaderPolicy; -const tokenCycler_js_1 = __nccwpck_require__(86389); -const log_js_1 = __nccwpck_require__(51449); +const tokenCycler_js_1 = __nccwpck_require__(59130); +const log_js_1 = __nccwpck_require__(43016); /** * The programmatic identifier of the auxiliaryAuthenticationHeaderPolicy. */ exports.auxiliaryAuthenticationHeaderPolicyName = "auxiliaryAuthenticationHeaderPolicy"; const AUTHORIZATION_AUXILIARY_HEADER = "x-ms-authorization-auxiliary"; async function sendAuthorizeRequest(options) { + var _a, _b; const { scopes, getAccessToken, request } = options; const getTokenOptions = { abortSignal: request.abortSignal, tracingOptions: request.tracingOptions, }; - return (await getAccessToken(scopes, getTokenOptions))?.token ?? ""; + return (_b = (_a = (await getAccessToken(scopes, getTokenOptions))) === null || _a === void 0 ? void 0 : _a.token) !== null && _b !== void 0 ? _b : ""; } /** * A policy for external tokens to `x-ms-authorization-auxiliary` header. @@ -49526,7 +49486,7 @@ function auxiliaryAuthenticationHeaderPolicy(options) { /***/ }), -/***/ 95782: +/***/ 13733: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -49536,9 +49496,9 @@ Object.defineProperty(exports, "__esModule", ({ value: true })); exports.bearerTokenAuthenticationPolicyName = void 0; exports.bearerTokenAuthenticationPolicy = bearerTokenAuthenticationPolicy; exports.parseChallenges = parseChallenges; -const tokenCycler_js_1 = __nccwpck_require__(86389); -const log_js_1 = __nccwpck_require__(51449); -const restError_js_1 = __nccwpck_require__(69867); +const tokenCycler_js_1 = __nccwpck_require__(59130); +const log_js_1 = __nccwpck_require__(43016); +const restError_js_1 = __nccwpck_require__(15186); /** * The programmatic identifier of the bearerTokenAuthenticationPolicy. */ @@ -49594,6 +49554,7 @@ function isChallengeResponse(response) { * If this method returns true, the underlying request will be sent once again. */ async function authorizeRequestOnCaeChallenge(onChallengeOptions, caeClaims) { + var _a; const { scopes } = onChallengeOptions; const accessToken = await onChallengeOptions.getAccessToken(scopes, { enableCae: true, @@ -49602,7 +49563,7 @@ async function authorizeRequestOnCaeChallenge(onChallengeOptions, caeClaims) { if (!accessToken) { return false; } - onChallengeOptions.request.headers.set("Authorization", `${accessToken.tokenType ?? "Bearer"} ${accessToken.token}`); + onChallengeOptions.request.headers.set("Authorization", `${(_a = accessToken.tokenType) !== null && _a !== void 0 ? _a : "Bearer"} ${accessToken.token}`); return true; } /** @@ -49610,11 +49571,12 @@ async function authorizeRequestOnCaeChallenge(onChallengeOptions, caeClaims) { * then apply it to the Authorization header of a request as a Bearer token. */ function bearerTokenAuthenticationPolicy(options) { + var _a, _b, _c; const { credential, scopes, challengeCallbacks } = options; const logger = options.logger || log_js_1.logger; const callbacks = { - authorizeRequest: challengeCallbacks?.authorizeRequest?.bind(challengeCallbacks) ?? defaultAuthorizeRequest, - authorizeRequestOnChallenge: challengeCallbacks?.authorizeRequestOnChallenge?.bind(challengeCallbacks), + authorizeRequest: (_b = (_a = challengeCallbacks === null || challengeCallbacks === void 0 ? void 0 : challengeCallbacks.authorizeRequest) === null || _a === void 0 ? void 0 : _a.bind(challengeCallbacks)) !== null && _b !== void 0 ? _b : defaultAuthorizeRequest, + authorizeRequestOnChallenge: (_c = challengeCallbacks === null || challengeCallbacks === void 0 ? void 0 : challengeCallbacks.authorizeRequestOnChallenge) === null || _c === void 0 ? void 0 : _c.bind(challengeCallbacks), }; // This function encapsulates the entire process of reliably retrieving the token // The options are left out of the public API until there's demand to configure this. @@ -49761,18 +49723,19 @@ function parseChallenges(challenges) { * @internal */ function getCaeChallengeClaims(challenges) { + var _a; if (!challenges) { return; } // Find all challenges present in the header const parsedChallenges = parseChallenges(challenges); - return parsedChallenges.find((x) => x.scheme === "Bearer" && x.params.claims && x.params.error === "insufficient_claims")?.params.claims; + return (_a = parsedChallenges.find((x) => x.scheme === "Bearer" && x.params.claims && x.params.error === "insufficient_claims")) === null || _a === void 0 ? void 0 : _a.params.claims; } //# sourceMappingURL=bearerTokenAuthenticationPolicy.js.map /***/ }), -/***/ 73758: +/***/ 16791: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -49781,7 +49744,7 @@ function getCaeChallengeClaims(challenges) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.decompressResponsePolicyName = void 0; exports.decompressResponsePolicy = decompressResponsePolicy; -const policies_1 = __nccwpck_require__(37717); +const policies_1 = __nccwpck_require__(25068); /** * The programmatic identifier of the decompressResponsePolicy. */ @@ -49797,7 +49760,7 @@ function decompressResponsePolicy() { /***/ }), -/***/ 88135: +/***/ 60962: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -49806,7 +49769,7 @@ function decompressResponsePolicy() { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.defaultRetryPolicyName = void 0; exports.defaultRetryPolicy = defaultRetryPolicy; -const policies_1 = __nccwpck_require__(37717); +const policies_1 = __nccwpck_require__(25068); /** * Name of the {@link defaultRetryPolicy} */ @@ -49824,7 +49787,7 @@ function defaultRetryPolicy(options = {}) { /***/ }), -/***/ 85985: +/***/ 72332: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -49833,7 +49796,7 @@ function defaultRetryPolicy(options = {}) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.exponentialRetryPolicyName = void 0; exports.exponentialRetryPolicy = exponentialRetryPolicy; -const policies_1 = __nccwpck_require__(37717); +const policies_1 = __nccwpck_require__(25068); /** * The programmatic identifier of the exponentialRetryPolicy. */ @@ -49849,7 +49812,7 @@ function exponentialRetryPolicy(options = {}) { /***/ }), -/***/ 66160: +/***/ 91201: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -49858,7 +49821,7 @@ function exponentialRetryPolicy(options = {}) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.formDataPolicyName = void 0; exports.formDataPolicy = formDataPolicy; -const policies_1 = __nccwpck_require__(37717); +const policies_1 = __nccwpck_require__(25068); /** * The programmatic identifier of the formDataPolicy. */ @@ -49873,7 +49836,7 @@ function formDataPolicy() { /***/ }), -/***/ 39614: +/***/ 84557: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -49882,8 +49845,8 @@ function formDataPolicy() { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.logPolicyName = void 0; exports.logPolicy = logPolicy; -const log_js_1 = __nccwpck_require__(51449); -const policies_1 = __nccwpck_require__(37717); +const log_js_1 = __nccwpck_require__(43016); +const policies_1 = __nccwpck_require__(25068); /** * The programmatic identifier of the logPolicy. */ @@ -49893,16 +49856,13 @@ exports.logPolicyName = policies_1.logPolicyName; * @param options - Options to configure logPolicy. */ function logPolicy(options = {}) { - return (0, policies_1.logPolicy)({ - logger: log_js_1.logger.info, - ...options, - }); + return (0, policies_1.logPolicy)(Object.assign({ logger: log_js_1.logger.info }, options)); } //# sourceMappingURL=logPolicy.js.map /***/ }), -/***/ 79608: +/***/ 43879: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -49911,8 +49871,8 @@ function logPolicy(options = {}) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.multipartPolicyName = void 0; exports.multipartPolicy = multipartPolicy; -const policies_1 = __nccwpck_require__(37717); -const file_js_1 = __nccwpck_require__(13168); +const policies_1 = __nccwpck_require__(25068); +const file_js_1 = __nccwpck_require__(99273); /** * Name of multipart policy */ @@ -49940,7 +49900,7 @@ function multipartPolicy() { /***/ }), -/***/ 99866: +/***/ 90227: /***/ ((__unused_webpack_module, exports) => { @@ -49975,7 +49935,7 @@ function ndJsonPolicy() { /***/ }), -/***/ 16236: +/***/ 59847: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -49985,7 +49945,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true })); exports.proxyPolicyName = void 0; exports.getDefaultProxySettings = getDefaultProxySettings; exports.proxyPolicy = proxyPolicy; -const policies_1 = __nccwpck_require__(37717); +const policies_1 = __nccwpck_require__(25068); /** * The programmatic identifier of the proxyPolicy. */ @@ -50014,7 +49974,7 @@ function proxyPolicy(proxySettings, options) { /***/ }), -/***/ 16798: +/***/ 83871: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -50023,7 +49983,7 @@ function proxyPolicy(proxySettings, options) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.redirectPolicyName = void 0; exports.redirectPolicy = redirectPolicy; -const policies_1 = __nccwpck_require__(37717); +const policies_1 = __nccwpck_require__(25068); /** * The programmatic identifier of the redirectPolicy. */ @@ -50041,7 +50001,7 @@ function redirectPolicy(options = {}) { /***/ }), -/***/ 22526: +/***/ 16269: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -50050,8 +50010,8 @@ function redirectPolicy(options = {}) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.retryPolicy = retryPolicy; const logger_1 = __nccwpck_require__(42549); -const constants_js_1 = __nccwpck_require__(11210); -const policies_1 = __nccwpck_require__(37717); +const constants_js_1 = __nccwpck_require__(19); +const policies_1 = __nccwpck_require__(25068); const retryPolicyLogger = (0, logger_1.createClientLogger)("core-rest-pipeline retryPolicy"); /** * retryPolicy is a generic policy to enable retrying requests when certain conditions are met @@ -50060,16 +50020,13 @@ function retryPolicy(strategies, options = { maxRetries: constants_js_1.DEFAULT_ // Cast is required since the TSP runtime retry strategy type is slightly different // very deep down (using real AbortSignal vs. AbortSignalLike in RestError). // In practice the difference doesn't actually matter. - return (0, policies_1.retryPolicy)(strategies, { - logger: retryPolicyLogger, - ...options, - }); + return (0, policies_1.retryPolicy)(strategies, Object.assign({ logger: retryPolicyLogger }, options)); } //# sourceMappingURL=retryPolicy.js.map /***/ }), -/***/ 34275: +/***/ 81150: /***/ ((__unused_webpack_module, exports) => { @@ -50103,7 +50060,7 @@ function setClientRequestIdPolicy(requestIdHeaderName = "x-ms-client-request-id" /***/ }), -/***/ 67655: +/***/ 41374: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -50112,7 +50069,7 @@ function setClientRequestIdPolicy(requestIdHeaderName = "x-ms-client-request-id" Object.defineProperty(exports, "__esModule", ({ value: true })); exports.systemErrorRetryPolicyName = void 0; exports.systemErrorRetryPolicy = systemErrorRetryPolicy; -const policies_1 = __nccwpck_require__(37717); +const policies_1 = __nccwpck_require__(25068); /** * Name of the {@link systemErrorRetryPolicy} */ @@ -50130,7 +50087,7 @@ function systemErrorRetryPolicy(options = {}) { /***/ }), -/***/ 63663: +/***/ 6444: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -50139,7 +50096,7 @@ function systemErrorRetryPolicy(options = {}) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.throttlingRetryPolicyName = void 0; exports.throttlingRetryPolicy = throttlingRetryPolicy; -const policies_1 = __nccwpck_require__(37717); +const policies_1 = __nccwpck_require__(25068); /** * Name of the {@link throttlingRetryPolicy} */ @@ -50161,7 +50118,7 @@ function throttlingRetryPolicy(options = {}) { /***/ }), -/***/ 34741: +/***/ 53230: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -50170,7 +50127,7 @@ function throttlingRetryPolicy(options = {}) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.tlsPolicyName = void 0; exports.tlsPolicy = tlsPolicy; -const policies_1 = __nccwpck_require__(37717); +const policies_1 = __nccwpck_require__(25068); /** * Name of the TLS Policy */ @@ -50185,7 +50142,7 @@ function tlsPolicy(tlsSettings) { /***/ }), -/***/ 30558: +/***/ 25373: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -50194,13 +50151,13 @@ function tlsPolicy(tlsSettings) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.tracingPolicyName = void 0; exports.tracingPolicy = tracingPolicy; -const core_tracing_1 = __nccwpck_require__(78168); -const constants_js_1 = __nccwpck_require__(11210); -const userAgent_js_1 = __nccwpck_require__(52476); -const log_js_1 = __nccwpck_require__(51449); -const core_util_1 = __nccwpck_require__(60643); -const restError_js_1 = __nccwpck_require__(69867); -const util_1 = __nccwpck_require__(56759); +const core_tracing_1 = __nccwpck_require__(92245); +const constants_js_1 = __nccwpck_require__(19); +const userAgent_js_1 = __nccwpck_require__(21127); +const log_js_1 = __nccwpck_require__(43016); +const core_util_1 = __nccwpck_require__(91276); +const restError_js_1 = __nccwpck_require__(15186); +const util_1 = __nccwpck_require__(37954); /** * The programmatic identifier of the tracingPolicy. */ @@ -50220,6 +50177,7 @@ function tracingPolicy(options = {}) { return { name: exports.tracingPolicyName, async sendRequest(request, next) { + var _a; if (!tracingClient) { return next(request); } @@ -50233,7 +50191,7 @@ function tracingPolicy(options = {}) { if (userAgent) { spanAttributes["http.user_agent"] = userAgent; } - const { span, tracingContext } = tryCreateSpan(tracingClient, request, spanAttributes) ?? {}; + const { span, tracingContext } = (_a = tryCreateSpan(tracingClient, request, spanAttributes)) !== null && _a !== void 0 ? _a : {}; if (!span || !tracingContext) { return next(request); } @@ -50326,7 +50284,7 @@ function tryProcessResponse(span, response) { /***/ }), -/***/ 69072: +/***/ 49335: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -50335,7 +50293,7 @@ function tryProcessResponse(span, response) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.userAgentPolicyName = void 0; exports.userAgentPolicy = userAgentPolicy; -const userAgent_js_1 = __nccwpck_require__(52476); +const userAgent_js_1 = __nccwpck_require__(21127); const UserAgentHeaderName = (0, userAgent_js_1.getUserAgentHeaderName)(); /** * The programmatic identifier of the userAgentPolicy. @@ -50362,7 +50320,7 @@ function userAgentPolicy(options = {}) { /***/ }), -/***/ 25801: +/***/ 15922: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -50371,7 +50329,7 @@ function userAgentPolicy(options = {}) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.wrapAbortSignalLikePolicyName = void 0; exports.wrapAbortSignalLikePolicy = wrapAbortSignalLikePolicy; -const wrapAbortSignal_js_1 = __nccwpck_require__(47694); +const wrapAbortSignal_js_1 = __nccwpck_require__(79049); exports.wrapAbortSignalLikePolicyName = "wrapAbortSignalLikePolicy"; /** * Policy that ensure that any AbortSignalLike is wrapped in a native AbortSignal for processing by the pipeline. @@ -50393,7 +50351,7 @@ function wrapAbortSignalLikePolicy() { return await next(request); } finally { - cleanup?.(); + cleanup === null || cleanup === void 0 ? void 0 : cleanup(); } }, }; @@ -50402,7 +50360,7 @@ function wrapAbortSignalLikePolicy() { /***/ }), -/***/ 69867: +/***/ 15186: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -50411,7 +50369,7 @@ function wrapAbortSignalLikePolicy() { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.RestError = void 0; exports.isRestError = isRestError; -const ts_http_runtime_1 = __nccwpck_require__(54855); +const ts_http_runtime_1 = __nccwpck_require__(67810); /** * A custom error type for failed pipeline requests. */ @@ -50428,7 +50386,7 @@ function isRestError(e) { /***/ }), -/***/ 13168: +/***/ 99273: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -50439,7 +50397,7 @@ exports.hasRawContent = hasRawContent; exports.getRawContent = getRawContent; exports.createFileFromStream = createFileFromStream; exports.createFile = createFile; -const core_util_1 = __nccwpck_require__(60643); +const core_util_1 = __nccwpck_require__(91276); function isNodeReadableStream(x) { return Boolean(x && typeof x["pipe"] === "function"); } @@ -50511,22 +50469,14 @@ function getRawContent(blob) { * @param options - optional metadata about the file, e.g. file name, file size, MIME type. */ function createFileFromStream(stream, name, options = {}) { - return { - ...unimplementedMethods, - type: options.type ?? "", - lastModified: options.lastModified ?? new Date().getTime(), - webkitRelativePath: options.webkitRelativePath ?? "", - size: options.size ?? -1, - name, - stream: () => { + var _a, _b, _c, _d; + return Object.assign(Object.assign({}, unimplementedMethods), { type: (_a = options.type) !== null && _a !== void 0 ? _a : "", lastModified: (_b = options.lastModified) !== null && _b !== void 0 ? _b : new Date().getTime(), webkitRelativePath: (_c = options.webkitRelativePath) !== null && _c !== void 0 ? _c : "", size: (_d = options.size) !== null && _d !== void 0 ? _d : -1, name, stream: () => { const s = stream(); if (isNodeReadableStream(s)) { throw new Error("Not supported: a Node stream was provided as input to createFileFromStream."); } return s; - }, - [rawContent]: stream, - }; + }, [rawContent]: stream }); } /** * Create an object that implements the File interface. This object is intended to be @@ -50540,18 +50490,9 @@ function createFileFromStream(stream, name, options = {}) { * @param options - optional metadata about the file, e.g. file name, file size, MIME type. */ function createFile(content, name, options = {}) { + var _a, _b, _c; if (core_util_1.isNodeLike) { - return { - ...unimplementedMethods, - type: options.type ?? "", - lastModified: options.lastModified ?? new Date().getTime(), - webkitRelativePath: options.webkitRelativePath ?? "", - size: content.byteLength, - name, - arrayBuffer: async () => content.buffer, - stream: () => new Blob([content]).stream(), - [rawContent]: () => content, - }; + return Object.assign(Object.assign({}, unimplementedMethods), { type: (_a = options.type) !== null && _a !== void 0 ? _a : "", lastModified: (_b = options.lastModified) !== null && _b !== void 0 ? _b : new Date().getTime(), webkitRelativePath: (_c = options.webkitRelativePath) !== null && _c !== void 0 ? _c : "", size: content.byteLength, name, arrayBuffer: async () => content.buffer, stream: () => new Blob([content]).stream(), [rawContent]: () => content }); } else { return new File([content], name, options); @@ -50561,7 +50502,7 @@ function createFile(content, name, options = {}) { /***/ }), -/***/ 86389: +/***/ 59130: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -50570,7 +50511,7 @@ function createFile(content, name, options = {}) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.DEFAULT_CYCLER_OPTIONS = void 0; exports.createTokenCycler = createTokenCycler; -const core_util_1 = __nccwpck_require__(60643); +const core_util_1 = __nccwpck_require__(91276); // Default options for the cycler if none are provided exports.DEFAULT_CYCLER_OPTIONS = { forcedRefreshWindowInMs: 1000, // Force waiting for a refresh 1s before the token expires @@ -50595,7 +50536,7 @@ async function beginRefresh(getAccessToken, retryIntervalInMs, refreshTimeout) { try { return await getAccessToken(); } - catch { + catch (_a) { return null; } } @@ -50633,10 +50574,7 @@ function createTokenCycler(credential, tokenCyclerOptions) { let refreshWorker = null; let token = null; let tenantId; - const options = { - ...exports.DEFAULT_CYCLER_OPTIONS, - ...tokenCyclerOptions, - }; + const options = Object.assign(Object.assign({}, exports.DEFAULT_CYCLER_OPTIONS), tokenCyclerOptions); /** * This little holder defines several predicates that we use to construct * the rules of refreshing the token. @@ -50653,13 +50591,14 @@ function createTokenCycler(credential, tokenCyclerOptions) { * window and not already refreshing) */ get shouldRefresh() { + var _a; if (cycler.isRefreshing) { return false; } - if (token?.refreshAfterTimestamp && token.refreshAfterTimestamp < Date.now()) { + if ((token === null || token === void 0 ? void 0 : token.refreshAfterTimestamp) && token.refreshAfterTimestamp < Date.now()) { return true; } - return (token?.expiresOnTimestamp ?? 0) - options.refreshWindowInMs < Date.now(); + return ((_a = token === null || token === void 0 ? void 0 : token.expiresOnTimestamp) !== null && _a !== void 0 ? _a : 0) - options.refreshWindowInMs < Date.now(); }, /** * Produces true if the cycler MUST refresh (null or nearly-expired @@ -50674,6 +50613,7 @@ function createTokenCycler(credential, tokenCyclerOptions) { * running. */ function refresh(scopes, getTokenOptions) { + var _a; if (!cycler.isRefreshing) { // We bind `scopes` here to avoid passing it around a lot const tryGetAccessToken = () => credential.getToken(scopes, getTokenOptions); @@ -50681,7 +50621,7 @@ function createTokenCycler(credential, tokenCyclerOptions) { // before the refresh can be considered done. refreshWorker = beginRefresh(tryGetAccessToken, options.retryIntervalInMs, // If we don't have a token, then we should timeout immediately - token?.expiresOnTimestamp ?? Date.now()) + (_a = token === null || token === void 0 ? void 0 : token.expiresOnTimestamp) !== null && _a !== void 0 ? _a : Date.now()) .then((_token) => { refreshWorker = null; token = _token; @@ -50734,7 +50674,7 @@ function createTokenCycler(credential, tokenCyclerOptions) { /***/ }), -/***/ 52476: +/***/ 21127: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -50743,8 +50683,8 @@ function createTokenCycler(credential, tokenCyclerOptions) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.getUserAgentHeaderName = getUserAgentHeaderName; exports.getUserAgentValue = getUserAgentValue; -const userAgentPlatform_js_1 = __nccwpck_require__(11351); -const constants_js_1 = __nccwpck_require__(11210); +const userAgentPlatform_js_1 = __nccwpck_require__(98672); +const constants_js_1 = __nccwpck_require__(19); function getUserAgentString(telemetryInfo) { const parts = []; for (const [key, value] of telemetryInfo) { @@ -50774,7 +50714,7 @@ async function getUserAgentValue(prefix) { /***/ }), -/***/ 11351: +/***/ 98672: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -50784,8 +50724,8 @@ Object.defineProperty(exports, "__esModule", ({ value: true })); exports.getHeaderName = getHeaderName; exports.setPlatformSpecificData = setPlatformSpecificData; const tslib_1 = __nccwpck_require__(31577); -const node_os_1 = tslib_1.__importDefault(__nccwpck_require__(48161)); -const node_process_1 = tslib_1.__importDefault(__nccwpck_require__(1708)); +const os = tslib_1.__importStar(__nccwpck_require__(48161)); +const process = tslib_1.__importStar(__nccwpck_require__(1708)); /** * @internal */ @@ -50796,8 +50736,8 @@ function getHeaderName() { * @internal */ async function setPlatformSpecificData(map) { - if (node_process_1.default && node_process_1.default.versions) { - const versions = node_process_1.default.versions; + if (process && process.versions) { + const versions = process.versions; if (versions.bun) { map.set("Bun", versions.bun); } @@ -50808,13 +50748,13 @@ async function setPlatformSpecificData(map) { map.set("Node", versions.node); } } - map.set("OS", `(${node_os_1.default.arch()}-${node_os_1.default.type()}-${node_os_1.default.release()})`); + map.set("OS", `(${os.arch()}-${os.type()}-${os.release()})`); } //# sourceMappingURL=userAgentPlatform.js.map /***/ }), -/***/ 47694: +/***/ 79049: /***/ ((__unused_webpack_module, exports) => { @@ -50854,7 +50794,7 @@ function wrapAbortSignalLike(abortSignalLike) { /***/ }), -/***/ 78168: +/***/ 92245: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -50862,15 +50802,15 @@ function wrapAbortSignalLike(abortSignalLike) { // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.createTracingClient = exports.useInstrumenter = void 0; -var instrumenter_js_1 = __nccwpck_require__(93068); +var instrumenter_js_1 = __nccwpck_require__(84939); Object.defineProperty(exports, "useInstrumenter", ({ enumerable: true, get: function () { return instrumenter_js_1.useInstrumenter; } })); -var tracingClient_js_1 = __nccwpck_require__(44509); +var tracingClient_js_1 = __nccwpck_require__(63960); Object.defineProperty(exports, "createTracingClient", ({ enumerable: true, get: function () { return tracingClient_js_1.createTracingClient; } })); //# sourceMappingURL=index.js.map /***/ }), -/***/ 93068: +/***/ 84939: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -50881,8 +50821,8 @@ exports.createDefaultTracingSpan = createDefaultTracingSpan; exports.createDefaultInstrumenter = createDefaultInstrumenter; exports.useInstrumenter = useInstrumenter; exports.getInstrumenter = getInstrumenter; -const tracingContext_js_1 = __nccwpck_require__(51047); -const state_js_1 = __nccwpck_require__(55145); +const tracingContext_js_1 = __nccwpck_require__(57428); +const state_js_1 = __nccwpck_require__(19016); function createDefaultTracingSpan() { return { end: () => { @@ -50945,7 +50885,7 @@ function getInstrumenter() { /***/ }), -/***/ 55145: +/***/ 19016: /***/ ((__unused_webpack_module, exports) => { @@ -50965,7 +50905,7 @@ exports.state = { /***/ }), -/***/ 44509: +/***/ 63960: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -50973,8 +50913,8 @@ exports.state = { // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.createTracingClient = createTracingClient; -const instrumenter_js_1 = __nccwpck_require__(93068); -const tracingContext_js_1 = __nccwpck_require__(51047); +const instrumenter_js_1 = __nccwpck_require__(84939); +const tracingContext_js_1 = __nccwpck_require__(57428); /** * Creates a new tracing client. * @@ -50984,12 +50924,8 @@ const tracingContext_js_1 = __nccwpck_require__(51047); function createTracingClient(options) { const { namespace, packageName, packageVersion } = options; function startSpan(name, operationOptions, spanOptions) { - const startSpanResult = (0, instrumenter_js_1.getInstrumenter)().startSpan(name, { - ...spanOptions, - packageName: packageName, - packageVersion: packageVersion, - tracingContext: operationOptions?.tracingOptions?.tracingContext, - }); + var _a; + const startSpanResult = (0, instrumenter_js_1.getInstrumenter)().startSpan(name, Object.assign(Object.assign({}, spanOptions), { packageName: packageName, packageVersion: packageVersion, tracingContext: (_a = operationOptions === null || operationOptions === void 0 ? void 0 : operationOptions.tracingOptions) === null || _a === void 0 ? void 0 : _a.tracingContext })); let tracingContext = startSpanResult.tracingContext; const span = startSpanResult.span; if (!tracingContext.getValue(tracingContext_js_1.knownContextKeys.namespace)) { @@ -50997,7 +50933,7 @@ function createTracingClient(options) { } span.setAttribute("az.namespace", tracingContext.getValue(tracingContext_js_1.knownContextKeys.namespace)); const updatedOptions = Object.assign({}, operationOptions, { - tracingOptions: { ...operationOptions?.tracingOptions, tracingContext }, + tracingOptions: Object.assign(Object.assign({}, operationOptions === null || operationOptions === void 0 ? void 0 : operationOptions.tracingOptions), { tracingContext }), }); return { span, @@ -51052,7 +50988,7 @@ function createTracingClient(options) { /***/ }), -/***/ 51047: +/***/ 57428: /***/ ((__unused_webpack_module, exports) => { @@ -51085,7 +51021,6 @@ function createTracingContext(options = {}) { } /** @internal */ class TracingContextImpl { - _contextMap; constructor(initialContext) { this._contextMap = initialContext instanceof TracingContextImpl @@ -51111,7 +51046,7 @@ exports.TracingContextImpl = TracingContextImpl; /***/ }), -/***/ 67145: +/***/ 64904: /***/ ((__unused_webpack_module, exports) => { @@ -51123,24 +51058,25 @@ exports.cancelablePromiseRace = cancelablePromiseRace; * promise.race() wrapper that aborts rest of promises as soon as the first promise settles. */ async function cancelablePromiseRace(abortablePromiseBuilders, options) { + var _a, _b; const aborter = new AbortController(); function abortHandler() { aborter.abort(); } - options?.abortSignal?.addEventListener("abort", abortHandler); + (_a = options === null || options === void 0 ? void 0 : options.abortSignal) === null || _a === void 0 ? void 0 : _a.addEventListener("abort", abortHandler); try { return await Promise.race(abortablePromiseBuilders.map((p) => p({ abortSignal: aborter.signal }))); } finally { aborter.abort(); - options?.abortSignal?.removeEventListener("abort", abortHandler); + (_b = options === null || options === void 0 ? void 0 : options.abortSignal) === null || _b === void 0 ? void 0 : _b.removeEventListener("abort", abortHandler); } } //# sourceMappingURL=aborterUtils.js.map /***/ }), -/***/ 53784: +/***/ 28677: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -51156,20 +51092,20 @@ const abort_controller_1 = __nccwpck_require__(764); * @returns A promise that can be aborted. */ function createAbortablePromise(buildPromise, options) { - const { cleanupBeforeAbort, abortSignal, abortErrorMsg } = options ?? {}; + const { cleanupBeforeAbort, abortSignal, abortErrorMsg } = options !== null && options !== void 0 ? options : {}; return new Promise((resolve, reject) => { function rejectOnAbort() { - reject(new abort_controller_1.AbortError(abortErrorMsg ?? "The operation was aborted.")); + reject(new abort_controller_1.AbortError(abortErrorMsg !== null && abortErrorMsg !== void 0 ? abortErrorMsg : "The operation was aborted.")); } function removeListeners() { - abortSignal?.removeEventListener("abort", onAbort); + abortSignal === null || abortSignal === void 0 ? void 0 : abortSignal.removeEventListener("abort", onAbort); } function onAbort() { - cleanupBeforeAbort?.(); + cleanupBeforeAbort === null || cleanupBeforeAbort === void 0 ? void 0 : cleanupBeforeAbort(); removeListeners(); rejectOnAbort(); } - if (abortSignal?.aborted) { + if (abortSignal === null || abortSignal === void 0 ? void 0 : abortSignal.aborted) { return rejectOnAbort(); } try { @@ -51184,14 +51120,14 @@ function createAbortablePromise(buildPromise, options) { catch (err) { reject(err); } - abortSignal?.addEventListener("abort", onAbort); + abortSignal === null || abortSignal === void 0 ? void 0 : abortSignal.addEventListener("abort", onAbort); }); } //# sourceMappingURL=createAbortablePromise.js.map /***/ }), -/***/ 45164: +/***/ 50419: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -51200,8 +51136,8 @@ function createAbortablePromise(buildPromise, options) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.delay = delay; exports.calculateRetryDelay = calculateRetryDelay; -const createAbortablePromise_js_1 = __nccwpck_require__(53784); -const util_1 = __nccwpck_require__(56759); +const createAbortablePromise_js_1 = __nccwpck_require__(28677); +const util_1 = __nccwpck_require__(37954); const StandardAbortMessage = "The delay was aborted."; /** * A wrapper for setTimeout that resolves a promise after timeInMs milliseconds. @@ -51211,13 +51147,13 @@ const StandardAbortMessage = "The delay was aborted."; */ function delay(timeInMs, options) { let token; - const { abortSignal, abortErrorMsg } = options ?? {}; + const { abortSignal, abortErrorMsg } = options !== null && options !== void 0 ? options : {}; return (0, createAbortablePromise_js_1.createAbortablePromise)((resolve) => { token = setTimeout(resolve, timeInMs); }, { cleanupBeforeAbort: () => clearTimeout(token), abortSignal, - abortErrorMsg: abortErrorMsg ?? StandardAbortMessage, + abortErrorMsg: abortErrorMsg !== null && abortErrorMsg !== void 0 ? abortErrorMsg : StandardAbortMessage, }); } /** @@ -51240,7 +51176,7 @@ function calculateRetryDelay(retryAttempt, config) { /***/ }), -/***/ 23721: +/***/ 3030: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -51248,7 +51184,7 @@ function calculateRetryDelay(retryAttempt, config) { // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.getErrorMessage = getErrorMessage; -const util_1 = __nccwpck_require__(56759); +const util_1 = __nccwpck_require__(37954); /** * Given what is thought to be an error object, return the message if possible. * If the message is missing, returns a stringified version of the input. @@ -51279,7 +51215,7 @@ function getErrorMessage(e) { /***/ }), -/***/ 60643: +/***/ 91276: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -51297,16 +51233,16 @@ exports.randomUUID = randomUUID; exports.uint8ArrayToString = uint8ArrayToString; exports.stringToUint8Array = stringToUint8Array; const tslib_1 = __nccwpck_require__(31577); -const tspRuntime = tslib_1.__importStar(__nccwpck_require__(56759)); -var aborterUtils_js_1 = __nccwpck_require__(67145); +const tspRuntime = tslib_1.__importStar(__nccwpck_require__(37954)); +var aborterUtils_js_1 = __nccwpck_require__(64904); Object.defineProperty(exports, "cancelablePromiseRace", ({ enumerable: true, get: function () { return aborterUtils_js_1.cancelablePromiseRace; } })); -var createAbortablePromise_js_1 = __nccwpck_require__(53784); +var createAbortablePromise_js_1 = __nccwpck_require__(28677); Object.defineProperty(exports, "createAbortablePromise", ({ enumerable: true, get: function () { return createAbortablePromise_js_1.createAbortablePromise; } })); -var delay_js_1 = __nccwpck_require__(45164); +var delay_js_1 = __nccwpck_require__(50419); Object.defineProperty(exports, "delay", ({ enumerable: true, get: function () { return delay_js_1.delay; } })); -var error_js_1 = __nccwpck_require__(23721); +var error_js_1 = __nccwpck_require__(3030); Object.defineProperty(exports, "getErrorMessage", ({ enumerable: true, get: function () { return error_js_1.getErrorMessage; } })); -var typeGuards_js_1 = __nccwpck_require__(73989); +var typeGuards_js_1 = __nccwpck_require__(34552); Object.defineProperty(exports, "isDefined", ({ enumerable: true, get: function () { return typeGuards_js_1.isDefined; } })); Object.defineProperty(exports, "isObjectWithProperties", ({ enumerable: true, get: function () { return typeGuards_js_1.isObjectWithProperties; } })); Object.defineProperty(exports, "objectHasProperty", ({ enumerable: true, get: function () { return typeGuards_js_1.objectHasProperty; } })); @@ -51436,7 +51372,7 @@ function stringToUint8Array(value, format) { /***/ }), -/***/ 73989: +/***/ 34552: /***/ ((__unused_webpack_module, exports) => { @@ -51603,7 +51539,7 @@ exports.AzureLogger = void 0; exports.setLogLevel = setLogLevel; exports.getLogLevel = getLogLevel; exports.createClientLogger = createClientLogger; -const logger_1 = __nccwpck_require__(49647); +const logger_1 = __nccwpck_require__(5334); const context = (0, logger_1.createLoggerContext)({ logLevelEnvVarName: "AZURE_LOG_LEVEL", namespace: "azure", @@ -51663,8 +51599,8 @@ Object.defineProperty(exports, "__esModule", ({ value: true })); // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.BatchResponseParser = void 0; -const core_rest_pipeline_1 = __nccwpck_require__(64839); -const core_http_compat_1 = __nccwpck_require__(37385); +const core_rest_pipeline_1 = __nccwpck_require__(54786); +const core_http_compat_1 = __nccwpck_require__(62464); const constants_js_1 = __nccwpck_require__(48855); const BatchUtils_js_1 = __nccwpck_require__(9071); const log_js_1 = __nccwpck_require__(19150); @@ -51840,10 +51776,10 @@ function utf8ByteLength(str) { // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.BlobBatch = void 0; -const core_util_1 = __nccwpck_require__(60643); -const core_auth_1 = __nccwpck_require__(10734); -const core_rest_pipeline_1 = __nccwpck_require__(64839); -const core_util_2 = __nccwpck_require__(60643); +const core_util_1 = __nccwpck_require__(91276); +const core_auth_1 = __nccwpck_require__(46113); +const core_rest_pipeline_1 = __nccwpck_require__(54786); +const core_util_2 = __nccwpck_require__(91276); const AnonymousCredential_js_1 = __nccwpck_require__(77725); const Clients_js_1 = __nccwpck_require__(79656); const Mutex_js_1 = __nccwpck_require__(93269); @@ -51853,7 +51789,7 @@ const core_xml_1 = __nccwpck_require__(64993); const constants_js_1 = __nccwpck_require__(48855); const StorageSharedKeyCredential_js_1 = __nccwpck_require__(78403); const tracing_js_1 = __nccwpck_require__(9820); -const core_client_1 = __nccwpck_require__(32588); +const core_client_1 = __nccwpck_require__(9235); const StorageSharedKeyCredentialPolicyV2_js_1 = __nccwpck_require__(99283); /** * A BlobBatch represents an aggregated set of operations on blobs. @@ -52308,7 +52244,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true })); exports.BlobDownloadResponse = void 0; // Copyright (c) Microsoft Corporation. // Licensed under the MIT License. -const core_util_1 = __nccwpck_require__(60643); +const core_util_1 = __nccwpck_require__(91276); const RetriableReadableStream_js_1 = __nccwpck_require__(90424); /** * ONLY AVAILABLE IN NODE.JS RUNTIME. @@ -52783,7 +52719,7 @@ exports.BlobDownloadResponse = BlobDownloadResponse; // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.BlobLeaseClient = void 0; -const core_util_1 = __nccwpck_require__(60643); +const core_util_1 = __nccwpck_require__(91276); const constants_js_1 = __nccwpck_require__(48855); const tracing_js_1 = __nccwpck_require__(9820); const utils_common_js_1 = __nccwpck_require__(46456); @@ -52994,7 +52930,7 @@ exports.BlobLeaseClient = BlobLeaseClient; // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.BlobQueryResponse = void 0; -const core_util_1 = __nccwpck_require__(60643); +const core_util_1 = __nccwpck_require__(91276); const BlobQuickQueryStream_js_1 = __nccwpck_require__(35942); /** * ONLY AVAILABLE IN NODE.JS RUNTIME. @@ -53371,9 +53307,9 @@ exports.BlobQueryResponse = BlobQueryResponse; Object.defineProperty(exports, "__esModule", ({ value: true })); exports.BlobServiceClient = void 0; -const core_auth_1 = __nccwpck_require__(10734); -const core_rest_pipeline_1 = __nccwpck_require__(64839); -const core_util_1 = __nccwpck_require__(60643); +const core_auth_1 = __nccwpck_require__(46113); +const core_rest_pipeline_1 = __nccwpck_require__(54786); +const core_util_1 = __nccwpck_require__(91276); const Pipeline_js_1 = __nccwpck_require__(24236); const ContainerClient_js_1 = __nccwpck_require__(11432); const utils_common_js_1 = __nccwpck_require__(46456); @@ -54086,10 +54022,10 @@ exports.BlobServiceClient = BlobServiceClient; // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.PageBlobClient = exports.BlockBlobClient = exports.AppendBlobClient = exports.BlobClient = void 0; -const core_rest_pipeline_1 = __nccwpck_require__(64839); -const core_auth_1 = __nccwpck_require__(10734); -const core_util_1 = __nccwpck_require__(60643); -const core_util_2 = __nccwpck_require__(60643); +const core_rest_pipeline_1 = __nccwpck_require__(54786); +const core_auth_1 = __nccwpck_require__(46113); +const core_util_1 = __nccwpck_require__(91276); +const core_util_2 = __nccwpck_require__(91276); const BlobDownloadResponse_js_1 = __nccwpck_require__(85602); const BlobQueryResponse_js_1 = __nccwpck_require__(24454); const AnonymousCredential_js_1 = __nccwpck_require__(77725); @@ -56941,9 +56877,9 @@ exports.PageBlobClient = PageBlobClient; Object.defineProperty(exports, "__esModule", ({ value: true })); exports.ContainerClient = void 0; -const core_rest_pipeline_1 = __nccwpck_require__(64839); -const core_util_1 = __nccwpck_require__(60643); -const core_auth_1 = __nccwpck_require__(10734); +const core_rest_pipeline_1 = __nccwpck_require__(54786); +const core_util_1 = __nccwpck_require__(91276); +const core_auth_1 = __nccwpck_require__(46113); const AnonymousCredential_js_1 = __nccwpck_require__(77725); const StorageSharedKeyCredential_js_1 = __nccwpck_require__(78403); const Pipeline_js_1 = __nccwpck_require__(24236); @@ -58291,11 +58227,11 @@ exports.isPipelineLike = isPipelineLike; exports.newPipeline = newPipeline; exports.getCoreClientOptions = getCoreClientOptions; exports.getCredentialFromPipeline = getCredentialFromPipeline; -const core_http_compat_1 = __nccwpck_require__(37385); -const core_rest_pipeline_1 = __nccwpck_require__(64839); -const core_client_1 = __nccwpck_require__(32588); +const core_http_compat_1 = __nccwpck_require__(62464); +const core_rest_pipeline_1 = __nccwpck_require__(54786); +const core_client_1 = __nccwpck_require__(9235); const core_xml_1 = __nccwpck_require__(64993); -const core_auth_1 = __nccwpck_require__(10734); +const core_auth_1 = __nccwpck_require__(46113); const log_js_1 = __nccwpck_require__(19150); const StorageRetryPolicyFactory_js_1 = __nccwpck_require__(92075); const StorageSharedKeyCredential_js_1 = __nccwpck_require__(78403); @@ -69104,7 +69040,7 @@ exports.listType = { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.AppendBlobImpl = void 0; const tslib_1 = __nccwpck_require__(31577); -const coreClient = tslib_1.__importStar(__nccwpck_require__(32588)); +const coreClient = tslib_1.__importStar(__nccwpck_require__(9235)); const Mappers = tslib_1.__importStar(__nccwpck_require__(52108)); const Parameters = tslib_1.__importStar(__nccwpck_require__(11236)); /** Class containing AppendBlob operations. */ @@ -69338,7 +69274,7 @@ const sealOperationSpec = { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.BlobImpl = void 0; const tslib_1 = __nccwpck_require__(31577); -const coreClient = tslib_1.__importStar(__nccwpck_require__(32588)); +const coreClient = tslib_1.__importStar(__nccwpck_require__(9235)); const Mappers = tslib_1.__importStar(__nccwpck_require__(52108)); const Parameters = tslib_1.__importStar(__nccwpck_require__(11236)); /** Class containing Blob operations. */ @@ -70371,7 +70307,7 @@ const setTagsOperationSpec = { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.BlockBlobImpl = void 0; const tslib_1 = __nccwpck_require__(31577); -const coreClient = tslib_1.__importStar(__nccwpck_require__(32588)); +const coreClient = tslib_1.__importStar(__nccwpck_require__(9235)); const Mappers = tslib_1.__importStar(__nccwpck_require__(52108)); const Parameters = tslib_1.__importStar(__nccwpck_require__(11236)); /** Class containing BlockBlob operations. */ @@ -70750,7 +70686,7 @@ const getBlockListOperationSpec = { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.ContainerImpl = void 0; const tslib_1 = __nccwpck_require__(31577); -const coreClient = tslib_1.__importStar(__nccwpck_require__(32588)); +const coreClient = tslib_1.__importStar(__nccwpck_require__(9235)); const Mappers = tslib_1.__importStar(__nccwpck_require__(52108)); const Parameters = tslib_1.__importStar(__nccwpck_require__(11236)); /** Class containing Container operations. */ @@ -71498,7 +71434,7 @@ tslib_1.__exportStar(__nccwpck_require__(32020), exports); Object.defineProperty(exports, "__esModule", ({ value: true })); exports.PageBlobImpl = void 0; const tslib_1 = __nccwpck_require__(31577); -const coreClient = tslib_1.__importStar(__nccwpck_require__(32588)); +const coreClient = tslib_1.__importStar(__nccwpck_require__(9235)); const Mappers = tslib_1.__importStar(__nccwpck_require__(52108)); const Parameters = tslib_1.__importStar(__nccwpck_require__(11236)); /** Class containing PageBlob operations. */ @@ -71967,7 +71903,7 @@ const copyIncrementalOperationSpec = { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.ServiceImpl = void 0; const tslib_1 = __nccwpck_require__(31577); -const coreClient = tslib_1.__importStar(__nccwpck_require__(32588)); +const coreClient = tslib_1.__importStar(__nccwpck_require__(9235)); const Mappers = tslib_1.__importStar(__nccwpck_require__(52108)); const Parameters = tslib_1.__importStar(__nccwpck_require__(11236)); /** Class containing Service operations. */ @@ -72421,7 +72357,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true })); Object.defineProperty(exports, "__esModule", ({ value: true })); exports.StorageClient = void 0; const tslib_1 = __nccwpck_require__(31577); -const coreHttpCompat = tslib_1.__importStar(__nccwpck_require__(37385)); +const coreHttpCompat = tslib_1.__importStar(__nccwpck_require__(62464)); const index_js_1 = __nccwpck_require__(62594); class StorageClient extends coreHttpCompat.ExtendedServiceClient { url; @@ -72505,7 +72441,7 @@ var KnownEncryptionAlgorithmType; Object.defineProperty(exports, "__esModule", ({ value: true })); exports.logger = exports.RestError = exports.BaseRequestPolicy = exports.StorageOAuthScopes = exports.newPipeline = exports.isPipelineLike = exports.Pipeline = exports.getBlobServiceAccountAudience = exports.StorageBlobAudience = exports.PremiumPageBlobTier = exports.BlockBlobTier = exports.generateBlobSASQueryParameters = exports.generateAccountSASQueryParameters = void 0; const tslib_1 = __nccwpck_require__(31577); -const core_rest_pipeline_1 = __nccwpck_require__(64839); +const core_rest_pipeline_1 = __nccwpck_require__(54786); Object.defineProperty(exports, "RestError", ({ enumerable: true, get: function () { return core_rest_pipeline_1.RestError; } })); tslib_1.__exportStar(__nccwpck_require__(74177), exports); tslib_1.__exportStar(__nccwpck_require__(79656), exports); @@ -73456,7 +73392,7 @@ exports.BaseRequestPolicy = BaseRequestPolicy; Object.defineProperty(exports, "__esModule", ({ value: true })); exports.StorageBrowserPolicy = void 0; const RequestPolicy_js_1 = __nccwpck_require__(51916); -const core_util_1 = __nccwpck_require__(60643); +const core_util_1 = __nccwpck_require__(91276); const constants_js_1 = __nccwpck_require__(48855); const utils_common_js_1 = __nccwpck_require__(46456); /** @@ -73513,7 +73449,7 @@ exports.StorageBrowserPolicy = StorageBrowserPolicy; Object.defineProperty(exports, "__esModule", ({ value: true })); exports.storageBrowserPolicyName = void 0; exports.storageBrowserPolicy = storageBrowserPolicy; -const core_util_1 = __nccwpck_require__(60643); +const core_util_1 = __nccwpck_require__(91276); const constants_js_1 = __nccwpck_require__(48855); const utils_common_js_1 = __nccwpck_require__(46456); /** @@ -73849,8 +73785,8 @@ Object.defineProperty(exports, "__esModule", ({ value: true })); exports.storageRetryPolicyName = void 0; exports.storageRetryPolicy = storageRetryPolicy; const abort_controller_1 = __nccwpck_require__(764); -const core_rest_pipeline_1 = __nccwpck_require__(64839); -const core_util_1 = __nccwpck_require__(60643); +const core_rest_pipeline_1 = __nccwpck_require__(54786); +const core_util_1 = __nccwpck_require__(91276); const StorageRetryPolicyFactory_js_1 = __nccwpck_require__(92075); const constants_js_1 = __nccwpck_require__(48855); const utils_common_js_1 = __nccwpck_require__(46456); @@ -74319,7 +74255,7 @@ function storageSharedKeyCredentialPolicy(options) { // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.BlobBeginCopyFromUrlPoller = void 0; -const core_util_1 = __nccwpck_require__(60643); +const core_util_1 = __nccwpck_require__(91276); const core_lro_1 = __nccwpck_require__(22670); /** * This is the poller returned by {@link BlobClient.beginCopyFromURL}. @@ -77262,7 +77198,7 @@ exports.PathStylePorts = [ // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.tracingClient = void 0; -const core_tracing_1 = __nccwpck_require__(78168); +const core_tracing_1 = __nccwpck_require__(92245); const constants_js_1 = __nccwpck_require__(48855); /** * Creates a span using the global tracer. @@ -77320,8 +77256,8 @@ exports.ConvertInternalResponseOfListBlobHierarchy = ConvertInternalResponseOfLi exports.ExtractPageRangeInfoItems = ExtractPageRangeInfoItems; exports.EscapePath = EscapePath; exports.assertResponse = assertResponse; -const core_rest_pipeline_1 = __nccwpck_require__(64839); -const core_util_1 = __nccwpck_require__(60643); +const core_rest_pipeline_1 = __nccwpck_require__(54786); +const core_util_1 = __nccwpck_require__(91276); const constants_js_1 = __nccwpck_require__(48855); /** * Reserved URL characters must be properly escaped for Storage services like Blob or File. @@ -78813,7 +78749,7 @@ exports.StorageRetryPolicyFactory = StorageRetryPolicyFactory; // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.getCachedDefaultHttpClient = getCachedDefaultHttpClient; -const core_rest_pipeline_1 = __nccwpck_require__(64839); +const core_rest_pipeline_1 = __nccwpck_require__(54786); let _defaultHttpClient; function getCachedDefaultHttpClient() { if (!_defaultHttpClient) { @@ -79124,7 +79060,7 @@ exports.BaseRequestPolicy = BaseRequestPolicy; Object.defineProperty(exports, "__esModule", ({ value: true })); exports.StorageBrowserPolicy = void 0; const RequestPolicy_js_1 = __nccwpck_require__(19024); -const core_util_1 = __nccwpck_require__(60643); +const core_util_1 = __nccwpck_require__(91276); const constants_js_1 = __nccwpck_require__(94795); const utils_common_js_1 = __nccwpck_require__(4100); /** @@ -79181,7 +79117,7 @@ exports.StorageBrowserPolicy = StorageBrowserPolicy; Object.defineProperty(exports, "__esModule", ({ value: true })); exports.storageBrowserPolicyName = void 0; exports.storageBrowserPolicy = storageBrowserPolicy; -const core_util_1 = __nccwpck_require__(60643); +const core_util_1 = __nccwpck_require__(91276); const constants_js_1 = __nccwpck_require__(94795); const utils_common_js_1 = __nccwpck_require__(4100); /** @@ -79517,8 +79453,8 @@ Object.defineProperty(exports, "__esModule", ({ value: true })); exports.storageRetryPolicyName = void 0; exports.storageRetryPolicy = storageRetryPolicy; const abort_controller_1 = __nccwpck_require__(764); -const core_rest_pipeline_1 = __nccwpck_require__(64839); -const core_util_1 = __nccwpck_require__(60643); +const core_rest_pipeline_1 = __nccwpck_require__(54786); +const core_util_1 = __nccwpck_require__(91276); const StorageRetryPolicyFactory_js_1 = __nccwpck_require__(53519); const constants_js_1 = __nccwpck_require__(94795); const utils_common_js_1 = __nccwpck_require__(4100); @@ -80168,8 +80104,8 @@ exports.attachCredential = attachCredential; exports.httpAuthorizationToString = httpAuthorizationToString; exports.EscapePath = EscapePath; exports.assertResponse = assertResponse; -const core_rest_pipeline_1 = __nccwpck_require__(64839); -const core_util_1 = __nccwpck_require__(60643); +const core_rest_pipeline_1 = __nccwpck_require__(54786); +const core_util_1 = __nccwpck_require__(91276); const constants_js_1 = __nccwpck_require__(94795); /** * Reserved URL characters must be properly escaped for Storage services like Blob or File. @@ -82326,7 +82262,7 @@ module.exports = parseParams /***/ }), -/***/ 61865: +/***/ 84260: /***/ ((__unused_webpack_module, exports) => { @@ -82374,7 +82310,7 @@ exports.AbortError = AbortError; /***/ }), -/***/ 97796: +/***/ 8007: /***/ ((__unused_webpack_module, exports) => { @@ -82413,7 +82349,7 @@ function isApiKeyCredential(credential) { /***/ }), -/***/ 926: +/***/ 98517: /***/ ((__unused_webpack_module, exports) => { @@ -82424,7 +82360,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true })); /***/ }), -/***/ 24558: +/***/ 32157: /***/ ((__unused_webpack_module, exports) => { @@ -82435,7 +82371,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true })); /***/ }), -/***/ 18261: +/***/ 28540: /***/ ((__unused_webpack_module, exports) => { @@ -82468,7 +82404,7 @@ function apiVersionPolicy(options) { /***/ }), -/***/ 51051: +/***/ 38052: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -82477,14 +82413,14 @@ function apiVersionPolicy(options) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.createDefaultPipeline = createDefaultPipeline; exports.getCachedDefaultHttpsClient = getCachedDefaultHttpsClient; -const defaultHttpClient_js_1 = __nccwpck_require__(51045); -const createPipelineFromOptions_js_1 = __nccwpck_require__(60459); -const apiVersionPolicy_js_1 = __nccwpck_require__(18261); -const credentials_js_1 = __nccwpck_require__(97796); -const apiKeyAuthenticationPolicy_js_1 = __nccwpck_require__(64668); -const basicAuthenticationPolicy_js_1 = __nccwpck_require__(42229); -const bearerAuthenticationPolicy_js_1 = __nccwpck_require__(89434); -const oauth2AuthenticationPolicy_js_1 = __nccwpck_require__(18912); +const defaultHttpClient_js_1 = __nccwpck_require__(41264); +const createPipelineFromOptions_js_1 = __nccwpck_require__(38358); +const apiVersionPolicy_js_1 = __nccwpck_require__(28540); +const credentials_js_1 = __nccwpck_require__(8007); +const apiKeyAuthenticationPolicy_js_1 = __nccwpck_require__(86987); +const basicAuthenticationPolicy_js_1 = __nccwpck_require__(6664); +const bearerAuthenticationPolicy_js_1 = __nccwpck_require__(66849); +const oauth2AuthenticationPolicy_js_1 = __nccwpck_require__(71143); let cachedHttpClient; /** * Creates a default rest pipeline to re-use accross Rest Level Clients @@ -82519,7 +82455,7 @@ function getCachedDefaultHttpsClient() { /***/ }), -/***/ 42468: +/***/ 20587: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -82527,10 +82463,10 @@ function getCachedDefaultHttpsClient() { // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.getClient = getClient; -const clientHelpers_js_1 = __nccwpck_require__(51051); -const sendRequest_js_1 = __nccwpck_require__(50796); -const urlHelpers_js_1 = __nccwpck_require__(98693); -const checkEnvironment_js_1 = __nccwpck_require__(31407); +const clientHelpers_js_1 = __nccwpck_require__(38052); +const sendRequest_js_1 = __nccwpck_require__(36451); +const urlHelpers_js_1 = __nccwpck_require__(12500); +const checkEnvironment_js_1 = __nccwpck_require__(98402); /** * Creates a client with a default pipeline * @param endpoint - Base endpoint for the client @@ -82538,8 +82474,9 @@ const checkEnvironment_js_1 = __nccwpck_require__(31407); * @param options - Client options */ function getClient(endpoint, clientOptions = {}) { - const pipeline = clientOptions.pipeline ?? (0, clientHelpers_js_1.createDefaultPipeline)(clientOptions); - if (clientOptions.additionalPolicies?.length) { + var _a, _b, _c; + const pipeline = (_a = clientOptions.pipeline) !== null && _a !== void 0 ? _a : (0, clientHelpers_js_1.createDefaultPipeline)(clientOptions); + if ((_b = clientOptions.additionalPolicies) === null || _b === void 0 ? void 0 : _b.length) { for (const { policy, position } of clientOptions.additionalPolicies) { // Sign happens after Retry and is commonly needed to occur // before policies that intercept post-retry. @@ -82550,9 +82487,9 @@ function getClient(endpoint, clientOptions = {}) { } } const { allowInsecureConnection, httpClient } = clientOptions; - const endpointUrl = clientOptions.endpoint ?? endpoint; + const endpointUrl = (_c = clientOptions.endpoint) !== null && _c !== void 0 ? _c : endpoint; const client = (path, ...args) => { - const getUrl = (requestOptions) => (0, urlHelpers_js_1.buildRequestUrl)(endpointUrl, path, args, { allowInsecureConnection, ...requestOptions }); + const getUrl = (requestOptions) => (0, urlHelpers_js_1.buildRequestUrl)(endpointUrl, path, args, Object.assign({ allowInsecureConnection }, requestOptions)); return { get: (requestOptions = {}) => { return buildOperation("GET", getUrl(requestOptions), pipeline, requestOptions, allowInsecureConnection, httpClient); @@ -82587,22 +82524,23 @@ function getClient(endpoint, clientOptions = {}) { }; } function buildOperation(method, url, pipeline, options, allowInsecureConnection, httpClient) { - allowInsecureConnection = options.allowInsecureConnection ?? allowInsecureConnection; + var _a; + allowInsecureConnection = (_a = options.allowInsecureConnection) !== null && _a !== void 0 ? _a : allowInsecureConnection; return { then: function (onFulfilled, onrejected) { - return (0, sendRequest_js_1.sendRequest)(method, url, pipeline, { ...options, allowInsecureConnection }, httpClient).then(onFulfilled, onrejected); + return (0, sendRequest_js_1.sendRequest)(method, url, pipeline, Object.assign(Object.assign({}, options), { allowInsecureConnection }), httpClient).then(onFulfilled, onrejected); }, async asBrowserStream() { if (checkEnvironment_js_1.isNodeLike) { throw new Error("`asBrowserStream` is supported only in the browser environment. Use `asNodeStream` instead to obtain the response body stream. If you require a Web stream of the response in Node, consider using `Readable.toWeb` on the result of `asNodeStream`."); } else { - return (0, sendRequest_js_1.sendRequest)(method, url, pipeline, { ...options, allowInsecureConnection, responseAsStream: true }, httpClient); + return (0, sendRequest_js_1.sendRequest)(method, url, pipeline, Object.assign(Object.assign({}, options), { allowInsecureConnection, responseAsStream: true }), httpClient); } }, async asNodeStream() { if (checkEnvironment_js_1.isNodeLike) { - return (0, sendRequest_js_1.sendRequest)(method, url, pipeline, { ...options, allowInsecureConnection, responseAsStream: true }, httpClient); + return (0, sendRequest_js_1.sendRequest)(method, url, pipeline, Object.assign(Object.assign({}, options), { allowInsecureConnection, responseAsStream: true }), httpClient); } else { throw new Error("`isNodeStream` is not supported in the browser environment. Use `asBrowserStream` to obtain the response body stream."); @@ -82614,7 +82552,7 @@ function buildOperation(method, url, pipeline, options, allowInsecureConnection, /***/ }), -/***/ 73407: +/***/ 20140: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -82623,10 +82561,10 @@ function buildOperation(method, url, pipeline, options, allowInsecureConnection, Object.defineProperty(exports, "__esModule", ({ value: true })); exports.buildBodyPart = buildBodyPart; exports.buildMultipartBody = buildMultipartBody; -const restError_js_1 = __nccwpck_require__(45227); -const httpHeaders_js_1 = __nccwpck_require__(82345); -const bytesEncoding_js_1 = __nccwpck_require__(28482); -const typeGuards_js_1 = __nccwpck_require__(90932); +const restError_js_1 = __nccwpck_require__(79058); +const httpHeaders_js_1 = __nccwpck_require__(43688); +const bytesEncoding_js_1 = __nccwpck_require__(28917); +const typeGuards_js_1 = __nccwpck_require__(1093); /** * Get value of a header in the part descriptor ignoring case */ @@ -82674,6 +82612,7 @@ function escapeDispositionField(value) { return JSON.stringify(value); } function getContentDisposition(descriptor) { + var _a; const contentDispositionHeader = getHeaderValue(descriptor, "content-disposition"); if (contentDispositionHeader) { return contentDispositionHeader; @@ -82683,7 +82622,7 @@ function getContentDisposition(descriptor) { descriptor.filename === undefined) { return undefined; } - const dispositionType = descriptor.dispositionType ?? "form-data"; + const dispositionType = (_a = descriptor.dispositionType) !== null && _a !== void 0 ? _a : "form-data"; let disposition = dispositionType; if (descriptor.name) { disposition += `; name=${escapeDispositionField(descriptor.name)}`; @@ -82722,9 +82661,10 @@ function normalizeBody(body, contentType) { throw new restError_js_1.RestError(`Unsupported body/content-type combination: ${body}, ${contentType}`); } function buildBodyPart(descriptor) { + var _a; const contentType = getPartContentType(descriptor); const contentDisposition = getContentDisposition(descriptor); - const headers = (0, httpHeaders_js_1.createHttpHeaders)(descriptor.headers ?? {}); + const headers = (0, httpHeaders_js_1.createHttpHeaders)((_a = descriptor.headers) !== null && _a !== void 0 ? _a : {}); if (contentType) { headers.set("content-type", contentType); } @@ -82744,7 +82684,7 @@ function buildMultipartBody(parts) { /***/ }), -/***/ 85470: +/***/ 82831: /***/ ((__unused_webpack_module, exports) => { @@ -82758,14 +82698,15 @@ exports.operationOptionsToRequestParameters = operationOptionsToRequestParameter * @returns the result of the conversion in RequestParameters of RLC layer */ function operationOptionsToRequestParameters(options) { + var _a, _b, _c, _d, _e, _f; return { - allowInsecureConnection: options.requestOptions?.allowInsecureConnection, - timeout: options.requestOptions?.timeout, - skipUrlEncoding: options.requestOptions?.skipUrlEncoding, + allowInsecureConnection: (_a = options.requestOptions) === null || _a === void 0 ? void 0 : _a.allowInsecureConnection, + timeout: (_b = options.requestOptions) === null || _b === void 0 ? void 0 : _b.timeout, + skipUrlEncoding: (_c = options.requestOptions) === null || _c === void 0 ? void 0 : _c.skipUrlEncoding, abortSignal: options.abortSignal, - onUploadProgress: options.requestOptions?.onUploadProgress, - onDownloadProgress: options.requestOptions?.onDownloadProgress, - headers: { ...options.requestOptions?.headers }, + onUploadProgress: (_d = options.requestOptions) === null || _d === void 0 ? void 0 : _d.onUploadProgress, + onDownloadProgress: (_e = options.requestOptions) === null || _e === void 0 ? void 0 : _e.onDownloadProgress, + headers: Object.assign({}, (_f = options.requestOptions) === null || _f === void 0 ? void 0 : _f.headers), onResponse: options.onResponse, }; } @@ -82773,7 +82714,7 @@ function operationOptionsToRequestParameters(options) { /***/ }), -/***/ 31835: +/***/ 26920: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -82781,26 +82722,28 @@ function operationOptionsToRequestParameters(options) { // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.createRestError = createRestError; -const restError_js_1 = __nccwpck_require__(45227); -const httpHeaders_js_1 = __nccwpck_require__(82345); +const restError_js_1 = __nccwpck_require__(79058); +const httpHeaders_js_1 = __nccwpck_require__(43688); function createRestError(messageOrResponse, response) { + var _a, _b, _c; const resp = typeof messageOrResponse === "string" ? response : messageOrResponse; - const internalError = resp.body?.error ?? resp.body; + const internalError = (_b = (_a = resp.body) === null || _a === void 0 ? void 0 : _a.error) !== null && _b !== void 0 ? _b : resp.body; const message = typeof messageOrResponse === "string" ? messageOrResponse - : (internalError?.message ?? `Unexpected status code: ${resp.status}`); + : ((_c = internalError === null || internalError === void 0 ? void 0 : internalError.message) !== null && _c !== void 0 ? _c : `Unexpected status code: ${resp.status}`); return new restError_js_1.RestError(message, { statusCode: statusCodeToNumber(resp.status), - code: internalError?.code, + code: internalError === null || internalError === void 0 ? void 0 : internalError.code, request: resp.request, response: toPipelineResponse(resp), }); } function toPipelineResponse(response) { + var _a; return { headers: (0, httpHeaders_js_1.createHttpHeaders)(response.headers), request: response.request, - status: statusCodeToNumber(response.status) ?? -1, + status: (_a = statusCodeToNumber(response.status)) !== null && _a !== void 0 ? _a : -1, }; } function statusCodeToNumber(statusCode) { @@ -82811,7 +82754,7 @@ function statusCodeToNumber(statusCode) { /***/ }), -/***/ 50796: +/***/ 36451: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -82819,12 +82762,12 @@ function statusCodeToNumber(statusCode) { // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.sendRequest = sendRequest; -const restError_js_1 = __nccwpck_require__(45227); -const httpHeaders_js_1 = __nccwpck_require__(82345); -const pipelineRequest_js_1 = __nccwpck_require__(93244); -const clientHelpers_js_1 = __nccwpck_require__(51051); -const typeGuards_js_1 = __nccwpck_require__(90932); -const multipart_js_1 = __nccwpck_require__(73407); +const restError_js_1 = __nccwpck_require__(79058); +const httpHeaders_js_1 = __nccwpck_require__(43688); +const pipelineRequest_js_1 = __nccwpck_require__(61605); +const clientHelpers_js_1 = __nccwpck_require__(38052); +const typeGuards_js_1 = __nccwpck_require__(1093); +const multipart_js_1 = __nccwpck_require__(20140); /** * Helper function to send request used by the client * @param method - method to use to send the request @@ -82835,16 +82778,17 @@ const multipart_js_1 = __nccwpck_require__(73407); * @returns returns and HttpResponse */ async function sendRequest(method, url, pipeline, options = {}, customHttpClient) { - const httpClient = customHttpClient ?? (0, clientHelpers_js_1.getCachedDefaultHttpsClient)(); + var _a; + const httpClient = customHttpClient !== null && customHttpClient !== void 0 ? customHttpClient : (0, clientHelpers_js_1.getCachedDefaultHttpsClient)(); const request = buildPipelineRequest(method, url, options); try { const response = await pipeline.sendRequest(httpClient, request); const headers = response.headers.toJSON(); - const stream = response.readableStreamBody ?? response.browserStreamBody; + const stream = (_a = response.readableStreamBody) !== null && _a !== void 0 ? _a : response.browserStreamBody; const parsedBody = options.responseAsStream || stream !== undefined ? undefined : getResponseBody(response); - const body = stream ?? parsedBody; - if (options?.onResponse) { - options.onResponse({ ...response, request, rawHeaders: headers, parsedBody }); + const body = stream !== null && stream !== void 0 ? stream : parsedBody; + if (options === null || options === void 0 ? void 0 : options.onResponse) { + options.onResponse(Object.assign(Object.assign({}, response), { request, rawHeaders: headers, parsedBody })); } return { request, @@ -82858,7 +82802,7 @@ async function sendRequest(method, url, pipeline, options = {}, customHttpClient const { response } = e; const rawHeaders = response.headers.toJSON(); // UNBRANDED DIFFERENCE: onResponse callback does not have a second __legacyError property - options?.onResponse({ ...response, request, rawHeaders }, e); + options === null || options === void 0 ? void 0 : options.onResponse(Object.assign(Object.assign({}, response), { request, rawHeaders }), e); } throw e; } @@ -82869,9 +82813,8 @@ async function sendRequest(method, url, pipeline, options = {}, customHttpClient * @returns returns the content-type */ function getRequestContentType(options = {}) { - return (options.contentType ?? - options.headers?.["content-type"] ?? - getContentType(options.body)); + var _a, _b, _c; + return ((_c = (_a = options.contentType) !== null && _a !== void 0 ? _a : (_b = options.headers) === null || _b === void 0 ? void 0 : _b["content-type"]) !== null && _c !== void 0 ? _c : getContentType(options.body)); } /** * Function to determine the content-type of a body @@ -82897,17 +82840,14 @@ function getContentType(body) { return "application/json"; } function buildPipelineRequest(method, url, options = {}) { + var _a, _b, _c; const requestContentType = getRequestContentType(options); const { body, multipartBody } = getRequestBody(options.body, requestContentType); const hasContent = body !== undefined || multipartBody !== undefined; - const headers = (0, httpHeaders_js_1.createHttpHeaders)({ - ...(options.headers ? options.headers : {}), - accept: options.accept ?? options.headers?.accept ?? "application/json", - ...(hasContent && - requestContentType && { - "content-type": requestContentType, - }), - }); + const headers = (0, httpHeaders_js_1.createHttpHeaders)(Object.assign(Object.assign(Object.assign({}, (options.headers ? options.headers : {})), { accept: (_c = (_a = options.accept) !== null && _a !== void 0 ? _a : (_b = options.headers) === null || _b === void 0 ? void 0 : _b.accept) !== null && _c !== void 0 ? _c : "application/json" }), (hasContent && + requestContentType && { + "content-type": requestContentType, + }))); return (0, pipelineRequest_js_1.createPipelineRequest)({ url, method, @@ -82963,10 +82903,11 @@ function getRequestBody(body, contentType = "") { * Prepares the response body */ function getResponseBody(response) { + var _a, _b; // Set the default response type - const contentType = response.headers.get("content-type") ?? ""; + const contentType = (_a = response.headers.get("content-type")) !== null && _a !== void 0 ? _a : ""; const firstType = contentType.split(";")[0]; - const bodyToParse = response.bodyAsText ?? ""; + const bodyToParse = (_b = response.bodyAsText) !== null && _b !== void 0 ? _b : ""; if (firstType === "text/plain") { return String(bodyToParse); } @@ -82986,8 +82927,9 @@ function getResponseBody(response) { } } function createParseError(response, err) { + var _a; const msg = `Error "${err}" occurred while parsing the response body - ${response.bodyAsText}.`; - const errCode = err.code ?? restError_js_1.RestError.PARSE_ERROR; + const errCode = (_a = err.code) !== null && _a !== void 0 ? _a : restError_js_1.RestError.PARSE_ERROR; return new restError_js_1.RestError(msg, { code: errCode, statusCode: response.status, @@ -82999,7 +82941,7 @@ function createParseError(response, err) { /***/ }), -/***/ 98693: +/***/ 12500: /***/ ((__unused_webpack_module, exports) => { @@ -83072,6 +83014,7 @@ function getQueryParamValue(key, allowReserved, style, param) { return `${allowReserved ? key : encodeURIComponent(key)}=${value}`; } function appendQueryParams(url, options = {}) { + var _a, _b, _c, _d; if (!options.queryParameters) { return url; } @@ -83085,18 +83028,18 @@ function appendQueryParams(url, options = {}) { } const hasMetadata = isQueryParameterWithOptions(param); const rawValue = hasMetadata ? param.value : param; - const explode = hasMetadata ? (param.explode ?? false) : false; + const explode = hasMetadata ? ((_a = param.explode) !== null && _a !== void 0 ? _a : false) : false; const style = hasMetadata && param.style ? param.style : "form"; if (explode) { if (Array.isArray(rawValue)) { for (const item of rawValue) { - paramStrings.push(getQueryParamValue(key, options.skipUrlEncoding ?? false, style, item)); + paramStrings.push(getQueryParamValue(key, (_b = options.skipUrlEncoding) !== null && _b !== void 0 ? _b : false, style, item)); } } else if (typeof rawValue === "object") { // For object explode, the name of the query parameter is ignored and we use the object key instead for (const [actualKey, value] of Object.entries(rawValue)) { - paramStrings.push(getQueryParamValue(actualKey, options.skipUrlEncoding ?? false, style, value)); + paramStrings.push(getQueryParamValue(actualKey, (_c = options.skipUrlEncoding) !== null && _c !== void 0 ? _c : false, style, value)); } } else { @@ -83105,7 +83048,7 @@ function appendQueryParams(url, options = {}) { } } else { - paramStrings.push(getQueryParamValue(key, options.skipUrlEncoding ?? false, style, rawValue)); + paramStrings.push(getQueryParamValue(key, (_d = options.skipUrlEncoding) !== null && _d !== void 0 ? _d : false, style, rawValue)); } } if (parsedUrl.search !== "") { @@ -83115,6 +83058,7 @@ function appendQueryParams(url, options = {}) { return parsedUrl.toString(); } function buildBaseUrl(endpoint, options) { + var _a; if (!options.pathParameters) { return endpoint; } @@ -83130,13 +83074,14 @@ function buildBaseUrl(endpoint, options) { if (!options.skipUrlEncoding) { value = encodeURIComponent(param); } - endpoint = replaceAll(endpoint, `{${key}}`, value) ?? ""; + endpoint = (_a = replaceAll(endpoint, `{${key}}`, value)) !== null && _a !== void 0 ? _a : ""; } return endpoint; } function buildRoutePath(routePath, pathParameters, options = {}) { + var _a; for (const pathParam of pathParameters) { - const allowReserved = typeof pathParam === "object" && (pathParam.allowReserved ?? false); + const allowReserved = typeof pathParam === "object" && ((_a = pathParam.allowReserved) !== null && _a !== void 0 ? _a : false); let value = typeof pathParam === "object" ? pathParam.value : pathParam; if (!options.skipUrlEncoding && !allowReserved) { value = encodeURIComponent(value); @@ -83159,7 +83104,7 @@ function replaceAll(value, searchValue, replaceValue) { /***/ }), -/***/ 4202: +/***/ 88819: /***/ ((__unused_webpack_module, exports) => { @@ -83167,13 +83112,13 @@ function replaceAll(value, searchValue, replaceValue) { // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.DEFAULT_RETRY_POLICY_COUNT = exports.SDK_VERSION = void 0; -exports.SDK_VERSION = "0.3.1"; +exports.SDK_VERSION = "0.3.0"; exports.DEFAULT_RETRY_POLICY_COUNT = 3; //# sourceMappingURL=constants.js.map /***/ }), -/***/ 60459: +/***/ 38358: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -83181,18 +83126,18 @@ exports.DEFAULT_RETRY_POLICY_COUNT = 3; // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.createPipelineFromOptions = createPipelineFromOptions; -const logPolicy_js_1 = __nccwpck_require__(65598); -const pipeline_js_1 = __nccwpck_require__(95405); -const redirectPolicy_js_1 = __nccwpck_require__(96318); -const userAgentPolicy_js_1 = __nccwpck_require__(22448); -const decompressResponsePolicy_js_1 = __nccwpck_require__(42878); -const defaultRetryPolicy_js_1 = __nccwpck_require__(50247); -const formDataPolicy_js_1 = __nccwpck_require__(51888); -const checkEnvironment_js_1 = __nccwpck_require__(31407); -const proxyPolicy_js_1 = __nccwpck_require__(33996); -const agentPolicy_js_1 = __nccwpck_require__(97789); -const tlsPolicy_js_1 = __nccwpck_require__(84949); -const multipartPolicy_js_1 = __nccwpck_require__(35384); +const logPolicy_js_1 = __nccwpck_require__(85613); +const pipeline_js_1 = __nccwpck_require__(53390); +const redirectPolicy_js_1 = __nccwpck_require__(56959); +const userAgentPolicy_js_1 = __nccwpck_require__(92375); +const decompressResponsePolicy_js_1 = __nccwpck_require__(29815); +const defaultRetryPolicy_js_1 = __nccwpck_require__(14786); +const formDataPolicy_js_1 = __nccwpck_require__(70337); +const checkEnvironment_js_1 = __nccwpck_require__(98402); +const proxyPolicy_js_1 = __nccwpck_require__(53511); +const agentPolicy_js_1 = __nccwpck_require__(51250); +const tlsPolicy_js_1 = __nccwpck_require__(55726); +const multipartPolicy_js_1 = __nccwpck_require__(75303); /** * Create a new pipeline with a default set of customizable policies. * @param options - Options to configure a custom pipeline. @@ -83228,7 +83173,7 @@ function createPipelineFromOptions(options) { /***/ }), -/***/ 51045: +/***/ 41264: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -83236,7 +83181,7 @@ function createPipelineFromOptions(options) { // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.createDefaultHttpClient = createDefaultHttpClient; -const nodeHttpClient_js_1 = __nccwpck_require__(77860); +const nodeHttpClient_js_1 = __nccwpck_require__(93003); /** * Create the correct HttpClient for the current environment. */ @@ -83247,7 +83192,7 @@ function createDefaultHttpClient() { /***/ }), -/***/ 82345: +/***/ 43688: /***/ ((__unused_webpack_module, exports) => { @@ -83264,7 +83209,6 @@ function* headerIterator(map) { } } class HttpHeadersImpl { - _headersMap; constructor(rawHeaders) { this._headersMap = new Map(); if (rawHeaders) { @@ -83288,7 +83232,8 @@ class HttpHeadersImpl { * @param name - The name of the header. This value is case-insensitive. */ get(name) { - return this._headersMap.get(normalizeName(name))?.value; + var _a; + return (_a = this._headersMap.get(normalizeName(name))) === null || _a === void 0 ? void 0 : _a.value; } /** * Get whether or not this header collection contains a header entry for the provided header name. @@ -83345,7 +83290,7 @@ function createHttpHeaders(rawHeaders) { /***/ }), -/***/ 54855: +/***/ 67810: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -83354,40 +83299,40 @@ function createHttpHeaders(rawHeaders) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.createRestError = exports.operationOptionsToRequestParameters = exports.getClient = exports.createDefaultHttpClient = exports.uint8ArrayToString = exports.stringToUint8Array = exports.isRestError = exports.RestError = exports.createEmptyPipeline = exports.createPipelineRequest = exports.createHttpHeaders = exports.TypeSpecRuntimeLogger = exports.setLogLevel = exports.getLogLevel = exports.createClientLogger = exports.AbortError = void 0; const tslib_1 = __nccwpck_require__(31577); -var AbortError_js_1 = __nccwpck_require__(61865); +var AbortError_js_1 = __nccwpck_require__(84260); Object.defineProperty(exports, "AbortError", ({ enumerable: true, get: function () { return AbortError_js_1.AbortError; } })); -var logger_js_1 = __nccwpck_require__(96342); +var logger_js_1 = __nccwpck_require__(34135); Object.defineProperty(exports, "createClientLogger", ({ enumerable: true, get: function () { return logger_js_1.createClientLogger; } })); Object.defineProperty(exports, "getLogLevel", ({ enumerable: true, get: function () { return logger_js_1.getLogLevel; } })); Object.defineProperty(exports, "setLogLevel", ({ enumerable: true, get: function () { return logger_js_1.setLogLevel; } })); Object.defineProperty(exports, "TypeSpecRuntimeLogger", ({ enumerable: true, get: function () { return logger_js_1.TypeSpecRuntimeLogger; } })); -var httpHeaders_js_1 = __nccwpck_require__(82345); +var httpHeaders_js_1 = __nccwpck_require__(43688); Object.defineProperty(exports, "createHttpHeaders", ({ enumerable: true, get: function () { return httpHeaders_js_1.createHttpHeaders; } })); -tslib_1.__exportStar(__nccwpck_require__(24558), exports); -tslib_1.__exportStar(__nccwpck_require__(926), exports); -var pipelineRequest_js_1 = __nccwpck_require__(93244); +tslib_1.__exportStar(__nccwpck_require__(32157), exports); +tslib_1.__exportStar(__nccwpck_require__(98517), exports); +var pipelineRequest_js_1 = __nccwpck_require__(61605); Object.defineProperty(exports, "createPipelineRequest", ({ enumerable: true, get: function () { return pipelineRequest_js_1.createPipelineRequest; } })); -var pipeline_js_1 = __nccwpck_require__(95405); +var pipeline_js_1 = __nccwpck_require__(53390); Object.defineProperty(exports, "createEmptyPipeline", ({ enumerable: true, get: function () { return pipeline_js_1.createEmptyPipeline; } })); -var restError_js_1 = __nccwpck_require__(45227); +var restError_js_1 = __nccwpck_require__(79058); Object.defineProperty(exports, "RestError", ({ enumerable: true, get: function () { return restError_js_1.RestError; } })); Object.defineProperty(exports, "isRestError", ({ enumerable: true, get: function () { return restError_js_1.isRestError; } })); -var bytesEncoding_js_1 = __nccwpck_require__(28482); +var bytesEncoding_js_1 = __nccwpck_require__(28917); Object.defineProperty(exports, "stringToUint8Array", ({ enumerable: true, get: function () { return bytesEncoding_js_1.stringToUint8Array; } })); Object.defineProperty(exports, "uint8ArrayToString", ({ enumerable: true, get: function () { return bytesEncoding_js_1.uint8ArrayToString; } })); -var defaultHttpClient_js_1 = __nccwpck_require__(51045); +var defaultHttpClient_js_1 = __nccwpck_require__(41264); Object.defineProperty(exports, "createDefaultHttpClient", ({ enumerable: true, get: function () { return defaultHttpClient_js_1.createDefaultHttpClient; } })); -var getClient_js_1 = __nccwpck_require__(42468); +var getClient_js_1 = __nccwpck_require__(20587); Object.defineProperty(exports, "getClient", ({ enumerable: true, get: function () { return getClient_js_1.getClient; } })); -var operationOptionHelpers_js_1 = __nccwpck_require__(85470); +var operationOptionHelpers_js_1 = __nccwpck_require__(82831); Object.defineProperty(exports, "operationOptionsToRequestParameters", ({ enumerable: true, get: function () { return operationOptionHelpers_js_1.operationOptionsToRequestParameters; } })); -var restError_js_2 = __nccwpck_require__(31835); +var restError_js_2 = __nccwpck_require__(26920); Object.defineProperty(exports, "createRestError", ({ enumerable: true, get: function () { return restError_js_2.createRestError; } })); //# sourceMappingURL=index.js.map /***/ }), -/***/ 10009: +/***/ 76488: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -83395,20 +83340,20 @@ Object.defineProperty(exports, "createRestError", ({ enumerable: true, get: func // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.logger = void 0; -const logger_js_1 = __nccwpck_require__(96342); +const logger_js_1 = __nccwpck_require__(34135); exports.logger = (0, logger_js_1.createClientLogger)("ts-http-runtime"); //# sourceMappingURL=log.js.map /***/ }), -/***/ 90087: +/***/ 91424: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { // Copyright (c) Microsoft Corporation. // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); -const log_js_1 = __nccwpck_require__(65682); +const log_js_1 = __nccwpck_require__(60513); const debugEnvVariable = (typeof process !== "undefined" && process.env && process.env.DEBUG) || undefined; let enabledString; let enabledNamespaces = []; @@ -83429,13 +83374,14 @@ function enable(namespaces) { enabledString = namespaces; enabledNamespaces = []; skippedNamespaces = []; - const namespaceList = namespaces.split(",").map((ns) => ns.trim()); + const wildcard = /\*/g; + const namespaceList = namespaces.split(",").map((ns) => ns.trim().replace(wildcard, ".*?")); for (const ns of namespaceList) { if (ns.startsWith("-")) { - skippedNamespaces.push(ns.substring(1)); + skippedNamespaces.push(new RegExp(`^${ns.substr(1)}$`)); } else { - enabledNamespaces.push(ns); + enabledNamespaces.push(new RegExp(`^${ns}$`)); } } for (const instance of debuggers) { @@ -83447,110 +83393,17 @@ function enabled(namespace) { return true; } for (const skipped of skippedNamespaces) { - if (namespaceMatches(namespace, skipped)) { + if (skipped.test(namespace)) { return false; } } for (const enabledNamespace of enabledNamespaces) { - if (namespaceMatches(namespace, enabledNamespace)) { + if (enabledNamespace.test(namespace)) { return true; } } return false; } -/** - * Given a namespace, check if it matches a pattern. - * Patterns only have a single wildcard character which is *. - * The behavior of * is that it matches zero or more other characters. - */ -function namespaceMatches(namespace, patternToMatch) { - // simple case, no pattern matching required - if (patternToMatch.indexOf("*") === -1) { - return namespace === patternToMatch; - } - let pattern = patternToMatch; - // normalize successive * if needed - if (patternToMatch.indexOf("**") !== -1) { - const patternParts = []; - let lastCharacter = ""; - for (const character of patternToMatch) { - if (character === "*" && lastCharacter === "*") { - continue; - } - else { - lastCharacter = character; - patternParts.push(character); - } - } - pattern = patternParts.join(""); - } - let namespaceIndex = 0; - let patternIndex = 0; - const patternLength = pattern.length; - const namespaceLength = namespace.length; - let lastWildcard = -1; - let lastWildcardNamespace = -1; - while (namespaceIndex < namespaceLength && patternIndex < patternLength) { - if (pattern[patternIndex] === "*") { - lastWildcard = patternIndex; - patternIndex++; - if (patternIndex === patternLength) { - // if wildcard is the last character, it will match the remaining namespace string - return true; - } - // now we let the wildcard eat characters until we match the next literal in the pattern - while (namespace[namespaceIndex] !== pattern[patternIndex]) { - namespaceIndex++; - // reached the end of the namespace without a match - if (namespaceIndex === namespaceLength) { - return false; - } - } - // now that we have a match, let's try to continue on - // however, it's possible we could find a later match - // so keep a reference in case we have to backtrack - lastWildcardNamespace = namespaceIndex; - namespaceIndex++; - patternIndex++; - continue; - } - else if (pattern[patternIndex] === namespace[namespaceIndex]) { - // simple case: literal pattern matches so keep going - patternIndex++; - namespaceIndex++; - } - else if (lastWildcard >= 0) { - // special case: we don't have a literal match, but there is a previous wildcard - // which we can backtrack to and try having the wildcard eat the match instead - patternIndex = lastWildcard + 1; - namespaceIndex = lastWildcardNamespace + 1; - // we've reached the end of the namespace without a match - if (namespaceIndex === namespaceLength) { - return false; - } - // similar to the previous logic, let's keep going until we find the next literal match - while (namespace[namespaceIndex] !== pattern[patternIndex]) { - namespaceIndex++; - if (namespaceIndex === namespaceLength) { - return false; - } - } - lastWildcardNamespace = namespaceIndex; - namespaceIndex++; - patternIndex++; - continue; - } - else { - return false; - } - } - const namespaceDone = namespaceIndex === namespace.length; - const patternDone = patternIndex === pattern.length; - // this is to detect the case of an unneeded final wildcard - // e.g. the pattern `ab*` should match the string `ab` - const trailingWildCard = patternIndex === pattern.length - 1 && pattern[patternIndex] === "*"; - return namespaceDone && (patternDone || trailingWildCard); -} function disable() { const result = enabledString || ""; enable(""); @@ -83594,7 +83447,7 @@ exports["default"] = debugObj; /***/ }), -/***/ 49647: +/***/ 5334: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -83602,13 +83455,13 @@ exports["default"] = debugObj; // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.createLoggerContext = void 0; -var logger_js_1 = __nccwpck_require__(96342); +var logger_js_1 = __nccwpck_require__(34135); Object.defineProperty(exports, "createLoggerContext", ({ enumerable: true, get: function () { return logger_js_1.createLoggerContext; } })); //# sourceMappingURL=internal.js.map /***/ }), -/***/ 65682: +/***/ 60513: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -83619,15 +83472,15 @@ exports.log = log; const tslib_1 = __nccwpck_require__(31577); const node_os_1 = __nccwpck_require__(48161); const node_util_1 = tslib_1.__importDefault(__nccwpck_require__(57975)); -const node_process_1 = tslib_1.__importDefault(__nccwpck_require__(1708)); +const process = tslib_1.__importStar(__nccwpck_require__(1708)); function log(message, ...args) { - node_process_1.default.stderr.write(`${node_util_1.default.format(message, ...args)}${node_os_1.EOL}`); + process.stderr.write(`${node_util_1.default.format(message, ...args)}${node_os_1.EOL}`); } //# sourceMappingURL=log.js.map /***/ }), -/***/ 96342: +/***/ 34135: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -83640,7 +83493,7 @@ exports.setLogLevel = setLogLevel; exports.getLogLevel = getLogLevel; exports.createClientLogger = createClientLogger; const tslib_1 = __nccwpck_require__(31577); -const debug_js_1 = tslib_1.__importDefault(__nccwpck_require__(90087)); +const debug_js_1 = tslib_1.__importDefault(__nccwpck_require__(91424)); const TYPESPEC_RUNTIME_LOG_LEVELS = ["verbose", "info", "warning", "error"]; const levelMap = { verbose: 400, @@ -83766,7 +83619,7 @@ function createClientLogger(namespace) { /***/ }), -/***/ 77860: +/***/ 93003: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -83776,15 +83629,15 @@ Object.defineProperty(exports, "__esModule", ({ value: true })); exports.getBodyLength = getBodyLength; exports.createNodeHttpClient = createNodeHttpClient; const tslib_1 = __nccwpck_require__(31577); -const node_http_1 = tslib_1.__importDefault(__nccwpck_require__(37067)); -const node_https_1 = tslib_1.__importDefault(__nccwpck_require__(44708)); -const node_zlib_1 = tslib_1.__importDefault(__nccwpck_require__(38522)); +const http = tslib_1.__importStar(__nccwpck_require__(37067)); +const https = tslib_1.__importStar(__nccwpck_require__(44708)); +const zlib = tslib_1.__importStar(__nccwpck_require__(38522)); const node_stream_1 = __nccwpck_require__(57075); -const AbortError_js_1 = __nccwpck_require__(61865); -const httpHeaders_js_1 = __nccwpck_require__(82345); -const restError_js_1 = __nccwpck_require__(45227); -const log_js_1 = __nccwpck_require__(10009); -const sanitizer_js_1 = __nccwpck_require__(83839); +const AbortError_js_1 = __nccwpck_require__(84260); +const httpHeaders_js_1 = __nccwpck_require__(43688); +const restError_js_1 = __nccwpck_require__(79058); +const log_js_1 = __nccwpck_require__(76488); +const sanitizer_js_1 = __nccwpck_require__(56620); const DEFAULT_TLS_SETTINGS = {}; function isReadableStream(body) { return body && typeof body.pipe === "function"; @@ -83809,8 +83662,6 @@ function isArrayBuffer(body) { return body && typeof body.byteLength === "number"; } class ReportTransform extends node_stream_1.Transform { - loadedBytes = 0; - progressCallback; // eslint-disable-next-line @typescript-eslint/no-unsafe-function-type _transform(chunk, _encoding, callback) { this.push(chunk); @@ -83825,6 +83676,7 @@ class ReportTransform extends node_stream_1.Transform { } constructor(progressCallback) { super(); + this.loadedBytes = 0; this.progressCallback = progressCallback; } } @@ -83833,13 +83685,15 @@ class ReportTransform extends node_stream_1.Transform { * @internal */ class NodeHttpClient { - cachedHttpAgent; - cachedHttpsAgents = new WeakMap(); + constructor() { + this.cachedHttpsAgents = new WeakMap(); + } /** * Makes a request over an underlying transport layer and returns the response. * @param request - The request to be made. */ async sendRequest(request) { + var _a, _b, _c; const abortController = new AbortController(); let abortListener; if (request.abortSignal) { @@ -83862,7 +83716,7 @@ class NodeHttpClient { }, request.timeout); } const acceptEncoding = request.headers.get("Accept-Encoding"); - const shouldDecompress = acceptEncoding?.includes("gzip") || acceptEncoding?.includes("deflate"); + const shouldDecompress = (acceptEncoding === null || acceptEncoding === void 0 ? void 0 : acceptEncoding.includes("gzip")) || (acceptEncoding === null || acceptEncoding === void 0 ? void 0 : acceptEncoding.includes("deflate")); let body = typeof request.body === "function" ? request.body() : request.body; if (body && !request.headers.has("Content-Length")) { const bodyLength = getBodyLength(body); @@ -83891,7 +83745,7 @@ class NodeHttpClient { clearTimeout(timeoutId); } const headers = getResponseHeaders(res); - const status = res.statusCode ?? 0; + const status = (_a = res.statusCode) !== null && _a !== void 0 ? _a : 0; const response = { status, headers, @@ -83917,8 +83771,8 @@ class NodeHttpClient { } if ( // Value of POSITIVE_INFINITY in streamResponseStatusCodes is considered as any status code - request.streamResponseStatusCodes?.has(Number.POSITIVE_INFINITY) || - request.streamResponseStatusCodes?.has(response.status)) { + ((_b = request.streamResponseStatusCodes) === null || _b === void 0 ? void 0 : _b.has(Number.POSITIVE_INFINITY)) || + ((_c = request.streamResponseStatusCodes) === null || _c === void 0 ? void 0 : _c.has(response.status))) { response.readableStreamBody = responseStream; } else { @@ -83939,9 +83793,10 @@ class NodeHttpClient { } Promise.all([uploadStreamDone, downloadStreamDone]) .then(() => { + var _a; // eslint-disable-next-line promise/always-return if (abortListener) { - request.abortSignal?.removeEventListener("abort", abortListener); + (_a = request.abortSignal) === null || _a === void 0 ? void 0 : _a.removeEventListener("abort", abortListener); } }) .catch((e) => { @@ -83951,25 +83806,19 @@ class NodeHttpClient { } } makeRequest(request, abortController, body) { + var _a; const url = new URL(request.url); const isInsecure = url.protocol !== "https:"; if (isInsecure && !request.allowInsecureConnection) { throw new Error(`Cannot connect to ${request.url} while allowInsecureConnection is false.`); } - const agent = request.agent ?? this.getOrCreateAgent(request, isInsecure); - const options = { - agent, - hostname: url.hostname, - path: `${url.pathname}${url.search}`, - port: url.port, - method: request.method, - headers: request.headers.toJSON({ preserveCase: true }), - ...request.requestOverrides, - }; + const agent = (_a = request.agent) !== null && _a !== void 0 ? _a : this.getOrCreateAgent(request, isInsecure); + const options = Object.assign({ agent, hostname: url.hostname, path: `${url.pathname}${url.search}`, port: url.port, method: request.method, headers: request.headers.toJSON({ preserveCase: true }) }, request.requestOverrides); return new Promise((resolve, reject) => { - const req = isInsecure ? node_http_1.default.request(options, resolve) : node_https_1.default.request(options, resolve); + const req = isInsecure ? http.request(options, resolve) : https.request(options, resolve); req.once("error", (err) => { - reject(new restError_js_1.RestError(err.message, { code: err.code ?? restError_js_1.RestError.REQUEST_SEND_ERROR, request })); + var _a; + reject(new restError_js_1.RestError(err.message, { code: (_a = err.code) !== null && _a !== void 0 ? _a : restError_js_1.RestError.REQUEST_SEND_ERROR, request })); }); abortController.signal.addEventListener("abort", () => { const abortError = new AbortError_js_1.AbortError("The operation was aborted. Rejecting from abort signal callback while making request."); @@ -83998,16 +83847,17 @@ class NodeHttpClient { }); } getOrCreateAgent(request, isInsecure) { + var _a; const disableKeepAlive = request.disableKeepAlive; // Handle Insecure requests first if (isInsecure) { if (disableKeepAlive) { // keepAlive:false is the default so we don't need a custom Agent - return node_http_1.default.globalAgent; + return http.globalAgent; } if (!this.cachedHttpAgent) { // If there is no cached agent create a new one and cache it. - this.cachedHttpAgent = new node_http_1.default.Agent({ keepAlive: true }); + this.cachedHttpAgent = new http.Agent({ keepAlive: true }); } return this.cachedHttpAgent; } @@ -84015,10 +83865,10 @@ class NodeHttpClient { if (disableKeepAlive && !request.tlsSettings) { // When there are no tlsSettings and keepAlive is false // we don't need a custom agent - return node_https_1.default.globalAgent; + return https.globalAgent; } // We use the tlsSettings to index cached clients - const tlsSettings = request.tlsSettings ?? DEFAULT_TLS_SETTINGS; + const tlsSettings = (_a = request.tlsSettings) !== null && _a !== void 0 ? _a : DEFAULT_TLS_SETTINGS; // Get the cached agent or create a new one with the // provided values for keepAlive and tlsSettings let agent = this.cachedHttpsAgents.get(tlsSettings); @@ -84026,12 +83876,9 @@ class NodeHttpClient { return agent; } log_js_1.logger.info("No cached TLS Agent exist, creating a new Agent"); - agent = new node_https_1.default.Agent({ + agent = new https.Agent(Object.assign({ // keepAlive is true if disableKeepAlive is false. - keepAlive: !disableKeepAlive, - // Since we are spreading, if no tslSettings were provided, nothing is added to the agent options. - ...tlsSettings, - }); + keepAlive: !disableKeepAlive }, tlsSettings)); this.cachedHttpsAgents.set(tlsSettings, agent); return agent; } @@ -84055,12 +83902,12 @@ function getResponseHeaders(res) { function getDecodedResponseStream(stream, headers) { const contentEncoding = headers.get("Content-Encoding"); if (contentEncoding === "gzip") { - const unzip = node_zlib_1.default.createGunzip(); + const unzip = zlib.createGunzip(); stream.pipe(unzip); return unzip; } else if (contentEncoding === "deflate") { - const inflate = node_zlib_1.default.createInflate(); + const inflate = zlib.createInflate(); stream.pipe(inflate); return inflate; } @@ -84081,7 +83928,7 @@ function streamToText(stream) { resolve(Buffer.concat(buffer).toString("utf8")); }); stream.on("error", (e) => { - if (e && e?.name === "AbortError") { + if (e && (e === null || e === void 0 ? void 0 : e.name) === "AbortError") { reject(e); } else { @@ -84124,7 +83971,7 @@ function createNodeHttpClient() { /***/ }), -/***/ 95405: +/***/ 53390: /***/ ((__unused_webpack_module, exports) => { @@ -84139,10 +83986,10 @@ const ValidPhaseNames = new Set(["Deserialize", "Serialize", "Retry", "Sign"]); * @internal */ class HttpPipeline { - _policies = []; - _orderedPolicies; constructor(policies) { - this._policies = policies?.slice(0) ?? []; + var _a; + this._policies = []; + this._policies = (_a = policies === null || policies === void 0 ? void 0 : policies.slice(0)) !== null && _a !== void 0 ? _a : []; this._orderedPolicies = undefined; } addPolicy(policy, options = {}) { @@ -84395,7 +84242,7 @@ function createEmptyPipeline() { /***/ }), -/***/ 93244: +/***/ 61605: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -84403,46 +84250,28 @@ function createEmptyPipeline() { // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.createPipelineRequest = createPipelineRequest; -const httpHeaders_js_1 = __nccwpck_require__(82345); -const uuidUtils_js_1 = __nccwpck_require__(64052); +const httpHeaders_js_1 = __nccwpck_require__(43688); +const uuidUtils_js_1 = __nccwpck_require__(90955); class PipelineRequestImpl { - url; - method; - headers; - timeout; - withCredentials; - body; - multipartBody; - formData; - streamResponseStatusCodes; - enableBrowserStreams; - proxySettings; - disableKeepAlive; - abortSignal; - requestId; - allowInsecureConnection; - onUploadProgress; - onDownloadProgress; - requestOverrides; - authSchemes; constructor(options) { + var _a, _b, _c, _d, _e, _f, _g; this.url = options.url; this.body = options.body; - this.headers = options.headers ?? (0, httpHeaders_js_1.createHttpHeaders)(); - this.method = options.method ?? "GET"; - this.timeout = options.timeout ?? 0; + this.headers = (_a = options.headers) !== null && _a !== void 0 ? _a : (0, httpHeaders_js_1.createHttpHeaders)(); + this.method = (_b = options.method) !== null && _b !== void 0 ? _b : "GET"; + this.timeout = (_c = options.timeout) !== null && _c !== void 0 ? _c : 0; this.multipartBody = options.multipartBody; this.formData = options.formData; - this.disableKeepAlive = options.disableKeepAlive ?? false; + this.disableKeepAlive = (_d = options.disableKeepAlive) !== null && _d !== void 0 ? _d : false; this.proxySettings = options.proxySettings; this.streamResponseStatusCodes = options.streamResponseStatusCodes; - this.withCredentials = options.withCredentials ?? false; + this.withCredentials = (_e = options.withCredentials) !== null && _e !== void 0 ? _e : false; this.abortSignal = options.abortSignal; this.onUploadProgress = options.onUploadProgress; this.onDownloadProgress = options.onDownloadProgress; this.requestId = options.requestId || (0, uuidUtils_js_1.randomUUID)(); - this.allowInsecureConnection = options.allowInsecureConnection ?? false; - this.enableBrowserStreams = options.enableBrowserStreams ?? false; + this.allowInsecureConnection = (_f = options.allowInsecureConnection) !== null && _f !== void 0 ? _f : false; + this.enableBrowserStreams = (_g = options.enableBrowserStreams) !== null && _g !== void 0 ? _g : false; this.requestOverrides = options.requestOverrides; this.authSchemes = options.authSchemes; } @@ -84459,7 +84288,7 @@ function createPipelineRequest(options) { /***/ }), -/***/ 97789: +/***/ 51250: /***/ ((__unused_webpack_module, exports) => { @@ -84491,7 +84320,7 @@ function agentPolicy(agent) { /***/ }), -/***/ 64668: +/***/ 86987: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -84500,7 +84329,7 @@ function agentPolicy(agent) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.apiKeyAuthenticationPolicyName = void 0; exports.apiKeyAuthenticationPolicy = apiKeyAuthenticationPolicy; -const checkInsecureConnection_js_1 = __nccwpck_require__(67027); +const checkInsecureConnection_js_1 = __nccwpck_require__(75626); /** * Name of the API Key Authentication Policy */ @@ -84512,9 +84341,10 @@ function apiKeyAuthenticationPolicy(options) { return { name: exports.apiKeyAuthenticationPolicyName, async sendRequest(request, next) { + var _a, _b; // Ensure allowInsecureConnection is explicitly set when sending request to non-https URLs (0, checkInsecureConnection_js_1.ensureSecureConnection)(request, options); - const scheme = (request.authSchemes ?? options.authSchemes)?.find((x) => x.kind === "apiKey"); + const scheme = (_b = ((_a = request.authSchemes) !== null && _a !== void 0 ? _a : options.authSchemes)) === null || _b === void 0 ? void 0 : _b.find((x) => x.kind === "apiKey"); // Skip adding authentication header if no API key authentication scheme is found if (!scheme) { return next(request); @@ -84531,7 +84361,7 @@ function apiKeyAuthenticationPolicy(options) { /***/ }), -/***/ 42229: +/***/ 6664: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -84540,8 +84370,8 @@ function apiKeyAuthenticationPolicy(options) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.basicAuthenticationPolicyName = void 0; exports.basicAuthenticationPolicy = basicAuthenticationPolicy; -const bytesEncoding_js_1 = __nccwpck_require__(28482); -const checkInsecureConnection_js_1 = __nccwpck_require__(67027); +const bytesEncoding_js_1 = __nccwpck_require__(28917); +const checkInsecureConnection_js_1 = __nccwpck_require__(75626); /** * Name of the Basic Authentication Policy */ @@ -84553,9 +84383,10 @@ function basicAuthenticationPolicy(options) { return { name: exports.basicAuthenticationPolicyName, async sendRequest(request, next) { + var _a, _b; // Ensure allowInsecureConnection is explicitly set when sending request to non-https URLs (0, checkInsecureConnection_js_1.ensureSecureConnection)(request, options); - const scheme = (request.authSchemes ?? options.authSchemes)?.find((x) => x.kind === "http" && x.scheme === "basic"); + const scheme = (_b = ((_a = request.authSchemes) !== null && _a !== void 0 ? _a : options.authSchemes)) === null || _b === void 0 ? void 0 : _b.find((x) => x.kind === "http" && x.scheme === "basic"); // Skip adding authentication header if no basic authentication scheme is found if (!scheme) { return next(request); @@ -84571,7 +84402,7 @@ function basicAuthenticationPolicy(options) { /***/ }), -/***/ 89434: +/***/ 66849: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -84580,7 +84411,7 @@ function basicAuthenticationPolicy(options) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.bearerAuthenticationPolicyName = void 0; exports.bearerAuthenticationPolicy = bearerAuthenticationPolicy; -const checkInsecureConnection_js_1 = __nccwpck_require__(67027); +const checkInsecureConnection_js_1 = __nccwpck_require__(75626); /** * Name of the Bearer Authentication Policy */ @@ -84592,9 +84423,10 @@ function bearerAuthenticationPolicy(options) { return { name: exports.bearerAuthenticationPolicyName, async sendRequest(request, next) { + var _a, _b; // Ensure allowInsecureConnection is explicitly set when sending request to non-https URLs (0, checkInsecureConnection_js_1.ensureSecureConnection)(request, options); - const scheme = (request.authSchemes ?? options.authSchemes)?.find((x) => x.kind === "http" && x.scheme === "bearer"); + const scheme = (_b = ((_a = request.authSchemes) !== null && _a !== void 0 ? _a : options.authSchemes)) === null || _b === void 0 ? void 0 : _b.find((x) => x.kind === "http" && x.scheme === "bearer"); // Skip adding authentication header if no bearer authentication scheme is found if (!scheme) { return next(request); @@ -84611,7 +84443,7 @@ function bearerAuthenticationPolicy(options) { /***/ }), -/***/ 67027: +/***/ 75626: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -84619,7 +84451,7 @@ function bearerAuthenticationPolicy(options) { // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.ensureSecureConnection = ensureSecureConnection; -const log_js_1 = __nccwpck_require__(10009); +const log_js_1 = __nccwpck_require__(76488); // Ensure the warining is only emitted once let insecureConnectionWarningEmmitted = false; /** @@ -84647,7 +84479,7 @@ function allowInsecureConnection(request, options) { function emitInsecureConnectionWarning() { const warning = "Sending token over insecure transport. Assume any token issued is compromised."; log_js_1.logger.warning(warning); - if (typeof process?.emitWarning === "function" && !insecureConnectionWarningEmmitted) { + if (typeof (process === null || process === void 0 ? void 0 : process.emitWarning) === "function" && !insecureConnectionWarningEmmitted) { insecureConnectionWarningEmmitted = true; process.emitWarning(warning); } @@ -84670,7 +84502,7 @@ function ensureSecureConnection(request, options) { /***/ }), -/***/ 18912: +/***/ 71143: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -84679,7 +84511,7 @@ function ensureSecureConnection(request, options) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.oauth2AuthenticationPolicyName = void 0; exports.oauth2AuthenticationPolicy = oauth2AuthenticationPolicy; -const checkInsecureConnection_js_1 = __nccwpck_require__(67027); +const checkInsecureConnection_js_1 = __nccwpck_require__(75626); /** * Name of the OAuth2 Authentication Policy */ @@ -84691,9 +84523,10 @@ function oauth2AuthenticationPolicy(options) { return { name: exports.oauth2AuthenticationPolicyName, async sendRequest(request, next) { + var _a, _b; // Ensure allowInsecureConnection is explicitly set when sending request to non-https URLs (0, checkInsecureConnection_js_1.ensureSecureConnection)(request, options); - const scheme = (request.authSchemes ?? options.authSchemes)?.find((x) => x.kind === "oauth2"); + const scheme = (_b = ((_a = request.authSchemes) !== null && _a !== void 0 ? _a : options.authSchemes)) === null || _b === void 0 ? void 0 : _b.find((x) => x.kind === "oauth2"); // Skip adding authentication header if no OAuth2 authentication scheme is found if (!scheme) { return next(request); @@ -84710,7 +84543,7 @@ function oauth2AuthenticationPolicy(options) { /***/ }), -/***/ 42878: +/***/ 29815: /***/ ((__unused_webpack_module, exports) => { @@ -84743,7 +84576,7 @@ function decompressResponsePolicy() { /***/ }), -/***/ 50247: +/***/ 14786: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -84752,10 +84585,10 @@ function decompressResponsePolicy() { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.defaultRetryPolicyName = void 0; exports.defaultRetryPolicy = defaultRetryPolicy; -const exponentialRetryStrategy_js_1 = __nccwpck_require__(86269); -const throttlingRetryStrategy_js_1 = __nccwpck_require__(60373); -const retryPolicy_js_1 = __nccwpck_require__(54878); -const constants_js_1 = __nccwpck_require__(4202); +const exponentialRetryStrategy_js_1 = __nccwpck_require__(22714); +const throttlingRetryStrategy_js_1 = __nccwpck_require__(7524); +const retryPolicy_js_1 = __nccwpck_require__(67021); +const constants_js_1 = __nccwpck_require__(88819); /** * Name of the {@link defaultRetryPolicy} */ @@ -84767,10 +84600,11 @@ exports.defaultRetryPolicyName = "defaultRetryPolicy"; * - Or otherwise if the outgoing request fails, it will retry with an exponentially increasing delay. */ function defaultRetryPolicy(options = {}) { + var _a; return { name: exports.defaultRetryPolicyName, sendRequest: (0, retryPolicy_js_1.retryPolicy)([(0, throttlingRetryStrategy_js_1.throttlingRetryStrategy)(), (0, exponentialRetryStrategy_js_1.exponentialRetryStrategy)(options)], { - maxRetries: options.maxRetries ?? constants_js_1.DEFAULT_RETRY_POLICY_COUNT, + maxRetries: (_a = options.maxRetries) !== null && _a !== void 0 ? _a : constants_js_1.DEFAULT_RETRY_POLICY_COUNT, }).sendRequest, }; } @@ -84778,7 +84612,7 @@ function defaultRetryPolicy(options = {}) { /***/ }), -/***/ 72449: +/***/ 28332: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -84787,9 +84621,9 @@ function defaultRetryPolicy(options = {}) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.exponentialRetryPolicyName = void 0; exports.exponentialRetryPolicy = exponentialRetryPolicy; -const exponentialRetryStrategy_js_1 = __nccwpck_require__(86269); -const retryPolicy_js_1 = __nccwpck_require__(54878); -const constants_js_1 = __nccwpck_require__(4202); +const exponentialRetryStrategy_js_1 = __nccwpck_require__(22714); +const retryPolicy_js_1 = __nccwpck_require__(67021); +const constants_js_1 = __nccwpck_require__(88819); /** * The programmatic identifier of the exponentialRetryPolicy. */ @@ -84799,20 +84633,18 @@ exports.exponentialRetryPolicyName = "exponentialRetryPolicy"; * @param options - Options that configure retry logic. */ function exponentialRetryPolicy(options = {}) { + var _a; return (0, retryPolicy_js_1.retryPolicy)([ - (0, exponentialRetryStrategy_js_1.exponentialRetryStrategy)({ - ...options, - ignoreSystemErrors: true, - }), + (0, exponentialRetryStrategy_js_1.exponentialRetryStrategy)(Object.assign(Object.assign({}, options), { ignoreSystemErrors: true })), ], { - maxRetries: options.maxRetries ?? constants_js_1.DEFAULT_RETRY_POLICY_COUNT, + maxRetries: (_a = options.maxRetries) !== null && _a !== void 0 ? _a : constants_js_1.DEFAULT_RETRY_POLICY_COUNT, }); } //# sourceMappingURL=exponentialRetryPolicy.js.map /***/ }), -/***/ 51888: +/***/ 70337: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -84821,17 +84653,18 @@ function exponentialRetryPolicy(options = {}) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.formDataPolicyName = void 0; exports.formDataPolicy = formDataPolicy; -const bytesEncoding_js_1 = __nccwpck_require__(28482); -const checkEnvironment_js_1 = __nccwpck_require__(31407); -const httpHeaders_js_1 = __nccwpck_require__(82345); +const bytesEncoding_js_1 = __nccwpck_require__(28917); +const checkEnvironment_js_1 = __nccwpck_require__(98402); +const httpHeaders_js_1 = __nccwpck_require__(43688); /** * The programmatic identifier of the formDataPolicy. */ exports.formDataPolicyName = "formDataPolicy"; function formDataToFormDataMap(formData) { + var _a; const formDataMap = {}; for (const [key, value] of formData.entries()) { - formDataMap[key] ??= []; + (_a = formDataMap[key]) !== null && _a !== void 0 ? _a : (formDataMap[key] = []); formDataMap[key].push(value); } return formDataMap; @@ -84882,7 +84715,7 @@ async function prepareFormData(formData, request) { // content type is specified and is not multipart/form-data. Exit. return; } - request.headers.set("Content-Type", contentType ?? "multipart/form-data"); + request.headers.set("Content-Type", contentType !== null && contentType !== void 0 ? contentType : "multipart/form-data"); // set body to MultipartRequestBody using content from FormDataMap const parts = []; for (const [fieldName, values] of Object.entries(formData)) { @@ -84918,7 +84751,7 @@ async function prepareFormData(formData, request) { /***/ }), -/***/ 37717: +/***/ 25068: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -84926,53 +84759,53 @@ async function prepareFormData(formData, request) { // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.userAgentPolicyName = exports.userAgentPolicy = exports.tlsPolicyName = exports.tlsPolicy = exports.redirectPolicyName = exports.redirectPolicy = exports.getDefaultProxySettings = exports.proxyPolicyName = exports.proxyPolicy = exports.multipartPolicyName = exports.multipartPolicy = exports.logPolicyName = exports.logPolicy = exports.formDataPolicyName = exports.formDataPolicy = exports.throttlingRetryPolicyName = exports.throttlingRetryPolicy = exports.systemErrorRetryPolicyName = exports.systemErrorRetryPolicy = exports.retryPolicy = exports.exponentialRetryPolicyName = exports.exponentialRetryPolicy = exports.defaultRetryPolicyName = exports.defaultRetryPolicy = exports.decompressResponsePolicyName = exports.decompressResponsePolicy = exports.agentPolicyName = exports.agentPolicy = void 0; -var agentPolicy_js_1 = __nccwpck_require__(97789); +var agentPolicy_js_1 = __nccwpck_require__(51250); Object.defineProperty(exports, "agentPolicy", ({ enumerable: true, get: function () { return agentPolicy_js_1.agentPolicy; } })); Object.defineProperty(exports, "agentPolicyName", ({ enumerable: true, get: function () { return agentPolicy_js_1.agentPolicyName; } })); -var decompressResponsePolicy_js_1 = __nccwpck_require__(42878); +var decompressResponsePolicy_js_1 = __nccwpck_require__(29815); Object.defineProperty(exports, "decompressResponsePolicy", ({ enumerable: true, get: function () { return decompressResponsePolicy_js_1.decompressResponsePolicy; } })); Object.defineProperty(exports, "decompressResponsePolicyName", ({ enumerable: true, get: function () { return decompressResponsePolicy_js_1.decompressResponsePolicyName; } })); -var defaultRetryPolicy_js_1 = __nccwpck_require__(50247); +var defaultRetryPolicy_js_1 = __nccwpck_require__(14786); Object.defineProperty(exports, "defaultRetryPolicy", ({ enumerable: true, get: function () { return defaultRetryPolicy_js_1.defaultRetryPolicy; } })); Object.defineProperty(exports, "defaultRetryPolicyName", ({ enumerable: true, get: function () { return defaultRetryPolicy_js_1.defaultRetryPolicyName; } })); -var exponentialRetryPolicy_js_1 = __nccwpck_require__(72449); +var exponentialRetryPolicy_js_1 = __nccwpck_require__(28332); Object.defineProperty(exports, "exponentialRetryPolicy", ({ enumerable: true, get: function () { return exponentialRetryPolicy_js_1.exponentialRetryPolicy; } })); Object.defineProperty(exports, "exponentialRetryPolicyName", ({ enumerable: true, get: function () { return exponentialRetryPolicy_js_1.exponentialRetryPolicyName; } })); -var retryPolicy_js_1 = __nccwpck_require__(54878); +var retryPolicy_js_1 = __nccwpck_require__(67021); Object.defineProperty(exports, "retryPolicy", ({ enumerable: true, get: function () { return retryPolicy_js_1.retryPolicy; } })); -var systemErrorRetryPolicy_js_1 = __nccwpck_require__(25767); +var systemErrorRetryPolicy_js_1 = __nccwpck_require__(79998); Object.defineProperty(exports, "systemErrorRetryPolicy", ({ enumerable: true, get: function () { return systemErrorRetryPolicy_js_1.systemErrorRetryPolicy; } })); Object.defineProperty(exports, "systemErrorRetryPolicyName", ({ enumerable: true, get: function () { return systemErrorRetryPolicy_js_1.systemErrorRetryPolicyName; } })); -var throttlingRetryPolicy_js_1 = __nccwpck_require__(90383); +var throttlingRetryPolicy_js_1 = __nccwpck_require__(48492); Object.defineProperty(exports, "throttlingRetryPolicy", ({ enumerable: true, get: function () { return throttlingRetryPolicy_js_1.throttlingRetryPolicy; } })); Object.defineProperty(exports, "throttlingRetryPolicyName", ({ enumerable: true, get: function () { return throttlingRetryPolicy_js_1.throttlingRetryPolicyName; } })); -var formDataPolicy_js_1 = __nccwpck_require__(51888); +var formDataPolicy_js_1 = __nccwpck_require__(70337); Object.defineProperty(exports, "formDataPolicy", ({ enumerable: true, get: function () { return formDataPolicy_js_1.formDataPolicy; } })); Object.defineProperty(exports, "formDataPolicyName", ({ enumerable: true, get: function () { return formDataPolicy_js_1.formDataPolicyName; } })); -var logPolicy_js_1 = __nccwpck_require__(65598); +var logPolicy_js_1 = __nccwpck_require__(85613); Object.defineProperty(exports, "logPolicy", ({ enumerable: true, get: function () { return logPolicy_js_1.logPolicy; } })); Object.defineProperty(exports, "logPolicyName", ({ enumerable: true, get: function () { return logPolicy_js_1.logPolicyName; } })); -var multipartPolicy_js_1 = __nccwpck_require__(35384); +var multipartPolicy_js_1 = __nccwpck_require__(75303); Object.defineProperty(exports, "multipartPolicy", ({ enumerable: true, get: function () { return multipartPolicy_js_1.multipartPolicy; } })); Object.defineProperty(exports, "multipartPolicyName", ({ enumerable: true, get: function () { return multipartPolicy_js_1.multipartPolicyName; } })); -var proxyPolicy_js_1 = __nccwpck_require__(33996); +var proxyPolicy_js_1 = __nccwpck_require__(53511); Object.defineProperty(exports, "proxyPolicy", ({ enumerable: true, get: function () { return proxyPolicy_js_1.proxyPolicy; } })); Object.defineProperty(exports, "proxyPolicyName", ({ enumerable: true, get: function () { return proxyPolicy_js_1.proxyPolicyName; } })); Object.defineProperty(exports, "getDefaultProxySettings", ({ enumerable: true, get: function () { return proxyPolicy_js_1.getDefaultProxySettings; } })); -var redirectPolicy_js_1 = __nccwpck_require__(96318); +var redirectPolicy_js_1 = __nccwpck_require__(56959); Object.defineProperty(exports, "redirectPolicy", ({ enumerable: true, get: function () { return redirectPolicy_js_1.redirectPolicy; } })); Object.defineProperty(exports, "redirectPolicyName", ({ enumerable: true, get: function () { return redirectPolicy_js_1.redirectPolicyName; } })); -var tlsPolicy_js_1 = __nccwpck_require__(84949); +var tlsPolicy_js_1 = __nccwpck_require__(55726); Object.defineProperty(exports, "tlsPolicy", ({ enumerable: true, get: function () { return tlsPolicy_js_1.tlsPolicy; } })); Object.defineProperty(exports, "tlsPolicyName", ({ enumerable: true, get: function () { return tlsPolicy_js_1.tlsPolicyName; } })); -var userAgentPolicy_js_1 = __nccwpck_require__(22448); +var userAgentPolicy_js_1 = __nccwpck_require__(92375); Object.defineProperty(exports, "userAgentPolicy", ({ enumerable: true, get: function () { return userAgentPolicy_js_1.userAgentPolicy; } })); Object.defineProperty(exports, "userAgentPolicyName", ({ enumerable: true, get: function () { return userAgentPolicy_js_1.userAgentPolicyName; } })); //# sourceMappingURL=internal.js.map /***/ }), -/***/ 65598: +/***/ 85613: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -84981,8 +84814,8 @@ Object.defineProperty(exports, "userAgentPolicyName", ({ enumerable: true, get: Object.defineProperty(exports, "__esModule", ({ value: true })); exports.logPolicyName = void 0; exports.logPolicy = logPolicy; -const log_js_1 = __nccwpck_require__(10009); -const sanitizer_js_1 = __nccwpck_require__(83839); +const log_js_1 = __nccwpck_require__(76488); +const sanitizer_js_1 = __nccwpck_require__(56620); /** * The programmatic identifier of the logPolicy. */ @@ -84992,7 +84825,8 @@ exports.logPolicyName = "logPolicy"; * @param options - Options to configure logPolicy. */ function logPolicy(options = {}) { - const logger = options.logger ?? log_js_1.logger.info; + var _a; + const logger = (_a = options.logger) !== null && _a !== void 0 ? _a : log_js_1.logger.info; const sanitizer = new sanitizer_js_1.Sanitizer({ additionalAllowedHeaderNames: options.additionalAllowedHeaderNames, additionalAllowedQueryParameters: options.additionalAllowedQueryParameters, @@ -85015,7 +84849,7 @@ function logPolicy(options = {}) { /***/ }), -/***/ 35384: +/***/ 75303: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -85024,10 +84858,10 @@ function logPolicy(options = {}) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.multipartPolicyName = void 0; exports.multipartPolicy = multipartPolicy; -const bytesEncoding_js_1 = __nccwpck_require__(28482); -const typeGuards_js_1 = __nccwpck_require__(90932); -const uuidUtils_js_1 = __nccwpck_require__(64052); -const concat_js_1 = __nccwpck_require__(75142); +const bytesEncoding_js_1 = __nccwpck_require__(28917); +const typeGuards_js_1 = __nccwpck_require__(1093); +const uuidUtils_js_1 = __nccwpck_require__(90955); +const concat_js_1 = __nccwpck_require__(93407); function generateBoundary() { return `----AzSDKFormBoundary${(0, uuidUtils_js_1.randomUUID)()}`; } @@ -85102,6 +84936,7 @@ function multipartPolicy() { return { name: exports.multipartPolicyName, async sendRequest(request, next) { + var _a; if (!request.multipartBody) { return next(request); } @@ -85109,7 +84944,7 @@ function multipartPolicy() { throw new Error("multipartBody and regular body cannot be set at the same time"); } let boundary = request.multipartBody.boundary; - const contentTypeHeader = request.headers.get("Content-Type") ?? "multipart/mixed"; + const contentTypeHeader = (_a = request.headers.get("Content-Type")) !== null && _a !== void 0 ? _a : "multipart/mixed"; const parsedHeader = contentTypeHeader.match(/^(multipart\/[^ ;]+)(?:; *boundary=(.+))?$/); if (!parsedHeader) { throw new Error(`Got multipart request body, but content-type header was not multipart: ${contentTypeHeader}`); @@ -85118,7 +84953,7 @@ function multipartPolicy() { if (parsedBoundary && boundary && parsedBoundary !== boundary) { throw new Error(`Multipart boundary was specified as ${parsedBoundary} in the header, but got ${boundary} in the request body`); } - boundary ??= parsedBoundary; + boundary !== null && boundary !== void 0 ? boundary : (boundary = parsedBoundary); if (boundary) { assertValidBoundary(boundary); } @@ -85136,7 +84971,7 @@ function multipartPolicy() { /***/ }), -/***/ 33996: +/***/ 53511: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -85149,7 +84984,7 @@ exports.getDefaultProxySettings = getDefaultProxySettings; exports.proxyPolicy = proxyPolicy; const https_proxy_agent_1 = __nccwpck_require__(84708); const http_proxy_agent_1 = __nccwpck_require__(64702); -const log_js_1 = __nccwpck_require__(10009); +const log_js_1 = __nccwpck_require__(76488); const HTTPS_PROXY = "HTTPS_PROXY"; const HTTP_PROXY = "HTTP_PROXY"; const ALL_PROXY = "ALL_PROXY"; @@ -85194,7 +85029,7 @@ function isBypassed(uri, noProxyList, bypassedMap) { return false; } const host = new URL(uri).hostname; - if (bypassedMap?.has(host)) { + if (bypassedMap === null || bypassedMap === void 0 ? void 0 : bypassedMap.has(host)) { return bypassedMap.get(host); } let isBypassedFlag = false; @@ -85217,7 +85052,7 @@ function isBypassed(uri, noProxyList, bypassedMap) { } } } - bypassedMap?.set(host, isBypassedFlag); + bypassedMap === null || bypassedMap === void 0 ? void 0 : bypassedMap.set(host, isBypassedFlag); return isBypassedFlag; } function loadNoProxy() { @@ -85267,7 +85102,7 @@ function getUrlFromProxySettings(settings) { try { parsedProxyUrl = new URL(settings.host); } - catch { + catch (_a) { throw new Error(`Expecting a valid host string in proxy settings, but found "${settings.host}".`); } parsedProxyUrl.port = String(settings.port); @@ -85322,9 +85157,10 @@ function proxyPolicy(proxySettings, options) { return { name: exports.proxyPolicyName, async sendRequest(request, next) { + var _a; if (!request.proxySettings && defaultProxy && - !isBypassed(request.url, options?.customNoProxyList ?? exports.globalNoProxyList, options?.customNoProxyList ? undefined : globalBypassedMap)) { + !isBypassed(request.url, (_a = options === null || options === void 0 ? void 0 : options.customNoProxyList) !== null && _a !== void 0 ? _a : exports.globalNoProxyList, (options === null || options === void 0 ? void 0 : options.customNoProxyList) ? undefined : globalBypassedMap)) { setProxyAgentOnRequest(request, cachedAgents, defaultProxy); } else if (request.proxySettings) { @@ -85338,7 +85174,7 @@ function proxyPolicy(proxySettings, options) { /***/ }), -/***/ 96318: +/***/ 56959: /***/ ((__unused_webpack_module, exports) => { @@ -85400,7 +85236,7 @@ async function handleRedirect(next, response, maxRetries, currentRetries = 0) { /***/ }), -/***/ 54878: +/***/ 67021: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -85408,10 +85244,10 @@ async function handleRedirect(next, response, maxRetries, currentRetries = 0) { // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.retryPolicy = retryPolicy; -const helpers_js_1 = __nccwpck_require__(18365); -const AbortError_js_1 = __nccwpck_require__(61865); -const logger_js_1 = __nccwpck_require__(96342); -const constants_js_1 = __nccwpck_require__(4202); +const helpers_js_1 = __nccwpck_require__(19490); +const AbortError_js_1 = __nccwpck_require__(84260); +const logger_js_1 = __nccwpck_require__(34135); +const constants_js_1 = __nccwpck_require__(88819); const retryPolicyLogger = (0, logger_js_1.createClientLogger)("ts-http-runtime retryPolicy"); /** * The programmatic identifier of the retryPolicy. @@ -85425,6 +85261,7 @@ function retryPolicy(strategies, options = { maxRetries: constants_js_1.DEFAULT_ return { name: retryPolicyName, async sendRequest(request, next) { + var _a, _b; let response; let responseError; let retryCount = -1; @@ -85448,12 +85285,12 @@ function retryPolicy(strategies, options = { maxRetries: constants_js_1.DEFAULT_ } response = responseError.response; } - if (request.abortSignal?.aborted) { + if ((_a = request.abortSignal) === null || _a === void 0 ? void 0 : _a.aborted) { logger.error(`Retry ${retryCount}: Request aborted.`); const abortError = new AbortError_js_1.AbortError(); throw abortError; } - if (retryCount >= (options.maxRetries ?? constants_js_1.DEFAULT_RETRY_POLICY_COUNT)) { + if (retryCount >= ((_b = options.maxRetries) !== null && _b !== void 0 ? _b : constants_js_1.DEFAULT_RETRY_POLICY_COUNT)) { logger.info(`Retry ${retryCount}: Maximum retries reached. Returning the last received response, or throwing the last received error.`); if (responseError) { throw responseError; @@ -85513,7 +85350,7 @@ function retryPolicy(strategies, options = { maxRetries: constants_js_1.DEFAULT_ /***/ }), -/***/ 25767: +/***/ 79998: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -85522,9 +85359,9 @@ function retryPolicy(strategies, options = { maxRetries: constants_js_1.DEFAULT_ Object.defineProperty(exports, "__esModule", ({ value: true })); exports.systemErrorRetryPolicyName = void 0; exports.systemErrorRetryPolicy = systemErrorRetryPolicy; -const exponentialRetryStrategy_js_1 = __nccwpck_require__(86269); -const retryPolicy_js_1 = __nccwpck_require__(54878); -const constants_js_1 = __nccwpck_require__(4202); +const exponentialRetryStrategy_js_1 = __nccwpck_require__(22714); +const retryPolicy_js_1 = __nccwpck_require__(67021); +const constants_js_1 = __nccwpck_require__(88819); /** * Name of the {@link systemErrorRetryPolicy} */ @@ -85536,15 +85373,13 @@ exports.systemErrorRetryPolicyName = "systemErrorRetryPolicy"; * @param options - Options that customize the policy. */ function systemErrorRetryPolicy(options = {}) { + var _a; return { name: exports.systemErrorRetryPolicyName, sendRequest: (0, retryPolicy_js_1.retryPolicy)([ - (0, exponentialRetryStrategy_js_1.exponentialRetryStrategy)({ - ...options, - ignoreHttpStatusCodes: true, - }), + (0, exponentialRetryStrategy_js_1.exponentialRetryStrategy)(Object.assign(Object.assign({}, options), { ignoreHttpStatusCodes: true })), ], { - maxRetries: options.maxRetries ?? constants_js_1.DEFAULT_RETRY_POLICY_COUNT, + maxRetries: (_a = options.maxRetries) !== null && _a !== void 0 ? _a : constants_js_1.DEFAULT_RETRY_POLICY_COUNT, }).sendRequest, }; } @@ -85552,7 +85387,7 @@ function systemErrorRetryPolicy(options = {}) { /***/ }), -/***/ 90383: +/***/ 48492: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -85561,9 +85396,9 @@ function systemErrorRetryPolicy(options = {}) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.throttlingRetryPolicyName = void 0; exports.throttlingRetryPolicy = throttlingRetryPolicy; -const throttlingRetryStrategy_js_1 = __nccwpck_require__(60373); -const retryPolicy_js_1 = __nccwpck_require__(54878); -const constants_js_1 = __nccwpck_require__(4202); +const throttlingRetryStrategy_js_1 = __nccwpck_require__(7524); +const retryPolicy_js_1 = __nccwpck_require__(67021); +const constants_js_1 = __nccwpck_require__(88819); /** * Name of the {@link throttlingRetryPolicy} */ @@ -85579,10 +85414,11 @@ exports.throttlingRetryPolicyName = "throttlingRetryPolicy"; * @param options - Options that configure retry logic. */ function throttlingRetryPolicy(options = {}) { + var _a; return { name: exports.throttlingRetryPolicyName, sendRequest: (0, retryPolicy_js_1.retryPolicy)([(0, throttlingRetryStrategy_js_1.throttlingRetryStrategy)()], { - maxRetries: options.maxRetries ?? constants_js_1.DEFAULT_RETRY_POLICY_COUNT, + maxRetries: (_a = options.maxRetries) !== null && _a !== void 0 ? _a : constants_js_1.DEFAULT_RETRY_POLICY_COUNT, }).sendRequest, }; } @@ -85590,7 +85426,7 @@ function throttlingRetryPolicy(options = {}) { /***/ }), -/***/ 84949: +/***/ 55726: /***/ ((__unused_webpack_module, exports) => { @@ -85622,7 +85458,7 @@ function tlsPolicy(tlsSettings) { /***/ }), -/***/ 22448: +/***/ 92375: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -85631,7 +85467,7 @@ function tlsPolicy(tlsSettings) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.userAgentPolicyName = void 0; exports.userAgentPolicy = userAgentPolicy; -const userAgent_js_1 = __nccwpck_require__(77788); +const userAgent_js_1 = __nccwpck_require__(295); const UserAgentHeaderName = (0, userAgent_js_1.getUserAgentHeaderName)(); /** * The programmatic identifier of the userAgentPolicy. @@ -85658,7 +85494,7 @@ function userAgentPolicy(options = {}) { /***/ }), -/***/ 45227: +/***/ 79058: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -85667,47 +85503,14 @@ function userAgentPolicy(options = {}) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.RestError = void 0; exports.isRestError = isRestError; -const error_js_1 = __nccwpck_require__(59602); -const inspect_js_1 = __nccwpck_require__(8580); -const sanitizer_js_1 = __nccwpck_require__(83839); +const error_js_1 = __nccwpck_require__(29769); +const inspect_js_1 = __nccwpck_require__(39067); +const sanitizer_js_1 = __nccwpck_require__(56620); const errorSanitizer = new sanitizer_js_1.Sanitizer(); /** * A custom error type for failed pipeline requests. */ class RestError extends Error { - /** - * Something went wrong when making the request. - * This means the actual request failed for some reason, - * such as a DNS issue or the connection being lost. - */ - static REQUEST_SEND_ERROR = "REQUEST_SEND_ERROR"; - /** - * This means that parsing the response from the server failed. - * It may have been malformed. - */ - static PARSE_ERROR = "PARSE_ERROR"; - /** - * The code of the error itself (use statics on RestError if possible.) - */ - code; - /** - * The HTTP status code of the request (if applicable.) - */ - statusCode; - /** - * The request that was made. - * This property is non-enumerable. - */ - request; - /** - * The response received (if any.) - * This property is non-enumerable. - */ - response; - /** - * Bonus property set by the throw site. - */ - details; constructor(message, options = {}) { super(message); this.name = "RestError"; @@ -85719,24 +85522,12 @@ class RestError extends Error { // JSON.stringify and console.log. Object.defineProperty(this, "request", { value: options.request, enumerable: false }); Object.defineProperty(this, "response", { value: options.response, enumerable: false }); - // Only include useful agent information in the request for logging, as the full agent object - // may contain large binary data. - const agent = this.request?.agent - ? { - maxFreeSockets: this.request.agent.maxFreeSockets, - maxSockets: this.request.agent.maxSockets, - } - : undefined; // Logging method for util.inspect in Node Object.defineProperty(this, inspect_js_1.custom, { value: () => { // Extract non-enumerable properties and add them back. This is OK since in this output the request and // response get sanitized. - return `RestError: ${this.message} \n ${errorSanitizer.sanitize({ - ...this, - request: { ...this.request, agent }, - response: this.response, - })}`; + return `RestError: ${this.message} \n ${errorSanitizer.sanitize(Object.assign(Object.assign({}, this), { request: this.request, response: this.response }))}`; }, enumerable: false, }); @@ -85744,6 +85535,17 @@ class RestError extends Error { } } exports.RestError = RestError; +/** + * Something went wrong when making the request. + * This means the actual request failed for some reason, + * such as a DNS issue or the connection being lost. + */ +RestError.REQUEST_SEND_ERROR = "REQUEST_SEND_ERROR"; +/** + * This means that parsing the response from the server failed. + * It may have been malformed. + */ +RestError.PARSE_ERROR = "PARSE_ERROR"; /** * Typeguard for RestError * @param e - Something caught by a catch clause. @@ -85758,7 +85560,7 @@ function isRestError(e) { /***/ }), -/***/ 86269: +/***/ 22714: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -85768,8 +85570,8 @@ Object.defineProperty(exports, "__esModule", ({ value: true })); exports.exponentialRetryStrategy = exponentialRetryStrategy; exports.isExponentialRetryResponse = isExponentialRetryResponse; exports.isSystemError = isSystemError; -const delay_js_1 = __nccwpck_require__(91463); -const throttlingRetryStrategy_js_1 = __nccwpck_require__(60373); +const delay_js_1 = __nccwpck_require__(36812); +const throttlingRetryStrategy_js_1 = __nccwpck_require__(7524); // intervals are in milliseconds const DEFAULT_CLIENT_RETRY_INTERVAL = 1000; const DEFAULT_CLIENT_MAX_RETRY_INTERVAL = 1000 * 64; @@ -85779,8 +85581,9 @@ const DEFAULT_CLIENT_MAX_RETRY_INTERVAL = 1000 * 64; * - Or otherwise if the outgoing request fails (408, greater or equal than 500, except for 501 and 505). */ function exponentialRetryStrategy(options = {}) { - const retryInterval = options.retryDelayInMs ?? DEFAULT_CLIENT_RETRY_INTERVAL; - const maxRetryInterval = options.maxRetryDelayInMs ?? DEFAULT_CLIENT_MAX_RETRY_INTERVAL; + var _a, _b; + const retryInterval = (_a = options.retryDelayInMs) !== null && _a !== void 0 ? _a : DEFAULT_CLIENT_RETRY_INTERVAL; + const maxRetryInterval = (_b = options.maxRetryDelayInMs) !== null && _b !== void 0 ? _b : DEFAULT_CLIENT_MAX_RETRY_INTERVAL; return { name: "exponentialRetryStrategy", retry({ retryCount, response, responseError }) { @@ -85832,7 +85635,7 @@ function isSystemError(err) { /***/ }), -/***/ 60373: +/***/ 7524: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -85841,7 +85644,7 @@ function isSystemError(err) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.isThrottlingRetryResponse = isThrottlingRetryResponse; exports.throttlingRetryStrategy = throttlingRetryStrategy; -const helpers_js_1 = __nccwpck_require__(18365); +const helpers_js_1 = __nccwpck_require__(19490); /** * The header that comes back from services representing * the amount of time (minimum) to wait to retry (in seconds or timestamp after which we can retry). @@ -85887,7 +85690,7 @@ function getRetryAfterInMs(response) { // negative diff would mean a date in the past, so retry asap with 0 milliseconds return Number.isFinite(diff) ? Math.max(0, diff) : undefined; } - catch { + catch (_a) { return undefined; } } @@ -85916,7 +85719,7 @@ function throttlingRetryStrategy() { /***/ }), -/***/ 28482: +/***/ 28917: /***/ ((__unused_webpack_module, exports) => { @@ -85947,12 +85750,13 @@ function stringToUint8Array(value, format) { /***/ }), -/***/ 31407: +/***/ 98402: /***/ ((__unused_webpack_module, exports) => { // Copyright (c) Microsoft Corporation. // Licensed under the MIT License. +var _a, _b, _c, _d; Object.defineProperty(exports, "__esModule", ({ value: true })); exports.isReactNative = exports.isNodeRuntime = exports.isNodeLike = exports.isBun = exports.isDeno = exports.isWebWorker = exports.isBrowser = void 0; /** @@ -85964,10 +85768,10 @@ exports.isBrowser = typeof window !== "undefined" && typeof window.document !== * A constant that indicates whether the environment the code is running is a Web Worker. */ exports.isWebWorker = typeof self === "object" && - typeof self?.importScripts === "function" && - (self.constructor?.name === "DedicatedWorkerGlobalScope" || - self.constructor?.name === "ServiceWorkerGlobalScope" || - self.constructor?.name === "SharedWorkerGlobalScope"); + typeof (self === null || self === void 0 ? void 0 : self.importScripts) === "function" && + (((_a = self.constructor) === null || _a === void 0 ? void 0 : _a.name) === "DedicatedWorkerGlobalScope" || + ((_b = self.constructor) === null || _b === void 0 ? void 0 : _b.name) === "ServiceWorkerGlobalScope" || + ((_c = self.constructor) === null || _c === void 0 ? void 0 : _c.name) === "SharedWorkerGlobalScope"); /** * A constant that indicates whether the environment the code is running is Deno. */ @@ -85983,7 +85787,7 @@ exports.isBun = typeof Bun !== "undefined" && typeof Bun.version !== "undefined" */ exports.isNodeLike = typeof globalThis.process !== "undefined" && Boolean(globalThis.process.version) && - Boolean(globalThis.process.versions?.node); + Boolean((_d = globalThis.process.versions) === null || _d === void 0 ? void 0 : _d.node); /** * A constant that indicates whether the environment the code is running is Node.JS. */ @@ -85992,12 +85796,12 @@ exports.isNodeRuntime = exports.isNodeLike && !exports.isBun && !exports.isDeno; * A constant that indicates whether the environment the code is running is in React-Native. */ // https://github.com/facebook/react-native/blob/main/packages/react-native/Libraries/Core/setUpNavigator.js -exports.isReactNative = typeof navigator !== "undefined" && navigator?.product === "ReactNative"; +exports.isReactNative = typeof navigator !== "undefined" && (navigator === null || navigator === void 0 ? void 0 : navigator.product) === "ReactNative"; //# sourceMappingURL=checkEnvironment.js.map /***/ }), -/***/ 75142: +/***/ 93407: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -86005,22 +85809,25 @@ exports.isReactNative = typeof navigator !== "undefined" && navigator?.product = // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.concat = concat; +const tslib_1 = __nccwpck_require__(31577); const stream_1 = __nccwpck_require__(2203); -const typeGuards_js_1 = __nccwpck_require__(90932); -async function* streamAsyncIterator() { - const reader = this.getReader(); - try { - while (true) { - const { done, value } = await reader.read(); - if (done) { - return; +const typeGuards_js_1 = __nccwpck_require__(1093); +function streamAsyncIterator() { + return tslib_1.__asyncGenerator(this, arguments, function* streamAsyncIterator_1() { + const reader = this.getReader(); + try { + while (true) { + const { done, value } = yield tslib_1.__await(reader.read()); + if (done) { + return yield tslib_1.__await(void 0); + } + yield yield tslib_1.__await(value); } - yield value; } - } - finally { - reader.releaseLock(); - } + finally { + reader.releaseLock(); + } + }); } function makeAsyncIterable(webStream) { if (!webStream[Symbol.asyncIterator]) { @@ -86062,12 +85869,27 @@ function toStream(source) { async function concat(sources) { return function () { const streams = sources.map((x) => (typeof x === "function" ? x() : x)).map(toStream); - return stream_1.Readable.from((async function* () { - for (const stream of streams) { - for await (const chunk of stream) { - yield chunk; + return stream_1.Readable.from((function () { + return tslib_1.__asyncGenerator(this, arguments, function* () { + var _a, e_1, _b, _c; + for (const stream of streams) { + try { + for (var _d = true, stream_2 = (e_1 = void 0, tslib_1.__asyncValues(stream)), stream_2_1; stream_2_1 = yield tslib_1.__await(stream_2.next()), _a = stream_2_1.done, !_a; _d = true) { + _c = stream_2_1.value; + _d = false; + const chunk = _c; + yield yield tslib_1.__await(chunk); + } + } + catch (e_1_1) { e_1 = { error: e_1_1 }; } + finally { + try { + if (!_d && !_a && (_b = stream_2.return)) yield tslib_1.__await(_b.call(stream_2)); + } + finally { if (e_1) throw e_1.error; } + } } - } + }); })()); }; } @@ -86075,7 +85897,7 @@ async function concat(sources) { /***/ }), -/***/ 91463: +/***/ 36812: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -86083,7 +85905,7 @@ async function concat(sources) { // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.calculateRetryDelay = calculateRetryDelay; -const random_js_1 = __nccwpck_require__(28501); +const random_js_1 = __nccwpck_require__(81988); /** * Calculates the delay interval for retry attempts using exponential delay with jitter. * @param retryAttempt - The current retry attempt number. @@ -86104,7 +85926,7 @@ function calculateRetryDelay(retryAttempt, config) { /***/ }), -/***/ 59602: +/***/ 29769: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -86112,7 +85934,7 @@ function calculateRetryDelay(retryAttempt, config) { // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.isError = isError; -const object_js_1 = __nccwpck_require__(1301); +const object_js_1 = __nccwpck_require__(51900); /** * Typeguard for an error object shape (has name and message) * @param e - Something caught by a catch clause. @@ -86129,7 +85951,7 @@ function isError(e) { /***/ }), -/***/ 18365: +/***/ 19490: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -86138,7 +85960,7 @@ function isError(e) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.delay = delay; exports.parseHeaderValueAsNumber = parseHeaderValueAsNumber; -const AbortError_js_1 = __nccwpck_require__(61865); +const AbortError_js_1 = __nccwpck_require__(84260); const StandardAbortMessage = "The operation was aborted."; /** * A wrapper for setTimeout that resolves a promise after delayInMs milliseconds. @@ -86154,10 +85976,10 @@ function delay(delayInMs, value, options) { let timer = undefined; let onAborted = undefined; const rejectOnAbort = () => { - return reject(new AbortError_js_1.AbortError(options?.abortErrorMsg ? options?.abortErrorMsg : StandardAbortMessage)); + return reject(new AbortError_js_1.AbortError((options === null || options === void 0 ? void 0 : options.abortErrorMsg) ? options === null || options === void 0 ? void 0 : options.abortErrorMsg : StandardAbortMessage)); }; const removeListeners = () => { - if (options?.abortSignal && onAborted) { + if ((options === null || options === void 0 ? void 0 : options.abortSignal) && onAborted) { options.abortSignal.removeEventListener("abort", onAborted); } }; @@ -86168,14 +85990,14 @@ function delay(delayInMs, value, options) { removeListeners(); return rejectOnAbort(); }; - if (options?.abortSignal && options.abortSignal.aborted) { + if ((options === null || options === void 0 ? void 0 : options.abortSignal) && options.abortSignal.aborted) { return rejectOnAbort(); } timer = setTimeout(() => { removeListeners(); resolve(value); }, delayInMs); - if (options?.abortSignal) { + if (options === null || options === void 0 ? void 0 : options.abortSignal) { options.abortSignal.addEventListener("abort", onAborted); } }); @@ -86197,7 +86019,7 @@ function parseHeaderValueAsNumber(response, headerName) { /***/ }), -/***/ 8580: +/***/ 39067: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -86211,7 +86033,7 @@ exports.custom = node_util_1.inspect.custom; /***/ }), -/***/ 56759: +/***/ 37954: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -86219,20 +86041,20 @@ exports.custom = node_util_1.inspect.custom; // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.Sanitizer = exports.uint8ArrayToString = exports.stringToUint8Array = exports.isWebWorker = exports.isReactNative = exports.isDeno = exports.isNodeRuntime = exports.isNodeLike = exports.isBun = exports.isBrowser = exports.randomUUID = exports.computeSha256Hmac = exports.computeSha256Hash = exports.isError = exports.isObject = exports.getRandomIntegerInclusive = exports.calculateRetryDelay = void 0; -var delay_js_1 = __nccwpck_require__(91463); +var delay_js_1 = __nccwpck_require__(36812); Object.defineProperty(exports, "calculateRetryDelay", ({ enumerable: true, get: function () { return delay_js_1.calculateRetryDelay; } })); -var random_js_1 = __nccwpck_require__(28501); +var random_js_1 = __nccwpck_require__(81988); Object.defineProperty(exports, "getRandomIntegerInclusive", ({ enumerable: true, get: function () { return random_js_1.getRandomIntegerInclusive; } })); -var object_js_1 = __nccwpck_require__(1301); +var object_js_1 = __nccwpck_require__(51900); Object.defineProperty(exports, "isObject", ({ enumerable: true, get: function () { return object_js_1.isObject; } })); -var error_js_1 = __nccwpck_require__(59602); +var error_js_1 = __nccwpck_require__(29769); Object.defineProperty(exports, "isError", ({ enumerable: true, get: function () { return error_js_1.isError; } })); -var sha256_js_1 = __nccwpck_require__(22237); +var sha256_js_1 = __nccwpck_require__(53876); Object.defineProperty(exports, "computeSha256Hash", ({ enumerable: true, get: function () { return sha256_js_1.computeSha256Hash; } })); Object.defineProperty(exports, "computeSha256Hmac", ({ enumerable: true, get: function () { return sha256_js_1.computeSha256Hmac; } })); -var uuidUtils_js_1 = __nccwpck_require__(64052); +var uuidUtils_js_1 = __nccwpck_require__(90955); Object.defineProperty(exports, "randomUUID", ({ enumerable: true, get: function () { return uuidUtils_js_1.randomUUID; } })); -var checkEnvironment_js_1 = __nccwpck_require__(31407); +var checkEnvironment_js_1 = __nccwpck_require__(98402); Object.defineProperty(exports, "isBrowser", ({ enumerable: true, get: function () { return checkEnvironment_js_1.isBrowser; } })); Object.defineProperty(exports, "isBun", ({ enumerable: true, get: function () { return checkEnvironment_js_1.isBun; } })); Object.defineProperty(exports, "isNodeLike", ({ enumerable: true, get: function () { return checkEnvironment_js_1.isNodeLike; } })); @@ -86240,16 +86062,16 @@ Object.defineProperty(exports, "isNodeRuntime", ({ enumerable: true, get: functi Object.defineProperty(exports, "isDeno", ({ enumerable: true, get: function () { return checkEnvironment_js_1.isDeno; } })); Object.defineProperty(exports, "isReactNative", ({ enumerable: true, get: function () { return checkEnvironment_js_1.isReactNative; } })); Object.defineProperty(exports, "isWebWorker", ({ enumerable: true, get: function () { return checkEnvironment_js_1.isWebWorker; } })); -var bytesEncoding_js_1 = __nccwpck_require__(28482); +var bytesEncoding_js_1 = __nccwpck_require__(28917); Object.defineProperty(exports, "stringToUint8Array", ({ enumerable: true, get: function () { return bytesEncoding_js_1.stringToUint8Array; } })); Object.defineProperty(exports, "uint8ArrayToString", ({ enumerable: true, get: function () { return bytesEncoding_js_1.uint8ArrayToString; } })); -var sanitizer_js_1 = __nccwpck_require__(83839); +var sanitizer_js_1 = __nccwpck_require__(56620); Object.defineProperty(exports, "Sanitizer", ({ enumerable: true, get: function () { return sanitizer_js_1.Sanitizer; } })); //# sourceMappingURL=internal.js.map /***/ }), -/***/ 1301: +/***/ 51900: /***/ ((__unused_webpack_module, exports) => { @@ -86272,7 +86094,7 @@ function isObject(input) { /***/ }), -/***/ 28501: +/***/ 81988: /***/ ((__unused_webpack_module, exports) => { @@ -86302,7 +86124,7 @@ function getRandomIntegerInclusive(min, max) { /***/ }), -/***/ 83839: +/***/ 56620: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -86310,7 +86132,7 @@ function getRandomIntegerInclusive(min, max) { // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", ({ value: true })); exports.Sanitizer = void 0; -const object_js_1 = __nccwpck_require__(1301); +const object_js_1 = __nccwpck_require__(51900); const RedactedString = "REDACTED"; // Make sure this list is up-to-date with the one under core/logger/Readme#Keyconcepts const defaultAllowedHeaderNames = [ @@ -86359,8 +86181,6 @@ const defaultAllowedQueryParameters = ["api-version"]; * A utility class to sanitize objects for logging. */ class Sanitizer { - allowedHeaderNames; - allowedQueryParameters; constructor({ additionalAllowedHeaderNames: allowedHeaderNames = [], additionalAllowedQueryParameters: allowedQueryParameters = [], } = {}) { allowedHeaderNames = defaultAllowedHeaderNames.concat(allowedHeaderNames); allowedQueryParameters = defaultAllowedQueryParameters.concat(allowedQueryParameters); @@ -86377,11 +86197,7 @@ class Sanitizer { return JSON.stringify(obj, (key, value) => { // Ensure Errors include their interesting non-enumerable members if (value instanceof Error) { - return { - ...value, - name: value.name, - message: value.message, - }; + return Object.assign(Object.assign({}, value), { name: value.name, message: value.message }); } if (key === "headers") { return this.sanitizeHeaders(value); @@ -86467,7 +86283,7 @@ exports.Sanitizer = Sanitizer; /***/ }), -/***/ 22237: +/***/ 53876: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -86499,7 +86315,7 @@ async function computeSha256Hash(content, encoding) { /***/ }), -/***/ 90932: +/***/ 1093: /***/ ((__unused_webpack_module, exports) => { @@ -86536,7 +86352,7 @@ function isBlob(x) { /***/ }), -/***/ 77788: +/***/ 295: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -86545,8 +86361,8 @@ function isBlob(x) { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.getUserAgentHeaderName = getUserAgentHeaderName; exports.getUserAgentValue = getUserAgentValue; -const userAgentPlatform_js_1 = __nccwpck_require__(24375); -const constants_js_1 = __nccwpck_require__(4202); +const userAgentPlatform_js_1 = __nccwpck_require__(89776); +const constants_js_1 = __nccwpck_require__(88819); function getUserAgentString(telemetryInfo) { const parts = []; for (const [key, value] of telemetryInfo) { @@ -86576,7 +86392,7 @@ async function getUserAgentValue(prefix) { /***/ }), -/***/ 24375: +/***/ 89776: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -86586,8 +86402,8 @@ Object.defineProperty(exports, "__esModule", ({ value: true })); exports.getHeaderName = getHeaderName; exports.setPlatformSpecificData = setPlatformSpecificData; const tslib_1 = __nccwpck_require__(31577); -const node_os_1 = tslib_1.__importDefault(__nccwpck_require__(48161)); -const node_process_1 = tslib_1.__importDefault(__nccwpck_require__(1708)); +const os = tslib_1.__importStar(__nccwpck_require__(48161)); +const process = tslib_1.__importStar(__nccwpck_require__(1708)); /** * @internal */ @@ -86598,8 +86414,8 @@ function getHeaderName() { * @internal */ async function setPlatformSpecificData(map) { - if (node_process_1.default && node_process_1.default.versions) { - const versions = node_process_1.default.versions; + if (process && process.versions) { + const versions = process.versions; if (versions.bun) { map.set("Bun", versions.bun); } @@ -86610,23 +86426,24 @@ async function setPlatformSpecificData(map) { map.set("Node", versions.node); } } - map.set("OS", `(${node_os_1.default.arch()}-${node_os_1.default.type()}-${node_os_1.default.release()})`); + map.set("OS", `(${os.arch()}-${os.type()}-${os.release()})`); } //# sourceMappingURL=userAgentPlatform.js.map /***/ }), -/***/ 64052: +/***/ 90955: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { // Copyright (c) Microsoft Corporation. // Licensed under the MIT License. +var _a; Object.defineProperty(exports, "__esModule", ({ value: true })); exports.randomUUID = randomUUID; const node_crypto_1 = __nccwpck_require__(77598); // NOTE: This is a workaround until we can use `globalThis.crypto.randomUUID` in Node.js 19+. -const uuidFunction = typeof globalThis?.crypto?.randomUUID === "function" +const uuidFunction = typeof ((_a = globalThis === null || globalThis === void 0 ? void 0 : globalThis.crypto) === null || _a === void 0 ? void 0 : _a.randomUUID) === "function" ? globalThis.crypto.randomUUID.bind(globalThis.crypto) : node_crypto_1.randomUUID; /** @@ -86699,34 +86516,18 @@ var __webpack_exports__ = {}; var core = __nccwpck_require__(59999); // EXTERNAL MODULE: ./node_modules/.pnpm/@actions+exec@1.1.1/node_modules/@actions/exec/lib/exec.js var exec = __nccwpck_require__(58872); -;// CONCATENATED MODULE: ./node_modules/.pnpm/detsys-ts@https+++codeload.github.com+DeterminateSystems+detsys-ts+tar.gz+285768c0d657f_c9f3de82f778b67727761493310aa570/node_modules/detsys-ts/dist/chunk-CTAAG5j7.js -//#region rolldown:runtime -var __defProp = Object.defineProperty; -var __export = (all) => { - let target = {}; - for (var name in all) __defProp(target, name, { - get: all[name], - enumerable: true - }); - return target; -}; - -//#endregion - -// EXTERNAL MODULE: external "node:fs" -var external_node_fs_ = __nccwpck_require__(73024); -// EXTERNAL MODULE: external "node:os" -var external_node_os_ = __nccwpck_require__(48161); -// EXTERNAL MODULE: external "node:util" -var external_node_util_ = __nccwpck_require__(57975); +// EXTERNAL MODULE: external "fs" +var external_fs_ = __nccwpck_require__(79896); // EXTERNAL MODULE: external "os" var external_os_ = __nccwpck_require__(70857); -;// CONCATENATED MODULE: external "node:fs/promises" -const promises_namespaceObject = __WEBPACK_EXTERNAL_createRequire(import.meta.url)("node:fs/promises"); -// EXTERNAL MODULE: external "node:zlib" -var external_node_zlib_ = __nccwpck_require__(38522); -// EXTERNAL MODULE: external "node:crypto" -var external_node_crypto_ = __nccwpck_require__(77598); +// EXTERNAL MODULE: external "util" +var external_util_ = __nccwpck_require__(39023); +;// CONCATENATED MODULE: external "fs/promises" +const promises_namespaceObject = __WEBPACK_EXTERNAL_createRequire(import.meta.url)("fs/promises"); +// EXTERNAL MODULE: external "zlib" +var external_zlib_ = __nccwpck_require__(43106); +// EXTERNAL MODULE: external "crypto" +var external_crypto_ = __nccwpck_require__(76982); ;// CONCATENATED MODULE: external "node:timers/promises" const external_node_timers_promises_namespaceObject = __WEBPACK_EXTERNAL_createRequire(import.meta.url)("node:timers/promises"); ;// CONCATENATED MODULE: ./node_modules/.pnpm/@sindresorhus+is@7.0.2/node_modules/@sindresorhus/is/distribution/index.js @@ -88156,7 +87957,7 @@ class PCancelable { Object.setPrototypeOf(PCancelable.prototype, Promise.prototype); -;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.8/node_modules/got/dist/source/core/errors.js +;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.7/node_modules/got/dist/source/core/errors.js // A hacky check to prevent circular references. function isRequest(x) { @@ -88307,8 +88108,6 @@ var external_node_stream_ = __nccwpck_require__(57075); var external_node_http_ = __nccwpck_require__(37067); // EXTERNAL MODULE: external "events" var external_events_ = __nccwpck_require__(24434); -// EXTERNAL MODULE: external "util" -var external_util_ = __nccwpck_require__(39023); // EXTERNAL MODULE: ./node_modules/.pnpm/defer-to-connect@2.0.1/node_modules/defer-to-connect/dist/source/index.js var source = __nccwpck_require__(57596); ;// CONCATENATED MODULE: ./node_modules/.pnpm/@szmarczak+http-timer@5.0.1/node_modules/@szmarczak/http-timer/dist/source/index.js @@ -88421,7 +88220,9 @@ const timer = (request) => { ;// CONCATENATED MODULE: external "node:url" const external_node_url_namespaceObject = __WEBPACK_EXTERNAL_createRequire(import.meta.url)("node:url"); -;// CONCATENATED MODULE: ./node_modules/.pnpm/normalize-url@8.1.0/node_modules/normalize-url/index.js +// EXTERNAL MODULE: external "node:crypto" +var external_node_crypto_ = __nccwpck_require__(77598); +;// CONCATENATED MODULE: ./node_modules/.pnpm/normalize-url@8.0.2/node_modules/normalize-url/index.js // https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs const DATA_URL_DEFAULT_MIME_TYPE = 'text/plain'; const DATA_URL_DEFAULT_CHARSET = 'us-ascii'; @@ -88513,8 +88314,6 @@ function normalizeUrl(urlString, options) { removeDirectoryIndex: false, removeExplicitPort: false, sortQueryParameters: true, - removePath: false, - transformPath: false, ...options, }; @@ -88626,18 +88425,6 @@ function normalizeUrl(urlString, options) { } } - // Remove path - if (options.removePath) { - urlObject.pathname = '/'; - } - - // Transform path components - if (options.transformPath && typeof options.transformPath === 'function') { - const pathComponents = urlObject.pathname.split('/').filter(Boolean); - const newComponents = options.transformPath(pathComponents); - urlObject.pathname = newComponents?.length > 0 ? `/${newComponents.join('/')}` : '/'; - } - if (urlObject.hostname) { // Remove trailing dot urlObject.hostname = urlObject.hostname.replace(/\.$/, ''); @@ -88678,21 +88465,12 @@ function normalizeUrl(urlString, options) { // Sort query parameters if (options.sortQueryParameters) { - const originalSearch = urlObject.search; urlObject.searchParams.sort(); // Calling `.sort()` encodes the search parameters, so we need to decode them again. try { urlObject.search = decodeURIComponent(urlObject.search); } catch {} - - // Fix parameters that originally had no equals sign but got one added by URLSearchParams - const partsWithoutEquals = originalSearch.slice(1).split('&').filter(p => p && !p.includes('=')); - for (const part of partsWithoutEquals) { - const decoded = decodeURIComponent(part); - // Only replace at word boundaries to avoid partial matches - urlObject.search = urlObject.search.replace(`?${decoded}=`, `?${decoded}`).replace(`&${decoded}=`, `&${decoded}`); - } } if (options.removeTrailingSlash) { @@ -89948,13 +89726,15 @@ getContentLength_fn = function() { }; -;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.8/node_modules/got/dist/source/core/utils/is-form-data.js +// EXTERNAL MODULE: external "node:util" +var external_node_util_ = __nccwpck_require__(57975); +;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.7/node_modules/got/dist/source/core/utils/is-form-data.js function is_form_data_isFormData(body) { return distribution.nodeStream(body) && distribution.function(body.getBoundary); } -;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.8/node_modules/got/dist/source/core/utils/get-body-size.js +;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.7/node_modules/got/dist/source/core/utils/get-body-size.js @@ -89978,7 +89758,7 @@ async function getBodySize(body, headers) { return undefined; } -;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.8/node_modules/got/dist/source/core/utils/proxy-events.js +;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.7/node_modules/got/dist/source/core/utils/proxy-events.js function proxyEvents(from, to, events) { const eventFunctions = {}; for (const event of events) { @@ -89997,7 +89777,7 @@ function proxyEvents(from, to, events) { ;// CONCATENATED MODULE: external "node:net" const external_node_net_namespaceObject = __WEBPACK_EXTERNAL_createRequire(import.meta.url)("node:net"); -;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.8/node_modules/got/dist/source/core/utils/unhandle.js +;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.7/node_modules/got/dist/source/core/utils/unhandle.js // When attaching listeners, it's very easy to forget about them. // Especially if you do error handling and set timeouts. // So instead of checking if it's proper to throw an error on every timeout ever, @@ -90019,7 +89799,7 @@ function unhandle() { }; } -;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.8/node_modules/got/dist/source/core/timed-out.js +;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.7/node_modules/got/dist/source/core/timed-out.js const reentry = Symbol('reentry'); @@ -90158,7 +89938,7 @@ function timedOut(request, delays, options) { return cancelTimeouts; } -;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.8/node_modules/got/dist/source/core/utils/url-to-options.js +;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.7/node_modules/got/dist/source/core/utils/url-to-options.js function urlToOptions(url) { // Cast to URL @@ -90182,7 +89962,7 @@ function urlToOptions(url) { return options; } -;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.8/node_modules/got/dist/source/core/utils/weakable-map.js +;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.7/node_modules/got/dist/source/core/utils/weakable-map.js class WeakableMap { weakMap; map; @@ -90212,7 +89992,7 @@ class WeakableMap { } } -;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.8/node_modules/got/dist/source/core/calculate-retry-delay.js +;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.7/node_modules/got/dist/source/core/calculate-retry-delay.js const calculateRetryDelay = ({ attemptCount, retryOptions, error, retryAfter, computedValue, }) => { if (error.name === 'RetryError') { return 1; @@ -90249,6 +90029,8 @@ const external_node_tls_namespaceObject = __WEBPACK_EXTERNAL_createRequire(impor var external_node_https_ = __nccwpck_require__(44708); ;// CONCATENATED MODULE: external "node:dns" const external_node_dns_namespaceObject = __WEBPACK_EXTERNAL_createRequire(import.meta.url)("node:dns"); +// EXTERNAL MODULE: external "node:os" +var external_node_os_ = __nccwpck_require__(48161); ;// CONCATENATED MODULE: ./node_modules/.pnpm/cacheable-lookup@7.0.0/node_modules/cacheable-lookup/source/index.js @@ -90699,7 +90481,7 @@ class CacheableLookup { // EXTERNAL MODULE: ./node_modules/.pnpm/http2-wrapper@2.2.1/node_modules/http2-wrapper/source/index.js var http2_wrapper_source = __nccwpck_require__(55409); -;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.8/node_modules/got/dist/source/core/parse-link-header.js +;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.7/node_modules/got/dist/source/core/parse-link-header.js function parseLinkHeader(link) { const parsed = []; const items = link.split(','); @@ -90734,7 +90516,7 @@ function parseLinkHeader(link) { return parsed; } -;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.8/node_modules/got/dist/source/core/options.js +;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.7/node_modules/got/dist/source/core/options.js @@ -91096,10 +90878,7 @@ class Options { return; } if (options instanceof Options) { - // Create a copy of the _init array to avoid infinite loop - // when merging an Options instance with itself - const initArray = [...options._init]; - for (const init of initArray) { + for (const init of options._init) { this.merge(init); } return; @@ -92374,7 +92153,7 @@ class Options { } } -;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.8/node_modules/got/dist/source/core/response.js +;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.7/node_modules/got/dist/source/core/response.js const isResponseOk = (response) => { const { statusCode } = response; @@ -92417,19 +92196,19 @@ const parseBody = (response, responseType, parseJson, encoding) => { }, response); }; -;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.8/node_modules/got/dist/source/core/utils/is-client-request.js +;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.7/node_modules/got/dist/source/core/utils/is-client-request.js function isClientRequest(clientRequest) { return clientRequest.writable && !clientRequest.writableEnded; } /* harmony default export */ const is_client_request = (isClientRequest); -;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.8/node_modules/got/dist/source/core/utils/is-unix-socket-url.js +;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.7/node_modules/got/dist/source/core/utils/is-unix-socket-url.js // eslint-disable-next-line @typescript-eslint/naming-convention function isUnixSocketURL(url) { return url.protocol === 'unix:' || url.hostname === 'unix'; } -;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.8/node_modules/got/dist/source/core/index.js +;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.7/node_modules/got/dist/source/core/index.js @@ -93436,7 +93215,7 @@ class Request extends external_node_stream_.Duplex { } } -;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.8/node_modules/got/dist/source/as-promise/types.js +;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.7/node_modules/got/dist/source/as-promise/types.js /** An error to be thrown when the request is aborted with `.cancel()`. @@ -93455,7 +93234,7 @@ class types_CancelError extends RequestError { } } -;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.8/node_modules/got/dist/source/as-promise/index.js +;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.7/node_modules/got/dist/source/as-promise/index.js @@ -93621,7 +93400,7 @@ function asPromise(firstRequest) { return promise; } -;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.8/node_modules/got/dist/source/create.js +;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.7/node_modules/got/dist/source/create.js @@ -93803,7 +93582,7 @@ const create = (defaults) => { }; /* harmony default export */ const source_create = (create); -;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.8/node_modules/got/dist/source/index.js +;// CONCATENATED MODULE: ./node_modules/.pnpm/got@14.4.7/node_modules/got/dist/source/index.js const defaults = { @@ -93826,1366 +93605,1698 @@ const got = source_create(defaults); -;// CONCATENATED MODULE: external "node:dns/promises" -const external_node_dns_promises_namespaceObject = __WEBPACK_EXTERNAL_createRequire(import.meta.url)("node:dns/promises"); +;// CONCATENATED MODULE: external "dns/promises" +const external_dns_promises_namespaceObject = __WEBPACK_EXTERNAL_createRequire(import.meta.url)("dns/promises"); // EXTERNAL MODULE: ./node_modules/.pnpm/@actions+cache@4.0.5/node_modules/@actions/cache/lib/cache.js var cache = __nccwpck_require__(95291); -;// CONCATENATED MODULE: external "node:child_process" -const external_node_child_process_namespaceObject = __WEBPACK_EXTERNAL_createRequire(import.meta.url)("node:child_process"); -;// CONCATENATED MODULE: external "node:path" -const external_node_path_namespaceObject = __WEBPACK_EXTERNAL_createRequire(import.meta.url)("node:path"); -;// CONCATENATED MODULE: ./node_modules/.pnpm/detsys-ts@https+++codeload.github.com+DeterminateSystems+detsys-ts+tar.gz+285768c0d657f_c9f3de82f778b67727761493310aa570/node_modules/detsys-ts/dist/index.js - - - - - - - - - - - - - - - - - - -//#region src/linux-release-info.ts -const readFileAsync = (0,external_node_util_.promisify)(external_node_fs_.readFile); -const linuxReleaseInfoOptionsDefaults = { - mode: "async", - customFile: null, - debug: false +// EXTERNAL MODULE: external "child_process" +var external_child_process_ = __nccwpck_require__(35317); +// EXTERNAL MODULE: external "path" +var external_path_ = __nccwpck_require__(16928); +;// CONCATENATED MODULE: ./node_modules/.pnpm/detsys-ts@https+++codeload.github.com+DeterminateSystems+detsys-ts+tar.gz+e439a01995ac0_42b2bed1ec0f71a693d9d66a3bfcc911/node_modules/detsys-ts/dist/index.js +var __defProp = Object.defineProperty; +var __export = (target, all) => { + for (var name in all) + __defProp(target, name, { get: all[name], enumerable: true }); +}; + +// src/linux-release-info.ts + + + +var readFileAsync = (0,external_util_.promisify)(external_fs_.readFile); +var linuxReleaseInfoOptionsDefaults = { + mode: "async", + customFile: null, + debug: false }; -/** -* Get OS release info from 'os-release' file and from native os module -* on Windows or Darwin it only returns common os module info -* (uses native fs module) -* @returns {object} info from the current os -*/ function releaseInfo(infoOptions) { - const options = { - ...linuxReleaseInfoOptionsDefaults, - ...infoOptions - }; - const searchOsReleaseFileList = osReleaseFileList(options.customFile); - if (external_node_os_.type() !== "Linux") if (options.mode === "sync") return getOsInfo(); - else return Promise.resolve(getOsInfo()); - if (options.mode === "sync") return readSyncOsreleaseFile(searchOsReleaseFileList, options); - else return Promise.resolve(readAsyncOsReleaseFile(searchOsReleaseFileList, options)); + const options = { ...linuxReleaseInfoOptionsDefaults, ...infoOptions }; + const searchOsReleaseFileList = osReleaseFileList( + options.customFile + ); + if (external_os_.type() !== "Linux") { + if (options.mode === "sync") { + return getOsInfo(); + } else { + return Promise.resolve(getOsInfo()); + } + } + if (options.mode === "sync") { + return readSyncOsreleaseFile(searchOsReleaseFileList, options); + } else { + return Promise.resolve( + readAsyncOsReleaseFile(searchOsReleaseFileList, options) + ); + } } -/** -* Format file data: convert data to object keys/values -* -* @param {object} sourceData Source object to be appended -* @param {string} srcParseData Input file data to be parsed -* @returns {object} Formated object -*/ function formatFileData(sourceData, srcParseData) { - const lines = srcParseData.split("\n"); - for (const line of lines) { - const lineData = line.split("="); - if (lineData.length === 2) { - lineData[1] = lineData[1].replace(/["'\r]/gi, ""); - Object.defineProperty(sourceData, lineData[0].toLowerCase(), { - value: lineData[1], - writable: true, - enumerable: true, - configurable: true - }); - } - } - return sourceData; + const lines = srcParseData.split("\n"); + for (const line of lines) { + const lineData = line.split("="); + if (lineData.length === 2) { + lineData[1] = lineData[1].replace(/["'\r]/gi, ""); + Object.defineProperty(sourceData, lineData[0].toLowerCase(), { + value: lineData[1], + writable: true, + enumerable: true, + configurable: true + }); + } + } + return sourceData; } -/** -* Export a list of os-release files -* -* @param {string} customFile optional custom complete filepath -* @returns {array} list of os-release files -*/ function osReleaseFileList(customFile) { - const DEFAULT_OS_RELEASE_FILES = ["/etc/os-release", "/usr/lib/os-release"]; - if (!customFile) return DEFAULT_OS_RELEASE_FILES; - else return Array(customFile); + const DEFAULT_OS_RELEASE_FILES = ["/etc/os-release", "/usr/lib/os-release"]; + if (!customFile) { + return DEFAULT_OS_RELEASE_FILES; + } else { + return Array(customFile); + } } -/** -* Get OS Basic Info -* (uses node 'os' native module) -* -* @returns {OsInfo} os basic info -*/ function getOsInfo() { - return { - type: external_node_os_.type(), - platform: external_node_os_.platform(), - hostname: external_node_os_.hostname(), - arch: external_node_os_.arch(), - release: external_node_os_.release() - }; + return { + type: external_os_.type(), + platform: external_os_.platform(), + hostname: external_os_.hostname(), + arch: external_os_.arch(), + release: external_os_.release() + }; } async function readAsyncOsReleaseFile(fileList, options) { - let fileData = null; - for (const osReleaseFile of fileList) try { - if (options.debug) console.log(`Trying to read '${osReleaseFile}'...`); - fileData = await readFileAsync(osReleaseFile, "binary"); - if (options.debug) console.log(`Read data:\n${fileData}`); - break; - } catch (error) { - if (options.debug) console.error(error); - } - if (fileData === null) throw new Error("Cannot read os-release file!"); - return formatFileData(getOsInfo(), fileData); + let fileData = null; + for (const osReleaseFile of fileList) { + try { + if (options.debug) { + console.log(`Trying to read '${osReleaseFile}'...`); + } + fileData = await readFileAsync(osReleaseFile, "binary"); + if (options.debug) { + console.log(`Read data: +${fileData}`); + } + break; + } catch (error3) { + if (options.debug) { + console.error(error3); + } + } + } + if (fileData === null) { + throw new Error("Cannot read os-release file!"); + } + return formatFileData(getOsInfo(), fileData); } function readSyncOsreleaseFile(releaseFileList, options) { - let fileData = null; - for (const osReleaseFile of releaseFileList) try { - if (options.debug) console.log(`Trying to read '${osReleaseFile}'...`); - fileData = external_node_fs_.readFileSync(osReleaseFile, "binary"); - if (options.debug) console.log(`Read data:\n${fileData}`); - break; - } catch (error) { - if (options.debug) console.error(error); - } - if (fileData === null) throw new Error("Cannot read os-release file!"); - return formatFileData(getOsInfo(), fileData); + let fileData = null; + for (const osReleaseFile of releaseFileList) { + try { + if (options.debug) { + console.log(`Trying to read '${osReleaseFile}'...`); + } + fileData = external_fs_.readFileSync(osReleaseFile, "binary"); + if (options.debug) { + console.log(`Read data: +${fileData}`); + } + break; + } catch (error3) { + if (options.debug) { + console.error(error3); + } + } + } + if (fileData === null) { + throw new Error("Cannot read os-release file!"); + } + return formatFileData(getOsInfo(), fileData); } -//#endregion -//#region src/actions-core-platform.ts -/** -* Get the name and version of the current Windows system. -*/ -const getWindowsInfo = async () => { - const { stdout: version } = await exec.getExecOutput("powershell -command \"(Get-CimInstance -ClassName Win32_OperatingSystem).Version\"", void 0, { silent: true }); - const { stdout: name } = await exec.getExecOutput("powershell -command \"(Get-CimInstance -ClassName Win32_OperatingSystem).Caption\"", void 0, { silent: true }); - return { - name: name.trim(), - version: version.trim() - }; +// src/actions-core-platform.ts + + + +var getWindowsInfo = async () => { + const { stdout: version } = await exec.getExecOutput( + 'powershell -command "(Get-CimInstance -ClassName Win32_OperatingSystem).Version"', + void 0, + { + silent: true + } + ); + const { stdout: name } = await exec.getExecOutput( + 'powershell -command "(Get-CimInstance -ClassName Win32_OperatingSystem).Caption"', + void 0, + { + silent: true + } + ); + return { + name: name.trim(), + version: version.trim() + }; }; -/** -* Get the name and version of the current macOS system. -*/ -const getMacOsInfo = async () => { - const { stdout } = await exec.getExecOutput("sw_vers", void 0, { silent: true }); - const version = stdout.match(/ProductVersion:\s*(.+)/)?.[1] ?? ""; - return { - name: stdout.match(/ProductName:\s*(.+)/)?.[1] ?? "", - version - }; +var getMacOsInfo = async () => { + const { stdout } = await exec.getExecOutput("sw_vers", void 0, { + silent: true + }); + const version = stdout.match(/ProductVersion:\s*(.+)/)?.[1] ?? ""; + const name = stdout.match(/ProductName:\s*(.+)/)?.[1] ?? ""; + return { + name, + version + }; }; -/** -* Get the name and version of the current Linux system. -*/ -const getLinuxInfo = async () => { - let data = {}; - try { - data = releaseInfo({ mode: "sync" }); - core.debug(`Identified release info: ${JSON.stringify(data)}`); - } catch (e) { - core.debug(`Error collecting release info: ${e}`); - } - return { - name: getPropertyViaWithDefault(data, [ - "id", - "name", - "pretty_name", - "id_like" - ], "unknown"), - version: getPropertyViaWithDefault(data, [ - "version_id", - "version", - "version_codename" - ], "unknown") - }; +var getLinuxInfo = async () => { + let data = {}; + try { + data = releaseInfo({ mode: "sync" }); + core.debug(`Identified release info: ${JSON.stringify(data)}`); + } catch (e) { + core.debug(`Error collecting release info: ${e}`); + } + return { + name: getPropertyViaWithDefault( + data, + ["id", "name", "pretty_name", "id_like"], + "unknown" + ), + version: getPropertyViaWithDefault( + data, + ["version_id", "version", "version_codename"], + "unknown" + ) + }; }; function getPropertyViaWithDefault(data, names, defaultValue) { - for (const name of names) { - const ret = getPropertyWithDefault(data, name, defaultValue); - if (ret !== defaultValue) return ret; - } - return defaultValue; + for (const name of names) { + const ret = getPropertyWithDefault(data, name, defaultValue); + if (ret !== defaultValue) { + return ret; + } + } + return defaultValue; } function getPropertyWithDefault(data, name, defaultValue) { - if (!data.hasOwnProperty(name)) return defaultValue; - const value = data[name]; - if (typeof value !== typeof defaultValue) return defaultValue; - return value; + if (!data.hasOwnProperty(name)) { + return defaultValue; + } + const value = data[name]; + if (typeof value !== typeof defaultValue) { + return defaultValue; + } + return value; } -/** -* The Action runner's platform. -*/ -const platform = external_os_.platform(); -/** -* The Action runner's architecture. -*/ -const arch = external_os_.arch(); -/** -* Whether the Action runner is a Windows system. -*/ -const isWindows = platform === "win32"; -/** -* Whether the Action runner is a macOS system. -*/ -const isMacOS = platform === "darwin"; -/** -* Whether the Action runner is a Linux system. -*/ -const isLinux = platform === "linux"; -/** -* Get system-level information about the current host (platform, architecture, etc.). -*/ +var platform2 = external_os_.platform(); +var arch2 = external_os_.arch(); +var isWindows = platform2 === "win32"; +var isMacOS = platform2 === "darwin"; +var isLinux = platform2 === "linux"; async function getDetails() { - return { - ...await (isWindows ? getWindowsInfo() : isMacOS ? getMacOsInfo() : getLinuxInfo()), - platform, - arch, - isWindows, - isMacOS, - isLinux - }; + return { + ...await (isWindows ? getWindowsInfo() : isMacOS ? getMacOsInfo() : getLinuxInfo()), + platform: platform2, + arch: arch2, + isWindows, + isMacOS, + isLinux + }; } -//#endregion -//#region src/errors.ts -/** -* Coerce a value of type `unknown` into a string. -*/ +// src/errors.ts function stringifyError(e) { - if (e instanceof Error) return e.message; - else if (typeof e === "string") return e; - else return JSON.stringify(e); + if (e instanceof Error) { + return e.message; + } else if (typeof e === "string") { + return e; + } else { + return JSON.stringify(e); + } } -//#endregion -//#region src/backtrace.ts -const START_SLOP_SECONDS = 5; +// src/backtrace.ts + + + + + +var START_SLOP_SECONDS = 5; async function collectBacktraces(prefixes, programNameDenyList, startTimestampMs) { - if (isMacOS) return await collectBacktracesMacOS(prefixes, programNameDenyList, startTimestampMs); - if (isLinux) return await collectBacktracesSystemd(prefixes, programNameDenyList, startTimestampMs); - return /* @__PURE__ */ new Map(); + if (isMacOS) { + return await collectBacktracesMacOS( + prefixes, + programNameDenyList, + startTimestampMs + ); + } + if (isLinux) { + return await collectBacktracesSystemd( + prefixes, + programNameDenyList, + startTimestampMs + ); + } + return /* @__PURE__ */ new Map(); } async function collectBacktracesMacOS(prefixes, programNameDenyList, startTimestampMs) { - const backtraces = /* @__PURE__ */ new Map(); - try { - const { stdout: logJson } = await exec.getExecOutput("log", [ - "show", - "--style", - "json", - "--last", - "1m", - "--no-info", - "--predicate", - "sender = 'ReportCrash'" - ], { silent: true }); - const sussyArray = JSON.parse(logJson); - if (!Array.isArray(sussyArray)) throw new Error(`Log json isn't an array: ${logJson}`); - if (sussyArray.length > 0) { - core.info(`Collecting crash data...`); - const delay = async (ms) => new Promise((resolve) => setTimeout(resolve, ms)); - await delay(5e3); - } - } catch { - core.debug("Failed to check logs for in-progress crash dumps; now proceeding with the assumption that all crash dumps completed."); - } - const dirs = [["system", "/Library/Logs/DiagnosticReports/"], ["user", `${process.env["HOME"]}/Library/Logs/DiagnosticReports/`]]; - for (const [source, dir] of dirs) { - const fileNames = (await (0,promises_namespaceObject.readdir)(dir)).filter((fileName) => { - return prefixes.some((prefix) => fileName.startsWith(prefix)); - }).filter((fileName) => { - return !programNameDenyList.some((programName) => fileName.startsWith(programName)); - }).filter((fileName) => { - return !fileName.endsWith(".diag"); - }); - const doGzip = (0,external_node_util_.promisify)(external_node_zlib_.gzip); - for (const fileName of fileNames) try { - if ((await (0,promises_namespaceObject.stat)(`${dir}/${fileName}`)).ctimeMs >= startTimestampMs) { - const logText = await (0,promises_namespaceObject.readFile)(`${dir}/${fileName}`); - const buf = await doGzip(logText); - backtraces.set(`backtrace_value_${source}_${fileName}`, buf.toString("base64")); - } - } catch (innerError) { - backtraces.set(`backtrace_failure_${source}_${fileName}`, stringifyError(innerError)); - } - } - return backtraces; + const backtraces = /* @__PURE__ */ new Map(); + try { + const { stdout: logJson } = await exec.getExecOutput( + "log", + [ + "show", + "--style", + "json", + "--last", + // Note we collect the last 1m only, because it should only take a few seconds to write the crash log. + // Therefore, any crashes before this 1m should be long done by now. + "1m", + "--no-info", + "--predicate", + "sender = 'ReportCrash'" + ], + { + silent: true + } + ); + const sussyArray = JSON.parse(logJson); + if (!Array.isArray(sussyArray)) { + throw new Error(`Log json isn't an array: ${logJson}`); + } + if (sussyArray.length > 0) { + core.info(`Collecting crash data...`); + const delay = async (ms) => new Promise((resolve) => setTimeout(resolve, ms)); + await delay(5e3); + } + } catch { + core.debug( + "Failed to check logs for in-progress crash dumps; now proceeding with the assumption that all crash dumps completed." + ); + } + const dirs = [ + ["system", "/Library/Logs/DiagnosticReports/"], + ["user", `${process.env["HOME"]}/Library/Logs/DiagnosticReports/`] + ]; + for (const [source, dir] of dirs) { + const fileNames = (await (0,promises_namespaceObject.readdir)(dir)).filter((fileName) => { + return prefixes.some((prefix) => fileName.startsWith(prefix)); + }).filter((fileName) => { + return !programNameDenyList.some( + (programName) => fileName.startsWith(programName) + ); + }).filter((fileName) => { + return !fileName.endsWith(".diag"); + }); + const doGzip = (0,external_util_.promisify)(external_zlib_.gzip); + for (const fileName of fileNames) { + try { + if ((await (0,promises_namespaceObject.stat)(`${dir}/${fileName}`)).ctimeMs >= startTimestampMs) { + const logText = await (0,promises_namespaceObject.readFile)(`${dir}/${fileName}`); + const buf = await doGzip(logText); + backtraces.set( + `backtrace_value_${source}_${fileName}`, + buf.toString("base64") + ); + } + } catch (innerError) { + backtraces.set( + `backtrace_failure_${source}_${fileName}`, + stringifyError(innerError) + ); + } + } + } + return backtraces; } async function collectBacktracesSystemd(prefixes, programNameDenyList, startTimestampMs) { - const sinceSeconds = Math.ceil((Date.now() - startTimestampMs) / 1e3) + START_SLOP_SECONDS; - const backtraces = /* @__PURE__ */ new Map(); - const coredumps = []; - try { - const { stdout: coredumpjson } = await exec.getExecOutput("coredumpctl", [ - "--json=pretty", - "list", - "--since", - `${sinceSeconds} seconds ago` - ], { silent: true }); - const sussyArray = JSON.parse(coredumpjson); - if (!Array.isArray(sussyArray)) throw new Error(`Coredump isn't an array: ${coredumpjson}`); - for (const sussyObject of sussyArray) { - const keys = Object.keys(sussyObject); - if (keys.includes("exe") && keys.includes("pid")) if (typeof sussyObject.exe == "string" && typeof sussyObject.pid == "number") { - const execParts = sussyObject.exe.split("/"); - const binaryName = execParts[execParts.length - 1]; - if (prefixes.some((prefix) => binaryName.startsWith(prefix)) && !programNameDenyList.includes(binaryName)) coredumps.push({ - exe: sussyObject.exe, - pid: sussyObject.pid - }); - } else core.debug(`Mysterious coredump entry missing exe string and/or pid number: ${JSON.stringify(sussyObject)}`); - else core.debug(`Mysterious coredump entry missing exe value and/or pid value: ${JSON.stringify(sussyObject)}`); - } - } catch (innerError) { - core.debug(`Cannot collect backtraces: ${stringifyError(innerError)}`); - return backtraces; - } - const doGzip = (0,external_node_util_.promisify)(external_node_zlib_.gzip); - for (const coredump of coredumps) try { - const { stdout: logText } = await exec.getExecOutput("coredumpctl", ["info", `${coredump.pid}`], { silent: true }); - const buf = await doGzip(logText); - backtraces.set(`backtrace_value_${coredump.pid}`, buf.toString("base64")); - } catch (innerError) { - backtraces.set(`backtrace_failure_${coredump.pid}`, stringifyError(innerError)); - } - return backtraces; + const sinceSeconds = Math.ceil((Date.now() - startTimestampMs) / 1e3) + START_SLOP_SECONDS; + const backtraces = /* @__PURE__ */ new Map(); + const coredumps = []; + try { + const { stdout: coredumpjson } = await exec.getExecOutput( + "coredumpctl", + ["--json=pretty", "list", "--since", `${sinceSeconds} seconds ago`], + { + silent: true + } + ); + const sussyArray = JSON.parse(coredumpjson); + if (!Array.isArray(sussyArray)) { + throw new Error(`Coredump isn't an array: ${coredumpjson}`); + } + for (const sussyObject of sussyArray) { + const keys = Object.keys(sussyObject); + if (keys.includes("exe") && keys.includes("pid")) { + if (typeof sussyObject.exe == "string" && typeof sussyObject.pid == "number") { + const execParts = sussyObject.exe.split("/"); + const binaryName = execParts[execParts.length - 1]; + if (prefixes.some((prefix) => binaryName.startsWith(prefix)) && !programNameDenyList.includes(binaryName)) { + coredumps.push({ + exe: sussyObject.exe, + pid: sussyObject.pid + }); + } + } else { + core.debug( + `Mysterious coredump entry missing exe string and/or pid number: ${JSON.stringify(sussyObject)}` + ); + } + } else { + core.debug( + `Mysterious coredump entry missing exe value and/or pid value: ${JSON.stringify(sussyObject)}` + ); + } + } + } catch (innerError) { + core.debug( + `Cannot collect backtraces: ${stringifyError(innerError)}` + ); + return backtraces; + } + const doGzip = (0,external_util_.promisify)(external_zlib_.gzip); + for (const coredump of coredumps) { + try { + const { stdout: logText } = await exec.getExecOutput( + "coredumpctl", + ["info", `${coredump.pid}`], + { + silent: true + } + ); + const buf = await doGzip(logText); + backtraces.set(`backtrace_value_${coredump.pid}`, buf.toString("base64")); + } catch (innerError) { + backtraces.set( + `backtrace_failure_${coredump.pid}`, + stringifyError(innerError) + ); + } + } + return backtraces; } -//#endregion -//#region src/correlation.ts -const OPTIONAL_VARIABLES = ["INVOCATION_ID"]; +// src/correlation.ts + + +var OPTIONAL_VARIABLES = ["INVOCATION_ID"]; function identify() { - const repository = hashEnvironmentVariables("GHR", [ - "GITHUB_SERVER_URL", - "GITHUB_REPOSITORY_OWNER", - "GITHUB_REPOSITORY_OWNER_ID", - "GITHUB_REPOSITORY", - "GITHUB_REPOSITORY_ID" - ]); - const run_differentiator = hashEnvironmentVariables("GHWJA", [ - "GITHUB_SERVER_URL", - "GITHUB_REPOSITORY_OWNER", - "GITHUB_REPOSITORY_OWNER_ID", - "GITHUB_REPOSITORY", - "GITHUB_REPOSITORY_ID", - "GITHUB_WORKFLOW", - "GITHUB_JOB", - "GITHUB_RUN_ID", - "GITHUB_RUN_NUMBER", - "GITHUB_RUN_ATTEMPT", - "INVOCATION_ID" - ]); - const ident = { - $anon_distinct_id: process.env["RUNNER_TRACKING_ID"] || (0,external_node_crypto_.randomUUID)(), - correlation_source: "github-actions", - github_repository_hash: repository, - github_workflow_hash: hashEnvironmentVariables("GHW", [ - "GITHUB_SERVER_URL", - "GITHUB_REPOSITORY_OWNER", - "GITHUB_REPOSITORY_OWNER_ID", - "GITHUB_REPOSITORY", - "GITHUB_REPOSITORY_ID", - "GITHUB_WORKFLOW" - ]), - github_workflow_job_hash: hashEnvironmentVariables("GHWJ", [ - "GITHUB_SERVER_URL", - "GITHUB_REPOSITORY_OWNER", - "GITHUB_REPOSITORY_OWNER_ID", - "GITHUB_REPOSITORY", - "GITHUB_REPOSITORY_ID", - "GITHUB_WORKFLOW", - "GITHUB_JOB" - ]), - github_workflow_run_hash: hashEnvironmentVariables("GHWJR", [ - "GITHUB_SERVER_URL", - "GITHUB_REPOSITORY_OWNER", - "GITHUB_REPOSITORY_OWNER_ID", - "GITHUB_REPOSITORY", - "GITHUB_REPOSITORY_ID", - "GITHUB_WORKFLOW", - "GITHUB_JOB", - "GITHUB_RUN_ID" - ]), - github_workflow_run_differentiator_hash: run_differentiator, - $session_id: run_differentiator, - $groups: { - github_repository: repository, - github_organization: hashEnvironmentVariables("GHO", [ - "GITHUB_SERVER_URL", - "GITHUB_REPOSITORY_OWNER", - "GITHUB_REPOSITORY_OWNER_ID" - ]) - }, - is_ci: true - }; - core.debug("Correlation data:"); - core.debug(JSON.stringify(ident, null, 2)); - return ident; + const repository = hashEnvironmentVariables("GHR", [ + "GITHUB_SERVER_URL", + "GITHUB_REPOSITORY_OWNER", + "GITHUB_REPOSITORY_OWNER_ID", + "GITHUB_REPOSITORY", + "GITHUB_REPOSITORY_ID" + ]); + const run_differentiator = hashEnvironmentVariables("GHWJA", [ + "GITHUB_SERVER_URL", + "GITHUB_REPOSITORY_OWNER", + "GITHUB_REPOSITORY_OWNER_ID", + "GITHUB_REPOSITORY", + "GITHUB_REPOSITORY_ID", + "GITHUB_WORKFLOW", + "GITHUB_JOB", + "GITHUB_RUN_ID", + "GITHUB_RUN_NUMBER", + "GITHUB_RUN_ATTEMPT", + "INVOCATION_ID" + ]); + const ident = { + $anon_distinct_id: process.env["RUNNER_TRACKING_ID"] || (0,external_crypto_.randomUUID)(), + correlation_source: "github-actions", + github_repository_hash: repository, + github_workflow_hash: hashEnvironmentVariables("GHW", [ + "GITHUB_SERVER_URL", + "GITHUB_REPOSITORY_OWNER", + "GITHUB_REPOSITORY_OWNER_ID", + "GITHUB_REPOSITORY", + "GITHUB_REPOSITORY_ID", + "GITHUB_WORKFLOW" + ]), + github_workflow_job_hash: hashEnvironmentVariables("GHWJ", [ + "GITHUB_SERVER_URL", + "GITHUB_REPOSITORY_OWNER", + "GITHUB_REPOSITORY_OWNER_ID", + "GITHUB_REPOSITORY", + "GITHUB_REPOSITORY_ID", + "GITHUB_WORKFLOW", + "GITHUB_JOB" + ]), + github_workflow_run_hash: hashEnvironmentVariables("GHWJR", [ + "GITHUB_SERVER_URL", + "GITHUB_REPOSITORY_OWNER", + "GITHUB_REPOSITORY_OWNER_ID", + "GITHUB_REPOSITORY", + "GITHUB_REPOSITORY_ID", + "GITHUB_WORKFLOW", + "GITHUB_JOB", + "GITHUB_RUN_ID" + ]), + github_workflow_run_differentiator_hash: run_differentiator, + $session_id: run_differentiator, + $groups: { + github_repository: repository, + github_organization: hashEnvironmentVariables("GHO", [ + "GITHUB_SERVER_URL", + "GITHUB_REPOSITORY_OWNER", + "GITHUB_REPOSITORY_OWNER_ID" + ]) + }, + is_ci: true + }; + core.debug("Correlation data:"); + core.debug(JSON.stringify(ident, null, 2)); + return ident; } function hashEnvironmentVariables(prefix, variables) { - const hash = (0,external_node_crypto_.createHash)("sha256"); - for (const varName of variables) { - let value = process.env[varName]; - if (value === void 0) if (OPTIONAL_VARIABLES.includes(varName)) { - core.debug(`Optional environment variable not set: ${varName} -- substituting with the variable name`); - value = varName; - } else { - core.debug(`Environment variable not set: ${varName} -- can't generate the requested identity`); - return; - } - hash.update(value); - hash.update("\0"); - } - return `${prefix}-${hash.digest("hex")}`; + const hash = (0,external_crypto_.createHash)("sha256"); + for (const varName of variables) { + let value = process.env[varName]; + if (value === void 0) { + if (OPTIONAL_VARIABLES.includes(varName)) { + core.debug( + `Optional environment variable not set: ${varName} -- substituting with the variable name` + ); + value = varName; + } else { + core.debug( + `Environment variable not set: ${varName} -- can't generate the requested identity` + ); + return void 0; + } + } + hash.update(value); + hash.update("\0"); + } + return `${prefix}-${hash.digest("hex")}`; } -//#endregion -//#region src/ids-host.ts -const DEFAULT_LOOKUP = "_detsys_ids._tcp.install.determinate.systems."; -const ALLOWED_SUFFIXES = [".install.determinate.systems", ".install.detsys.dev"]; -const DEFAULT_IDS_HOST = "https://install.determinate.systems"; -const LOOKUP = process.env["IDS_LOOKUP"] ?? DEFAULT_LOOKUP; -const DEFAULT_TIMEOUT = 1e4; -/** -* Host information for install.determinate.systems. -*/ +// src/ids-host.ts + + + +var DEFAULT_LOOKUP = "_detsys_ids._tcp.install.determinate.systems."; +var ALLOWED_SUFFIXES = [ + ".install.determinate.systems", + ".install.detsys.dev" +]; +var DEFAULT_IDS_HOST = "https://install.determinate.systems"; +var LOOKUP = process.env["IDS_LOOKUP"] ?? DEFAULT_LOOKUP; +var DEFAULT_TIMEOUT = 1e4; var IdsHost = class { - constructor(idsProjectName, diagnosticsSuffix, runtimeDiagnosticsUrl) { - this.idsProjectName = idsProjectName; - this.diagnosticsSuffix = diagnosticsSuffix; - this.runtimeDiagnosticsUrl = runtimeDiagnosticsUrl; - this.client = void 0; - } - async getGot(recordFailoverCallback) { - if (this.client === void 0) this.client = got.extend({ - timeout: { request: DEFAULT_TIMEOUT }, - retry: { - limit: Math.max((await this.getUrlsByPreference()).length, 3), - methods: ["GET", "HEAD"] - }, - hooks: { - beforeRetry: [async (error, retryCount) => { - const prevUrl = await this.getRootUrl(); - this.markCurrentHostBroken(); - const nextUrl = await this.getRootUrl(); - if (recordFailoverCallback !== void 0) recordFailoverCallback(error, prevUrl, nextUrl); - core.info(`Retrying after error ${error.code}, retry #: ${retryCount}`); - }], - beforeRequest: [async (options) => { - const currentUrl = options.url; - if (this.isUrlSubjectToDynamicUrls(currentUrl)) { - const newUrl = new URL(currentUrl); - newUrl.host = (await this.getRootUrl()).host; - options.url = newUrl; - core.debug(`Transmuted ${currentUrl} into ${newUrl}`); - } else core.debug(`No transmutations on ${currentUrl}`); - }] - } - }); - return this.client; - } - markCurrentHostBroken() { - this.prioritizedURLs?.shift(); - } - setPrioritizedUrls(urls) { - this.prioritizedURLs = urls; - } - isUrlSubjectToDynamicUrls(url) { - if (url.origin === DEFAULT_IDS_HOST) return true; - for (const suffix of ALLOWED_SUFFIXES) if (url.host.endsWith(suffix)) return true; - return false; - } - async getDynamicRootUrl() { - const idsHost = process.env["IDS_HOST"]; - if (idsHost !== void 0) try { - return new URL(idsHost); - } catch (err) { - core.error(`IDS_HOST environment variable is not a valid URL. Ignoring. ${stringifyError(err)}`); - } - let url = void 0; - try { - url = (await this.getUrlsByPreference())[0]; - } catch (err) { - core.error(`Error collecting IDS URLs by preference: ${stringifyError(err)}`); - } - if (url === void 0) return; - else return new URL(url); - } - async getRootUrl() { - const url = await this.getDynamicRootUrl(); - if (url === void 0) return new URL(DEFAULT_IDS_HOST); - return url; - } - async getDiagnosticsUrl() { - if (this.runtimeDiagnosticsUrl === "") return; - if (this.runtimeDiagnosticsUrl !== "-" && this.runtimeDiagnosticsUrl !== void 0) try { - return new URL(this.runtimeDiagnosticsUrl); - } catch (err) { - core.info(`User-provided diagnostic endpoint ignored: not a valid URL: ${stringifyError(err)}`); - } - try { - const diagnosticUrl = await this.getRootUrl(); - diagnosticUrl.pathname += "events/batch"; - return diagnosticUrl; - } catch (err) { - core.info(`Generated diagnostic endpoint ignored, and diagnostics are disabled: not a valid URL: ${stringifyError(err)}`); - return; - } - } - async getUrlsByPreference() { - if (this.prioritizedURLs === void 0) this.prioritizedURLs = orderRecordsByPriorityWeight(await discoverServiceRecords()).flatMap((record) => recordToUrl(record) || []); - return this.prioritizedURLs; - } + constructor(idsProjectName, diagnosticsSuffix, runtimeDiagnosticsUrl) { + this.idsProjectName = idsProjectName; + this.diagnosticsSuffix = diagnosticsSuffix; + this.runtimeDiagnosticsUrl = runtimeDiagnosticsUrl; + this.client = void 0; + } + async getGot(recordFailoverCallback) { + if (this.client === void 0) { + this.client = got.extend({ + timeout: { + request: DEFAULT_TIMEOUT + }, + retry: { + limit: Math.max((await this.getUrlsByPreference()).length, 3), + methods: ["GET", "HEAD"] + }, + hooks: { + beforeRetry: [ + async (error3, retryCount) => { + const prevUrl = await this.getRootUrl(); + this.markCurrentHostBroken(); + const nextUrl = await this.getRootUrl(); + if (recordFailoverCallback !== void 0) { + recordFailoverCallback(error3, prevUrl, nextUrl); + } + core.info( + `Retrying after error ${error3.code}, retry #: ${retryCount}` + ); + } + ], + beforeRequest: [ + async (options) => { + const currentUrl = options.url; + if (this.isUrlSubjectToDynamicUrls(currentUrl)) { + const newUrl = new URL(currentUrl); + const url = await this.getRootUrl(); + newUrl.host = url.host; + options.url = newUrl; + core.debug(`Transmuted ${currentUrl} into ${newUrl}`); + } else { + core.debug(`No transmutations on ${currentUrl}`); + } + } + ] + } + }); + } + return this.client; + } + markCurrentHostBroken() { + this.prioritizedURLs?.shift(); + } + setPrioritizedUrls(urls) { + this.prioritizedURLs = urls; + } + isUrlSubjectToDynamicUrls(url) { + if (url.origin === DEFAULT_IDS_HOST) { + return true; + } + for (const suffix of ALLOWED_SUFFIXES) { + if (url.host.endsWith(suffix)) { + return true; + } + } + return false; + } + async getDynamicRootUrl() { + const idsHost = process.env["IDS_HOST"]; + if (idsHost !== void 0) { + try { + return new URL(idsHost); + } catch (err) { + core.error( + `IDS_HOST environment variable is not a valid URL. Ignoring. ${stringifyError(err)}` + ); + } + } + let url = void 0; + try { + const urls = await this.getUrlsByPreference(); + url = urls[0]; + } catch (err) { + core.error( + `Error collecting IDS URLs by preference: ${stringifyError(err)}` + ); + } + if (url === void 0) { + return void 0; + } else { + return new URL(url); + } + } + async getRootUrl() { + const url = await this.getDynamicRootUrl(); + if (url === void 0) { + return new URL(DEFAULT_IDS_HOST); + } + return url; + } + async getDiagnosticsUrl() { + if (this.runtimeDiagnosticsUrl === "") { + return void 0; + } + if (this.runtimeDiagnosticsUrl !== "-" && this.runtimeDiagnosticsUrl !== void 0) { + try { + return new URL(this.runtimeDiagnosticsUrl); + } catch (err) { + core.info( + `User-provided diagnostic endpoint ignored: not a valid URL: ${stringifyError(err)}` + ); + } + } + try { + const diagnosticUrl = await this.getRootUrl(); + diagnosticUrl.pathname += "events/batch"; + return diagnosticUrl; + } catch (err) { + core.info( + `Generated diagnostic endpoint ignored, and diagnostics are disabled: not a valid URL: ${stringifyError(err)}` + ); + return void 0; + } + } + async getUrlsByPreference() { + if (this.prioritizedURLs === void 0) { + this.prioritizedURLs = orderRecordsByPriorityWeight( + await discoverServiceRecords() + ).flatMap((record) => recordToUrl(record) || []); + } + return this.prioritizedURLs; + } }; function recordToUrl(record) { - const urlStr = `https://${record.name}:${record.port}`; - try { - return new URL(urlStr); - } catch (err) { - core.debug(`Record ${JSON.stringify(record)} produced an invalid URL: ${urlStr} (${err})`); - return; - } + const urlStr = `https://${record.name}:${record.port}`; + try { + return new URL(urlStr); + } catch (err) { + core.debug( + `Record ${JSON.stringify(record)} produced an invalid URL: ${urlStr} (${err})` + ); + return void 0; + } } async function discoverServiceRecords() { - return await discoverServicesStub((0,external_node_dns_promises_namespaceObject.resolveSrv)(LOOKUP), 1e3); + return await discoverServicesStub((0,external_dns_promises_namespaceObject.resolveSrv)(LOOKUP), 1e3); } async function discoverServicesStub(lookup, timeout) { - const defaultFallback = new Promise((resolve, _reject) => { - setTimeout(resolve, timeout, []); - }); - let records; - try { - records = await Promise.race([lookup, defaultFallback]); - } catch (reason) { - core.debug(`Error resolving SRV records: ${stringifyError(reason)}`); - records = []; - } - const acceptableRecords = records.filter((record) => { - for (const suffix of ALLOWED_SUFFIXES) if (record.name.endsWith(suffix)) return true; - core.debug(`Unacceptable domain due to an invalid suffix: ${record.name}`); - return false; - }); - if (acceptableRecords.length === 0) core.debug(`No records found for ${LOOKUP}`); - else core.debug(`Resolved ${LOOKUP} to ${JSON.stringify(acceptableRecords)}`); - return acceptableRecords; + const defaultFallback = new Promise( + (resolve, _reject) => { + setTimeout(resolve, timeout, []); + } + ); + let records; + try { + records = await Promise.race([lookup, defaultFallback]); + } catch (reason) { + core.debug(`Error resolving SRV records: ${stringifyError(reason)}`); + records = []; + } + const acceptableRecords = records.filter((record) => { + for (const suffix of ALLOWED_SUFFIXES) { + if (record.name.endsWith(suffix)) { + return true; + } + } + core.debug( + `Unacceptable domain due to an invalid suffix: ${record.name}` + ); + return false; + }); + if (acceptableRecords.length === 0) { + core.debug(`No records found for ${LOOKUP}`); + } else { + core.debug( + `Resolved ${LOOKUP} to ${JSON.stringify(acceptableRecords)}` + ); + } + return acceptableRecords; } function orderRecordsByPriorityWeight(records) { - const byPriorityWeight = /* @__PURE__ */ new Map(); - for (const record of records) { - const existing = byPriorityWeight.get(record.priority); - if (existing) existing.push(record); - else byPriorityWeight.set(record.priority, [record]); - } - const prioritizedRecords = []; - const keys = Array.from(byPriorityWeight.keys()).sort((a, b) => a - b); - for (const priority of keys) { - const recordsByPrio = byPriorityWeight.get(priority); - if (recordsByPrio === void 0) continue; - prioritizedRecords.push(...weightedRandom(recordsByPrio)); - } - return prioritizedRecords; + const byPriorityWeight = /* @__PURE__ */ new Map(); + for (const record of records) { + const existing = byPriorityWeight.get(record.priority); + if (existing) { + existing.push(record); + } else { + byPriorityWeight.set(record.priority, [record]); + } + } + const prioritizedRecords = []; + const keys = Array.from(byPriorityWeight.keys()).sort( + (a, b) => a - b + ); + for (const priority of keys) { + const recordsByPrio = byPriorityWeight.get(priority); + if (recordsByPrio === void 0) { + continue; + } + prioritizedRecords.push(...weightedRandom(recordsByPrio)); + } + return prioritizedRecords; } function weightedRandom(records) { - const scratchRecords = records.slice(); - const result = []; - while (scratchRecords.length > 0) { - const weights = []; - for (let i = 0; i < scratchRecords.length; i++) weights.push(scratchRecords[i].weight + (i > 0 ? scratchRecords[i - 1].weight : 0)); - const point = Math.random() * weights[weights.length - 1]; - for (let selectedIndex = 0; selectedIndex < weights.length; selectedIndex++) if (weights[selectedIndex] > point) { - result.push(scratchRecords.splice(selectedIndex, 1)[0]); - break; - } - } - return result; + const scratchRecords = records.slice(); + const result = []; + while (scratchRecords.length > 0) { + const weights = []; + { + for (let i = 0; i < scratchRecords.length; i++) { + weights.push( + scratchRecords[i].weight + (i > 0 ? scratchRecords[i - 1].weight : 0) + ); + } + } + const point = Math.random() * weights[weights.length - 1]; + for (let selectedIndex = 0; selectedIndex < weights.length; selectedIndex++) { + if (weights[selectedIndex] > point) { + result.push(scratchRecords.splice(selectedIndex, 1)[0]); + break; + } + } + } + return result; } -//#endregion -//#region src/inputs.ts -var inputs_exports = __export({ - getArrayOfStrings: () => getArrayOfStrings, - getArrayOfStringsOrNull: () => getArrayOfStringsOrNull, - getBool: () => getBool, - getBoolOrUndefined: () => getBoolOrUndefined, - getMultilineStringOrNull: () => getMultilineStringOrNull, - getNumberOrNull: () => getNumberOrNull, - getString: () => getString, - getStringOrNull: () => getStringOrNull, - getStringOrUndefined: () => getStringOrUndefined, - handleString: () => handleString +// src/inputs.ts +var inputs_exports = {}; +__export(inputs_exports, { + getArrayOfStrings: () => getArrayOfStrings, + getArrayOfStringsOrNull: () => getArrayOfStringsOrNull, + getBool: () => getBool, + getBoolOrUndefined: () => getBoolOrUndefined, + getMultilineStringOrNull: () => getMultilineStringOrNull, + getNumberOrNull: () => getNumberOrNull, + getString: () => getString, + getStringOrNull: () => getStringOrNull, + getStringOrUndefined: () => getStringOrUndefined, + handleString: () => handleString }); -/** -* Get a Boolean input from the Action's configuration by name. -*/ -const getBool = (name) => { - return core.getBooleanInput(name); + +var getBool = (name) => { + return core.getBooleanInput(name); }; -/** -* Get a Boolean input from the Action's configuration by name, or undefined if it is unset. -*/ -const getBoolOrUndefined = (name) => { - if (getStringOrUndefined(name) === void 0) return; - return core.getBooleanInput(name); +var getBoolOrUndefined = (name) => { + if (getStringOrUndefined(name) === void 0) { + return void 0; + } + return core.getBooleanInput(name); }; -/** -* Convert a comma-separated string input into an array of strings. If `comma` is selected, -* all whitespace is removed from the string before converting to an array. -*/ -const getArrayOfStrings = (name, separator) => { - const original = getString(name); - return handleString(original, separator); +var getArrayOfStrings = (name, separator) => { + const original = getString(name); + return handleString(original, separator); }; -/** -* Convert a string input into an array of strings or `null` if no value is set. -*/ -const getArrayOfStringsOrNull = (name, separator) => { - const original = getStringOrNull(name); - if (original === null) return null; - else return handleString(original, separator); +var getArrayOfStringsOrNull = (name, separator) => { + const original = getStringOrNull(name); + if (original === null) { + return null; + } else { + return handleString(original, separator); + } }; -const handleString = (input, separator) => { - const sepChar = separator === "comma" ? "," : /\s+/; - const trimmed = input.trim(); - if (trimmed === "") return []; - return trimmed.split(sepChar).map((s) => s.trim()); +var handleString = (input, separator) => { + const sepChar = separator === "comma" ? "," : /\s+/; + const trimmed = input.trim(); + if (trimmed === "") { + return []; + } + return trimmed.split(sepChar).map((s) => s.trim()); }; -/** -* Get a multi-line string input from the Action's configuration by name or return `null` if not set. -*/ -const getMultilineStringOrNull = (name) => { - const value = core.getMultilineInput(name); - if (value.length === 0) return null; - else return value; +var getMultilineStringOrNull = (name) => { + const value = core.getMultilineInput(name); + if (value.length === 0) { + return null; + } else { + return value; + } }; -/** -* Get a number input from the Action's configuration by name or return `null` if not set. -*/ -const getNumberOrNull = (name) => { - const value = core.getInput(name); - if (value === "") return null; - else return Number(value); +var getNumberOrNull = (name) => { + const value = core.getInput(name); + if (value === "") { + return null; + } else { + return Number(value); + } }; -/** -* Get a string input from the Action's configuration. -*/ -const getString = (name) => { - return core.getInput(name); +var getString = (name) => { + return core.getInput(name); }; -/** -* Get a string input from the Action's configuration by name or return `null` if not set. -*/ -const getStringOrNull = (name) => { - const value = core.getInput(name); - if (value === "") return null; - else return value; +var getStringOrNull = (name) => { + const value = core.getInput(name); + if (value === "") { + return null; + } else { + return value; + } }; -/** -* Get a string input from the Action's configuration by name or return `undefined` if not set. -*/ -const getStringOrUndefined = (name) => { - const value = core.getInput(name); - if (value === "") return; - else return value; +var getStringOrUndefined = (name) => { + const value = core.getInput(name); + if (value === "") { + return void 0; + } else { + return value; + } }; -//#endregion -//#region src/platform.ts -var platform_exports = __export({ - getArchOs: () => getArchOs, - getNixPlatform: () => getNixPlatform +// src/platform.ts +var platform_exports = {}; +__export(platform_exports, { + getArchOs: () => getArchOs, + getNixPlatform: () => getNixPlatform }); -/** -* Get the current architecture plus OS. Examples include `X64-Linux` and `ARM64-macOS`. -*/ + function getArchOs() { - const envArch = process.env.RUNNER_ARCH; - const envOs = process.env.RUNNER_OS; - if (envArch && envOs) return `${envArch}-${envOs}`; - else { - core.error(`Can't identify the platform: RUNNER_ARCH or RUNNER_OS undefined (${envArch}-${envOs})`); - throw new Error("RUNNER_ARCH and/or RUNNER_OS is not defined"); - } + const envArch = process.env.RUNNER_ARCH; + const envOs = process.env.RUNNER_OS; + if (envArch && envOs) { + return `${envArch}-${envOs}`; + } else { + core.error( + `Can't identify the platform: RUNNER_ARCH or RUNNER_OS undefined (${envArch}-${envOs})` + ); + throw new Error("RUNNER_ARCH and/or RUNNER_OS is not defined"); + } } -/** -* Get the current Nix system. Examples include `x86_64-linux` and `aarch64-darwin`. -*/ function getNixPlatform(archOs) { - const mappedTo = new Map([ - ["X64-macOS", "x86_64-darwin"], - ["ARM64-macOS", "aarch64-darwin"], - ["X64-Linux", "x86_64-linux"], - ["ARM64-Linux", "aarch64-linux"] - ]).get(archOs); - if (mappedTo) return mappedTo; - else { - core.error(`ArchOs (${archOs}) doesn't map to a supported Nix platform.`); - throw new Error(`Cannot convert ArchOs (${archOs}) to a supported Nix platform.`); - } + const archOsMap = /* @__PURE__ */ new Map([ + ["X64-macOS", "x86_64-darwin"], + ["ARM64-macOS", "aarch64-darwin"], + ["X64-Linux", "x86_64-linux"], + ["ARM64-Linux", "aarch64-linux"] + ]); + const mappedTo = archOsMap.get(archOs); + if (mappedTo) { + return mappedTo; + } else { + core.error( + `ArchOs (${archOs}) doesn't map to a supported Nix platform.` + ); + throw new Error( + `Cannot convert ArchOs (${archOs}) to a supported Nix platform.` + ); + } } -//#endregion -//#region src/sourcedef.ts +// src/sourcedef.ts + function constructSourceParameters(legacyPrefix) { - return { - path: noisilyGetInput("path", legacyPrefix), - url: noisilyGetInput("url", legacyPrefix), - tag: noisilyGetInput("tag", legacyPrefix), - pr: noisilyGetInput("pr", legacyPrefix), - branch: noisilyGetInput("branch", legacyPrefix), - revision: noisilyGetInput("revision", legacyPrefix) - }; + return { + path: noisilyGetInput("path", legacyPrefix), + url: noisilyGetInput("url", legacyPrefix), + tag: noisilyGetInput("tag", legacyPrefix), + pr: noisilyGetInput("pr", legacyPrefix), + branch: noisilyGetInput("branch", legacyPrefix), + revision: noisilyGetInput("revision", legacyPrefix) + }; } function noisilyGetInput(suffix, legacyPrefix) { - const preferredInput = getStringOrUndefined(`source-${suffix}`); - if (!legacyPrefix) return preferredInput; - const legacyInput = getStringOrUndefined(`${legacyPrefix}-${suffix}`); - if (preferredInput && legacyInput) { - core.warning(`The supported option source-${suffix} and the legacy option ${legacyPrefix}-${suffix} are both set. Preferring source-${suffix}. Please stop setting ${legacyPrefix}-${suffix}.`); - return preferredInput; - } else if (legacyInput) { - core.warning(`The legacy option ${legacyPrefix}-${suffix} is set. Please migrate to source-${suffix}.`); - return legacyInput; - } else return preferredInput; + const preferredInput = getStringOrUndefined(`source-${suffix}`); + if (!legacyPrefix) { + return preferredInput; + } + const legacyInput = getStringOrUndefined(`${legacyPrefix}-${suffix}`); + if (preferredInput && legacyInput) { + core.warning( + `The supported option source-${suffix} and the legacy option ${legacyPrefix}-${suffix} are both set. Preferring source-${suffix}. Please stop setting ${legacyPrefix}-${suffix}.` + ); + return preferredInput; + } else if (legacyInput) { + core.warning( + `The legacy option ${legacyPrefix}-${suffix} is set. Please migrate to source-${suffix}.` + ); + return legacyInput; + } else { + return preferredInput; + } } -//#endregion -//#region src/index.ts -const pkgVersion = "1.0"; -const EVENT_BACKTRACES = "backtrace"; -const EVENT_EXCEPTION = "exception"; -const EVENT_ARTIFACT_CACHE_HIT = "artifact_cache_hit"; -const EVENT_ARTIFACT_CACHE_MISS = "artifact_cache_miss"; -const EVENT_ARTIFACT_CACHE_PERSIST = "artifact_cache_persist"; -const EVENT_PREFLIGHT_REQUIRE_NIX_DENIED = "preflight-require-nix-denied"; -const EVENT_STORE_IDENTITY_FAILED = "store_identity_failed"; -const FACT_ARTIFACT_FETCHED_FROM_CACHE = "artifact_fetched_from_cache"; -const FACT_ENDED_WITH_EXCEPTION = "ended_with_exception"; -const FACT_FINAL_EXCEPTION = "final_exception"; -const FACT_OS = "$os"; -const FACT_OS_VERSION = "$os_version"; -const FACT_SOURCE_URL = "source_url"; -const FACT_SOURCE_URL_ETAG = "source_url_etag"; -const FACT_NIX_VERSION = "nix_version"; -const FACT_NIX_LOCATION = "nix_location"; -const FACT_NIX_STORE_TRUST = "nix_store_trusted"; -const FACT_NIX_STORE_VERSION = "nix_store_version"; -const FACT_NIX_STORE_CHECK_METHOD = "nix_store_check_method"; -const FACT_NIX_STORE_CHECK_ERROR = "nix_store_check_error"; -const STATE_KEY_EXECUTION_PHASE = "detsys_action_execution_phase"; -const STATE_KEY_NIX_NOT_FOUND = "detsys_action_nix_not_found"; -const STATE_NOT_FOUND = "not-found"; -const STATE_KEY_CROSS_PHASE_ID = "detsys_cross_phase_id"; -const STATE_BACKTRACE_START_TIMESTAMP = "detsys_backtrace_start_timestamp"; -const DIAGNOSTIC_ENDPOINT_TIMEOUT_MS = 1e4; -const CHECK_IN_ENDPOINT_TIMEOUT_MS = 1e3; -const PROGRAM_NAME_CRASH_DENY_LIST = [ - "nix-expr-tests", - "nix-store-tests", - "nix-util-tests" +// src/index.ts + + + + + + + + + + + + + +var pkgVersion = "1.0"; +var EVENT_BACKTRACES = "backtrace"; +var EVENT_EXCEPTION = "exception"; +var EVENT_ARTIFACT_CACHE_HIT = "artifact_cache_hit"; +var EVENT_ARTIFACT_CACHE_MISS = "artifact_cache_miss"; +var EVENT_ARTIFACT_CACHE_PERSIST = "artifact_cache_persist"; +var EVENT_PREFLIGHT_REQUIRE_NIX_DENIED = "preflight-require-nix-denied"; +var EVENT_STORE_IDENTITY_FAILED = "store_identity_failed"; +var FACT_ARTIFACT_FETCHED_FROM_CACHE = "artifact_fetched_from_cache"; +var FACT_ENDED_WITH_EXCEPTION = "ended_with_exception"; +var FACT_FINAL_EXCEPTION = "final_exception"; +var FACT_OS = "$os"; +var FACT_OS_VERSION = "$os_version"; +var FACT_SOURCE_URL = "source_url"; +var FACT_SOURCE_URL_ETAG = "source_url_etag"; +var FACT_NIX_LOCATION = "nix_location"; +var FACT_NIX_STORE_TRUST = "nix_store_trusted"; +var FACT_NIX_STORE_VERSION = "nix_store_version"; +var FACT_NIX_STORE_CHECK_METHOD = "nix_store_check_method"; +var FACT_NIX_STORE_CHECK_ERROR = "nix_store_check_error"; +var STATE_KEY_EXECUTION_PHASE = "detsys_action_execution_phase"; +var STATE_KEY_NIX_NOT_FOUND = "detsys_action_nix_not_found"; +var STATE_NOT_FOUND = "not-found"; +var STATE_KEY_CROSS_PHASE_ID = "detsys_cross_phase_id"; +var STATE_BACKTRACE_START_TIMESTAMP = "detsys_backtrace_start_timestamp"; +var DIAGNOSTIC_ENDPOINT_TIMEOUT_MS = 1e4; +var CHECK_IN_ENDPOINT_TIMEOUT_MS = 1e3; +var PROGRAM_NAME_CRASH_DENY_LIST = [ + "nix-expr-tests", + "nix-store-tests", + "nix-util-tests" ]; -const determinateStateDir = "/var/lib/determinate"; -const determinateIdentityFile = external_node_path_namespaceObject.join(determinateStateDir, "identity.json"); -const isRoot = external_node_os_.userInfo().uid === 0; -/** Create the Determinate state directory by escalating via sudo */ +var determinateStateDir = "/var/lib/determinate"; +var determinateIdentityFile = external_path_.join(determinateStateDir, "identity.json"); +var isRoot = external_os_.userInfo().uid === 0; async function sudoEnsureDeterminateStateDir() { - const code = await exec.exec("sudo", [ - "mkdir", - "-p", - determinateStateDir - ]); - if (code !== 0) throw new Error(`sudo mkdir -p exit: ${code}`); + const code = await exec.exec("sudo", [ + "mkdir", + "-p", + determinateStateDir + ]); + if (code !== 0) { + throw new Error(`sudo mkdir -p exit: ${code}`); + } } -/** Ensures the Determinate state directory exists, escalating if necessary */ async function ensureDeterminateStateDir() { - if (isRoot) await (0,promises_namespaceObject.mkdir)(determinateStateDir, { recursive: true }); - else return sudoEnsureDeterminateStateDir(); + if (isRoot) { + await (0,promises_namespaceObject.mkdir)(determinateStateDir, { recursive: true }); + } else { + return sudoEnsureDeterminateStateDir(); + } } -/** Writes correlation hashes to the Determinate state directory by writing to a `sudo tee` pipe */ async function sudoWriteCorrelationHashes(hashes) { - const buffer = Buffer.from(hashes); - const code = await exec.exec("sudo", ["tee", determinateIdentityFile], { - input: buffer, - outStream: (0,external_node_fs_.createWriteStream)("/dev/null") - }); - if (code !== 0) throw new Error(`sudo tee exit: ${code}`); + const buffer = Buffer.from(hashes); + const code = await exec.exec( + "sudo", + ["tee", determinateIdentityFile], + { + input: buffer, + // Ignore output from tee + outStream: (0,external_fs_.createWriteStream)("/dev/null") + } + ); + if (code !== 0) { + throw new Error(`sudo tee exit: ${code}`); + } } -/** Writes correlation hashes to the Determinate state directory, escalating if necessary */ async function writeCorrelationHashes(hashes) { - await ensureDeterminateStateDir(); - if (isRoot) await promises_namespaceObject.writeFile(determinateIdentityFile, hashes, "utf-8"); - else return sudoWriteCorrelationHashes(hashes); + await ensureDeterminateStateDir(); + if (isRoot) { + await promises_namespaceObject.writeFile(determinateIdentityFile, hashes, "utf-8"); + } else { + return sudoWriteCorrelationHashes(hashes); + } } var DetSysAction = class { - determineExecutionPhase() { - if (core.getState(STATE_KEY_EXECUTION_PHASE) === "") { - core.saveState(STATE_KEY_EXECUTION_PHASE, "post"); - return "main"; - } else return "post"; - } - constructor(actionOptions) { - this.actionOptions = makeOptionsConfident(actionOptions); - this.idsHost = new IdsHost(this.actionOptions.idsProjectName, actionOptions.diagnosticsSuffix, process.env["INPUT_DIAGNOSTIC-ENDPOINT"]); - this.exceptionAttachments = /* @__PURE__ */ new Map(); - this.nixStoreTrust = "unknown"; - this.strictMode = getBool("_internal-strict-mode"); - if (getBoolOrUndefined("_internal-obliterate-actions-id-token-request-variables") === true) { - process.env["ACTIONS_ID_TOKEN_REQUEST_URL"] = void 0; - process.env["ACTIONS_ID_TOKEN_REQUEST_TOKEN"] = void 0; - } - this.features = {}; - this.featureEventMetadata = {}; - this.events = []; - this.getCrossPhaseId(); - this.collectBacktraceSetup(); - this.facts = { - $lib: "idslib", - $lib_version: pkgVersion, - project: this.actionOptions.name, - ids_project: this.actionOptions.idsProjectName - }; - const params = [ - ["github_action_ref", "GITHUB_ACTION_REF"], - ["github_action_repository", "GITHUB_ACTION_REPOSITORY"], - ["github_event_name", "GITHUB_EVENT_NAME"], - ["$os", "RUNNER_OS"], - ["arch", "RUNNER_ARCH"] - ]; - for (const [target, env] of params) { - const value = process.env[env]; - if (value) this.facts[target] = value; - } - this.identity = identify(); - this.archOs = getArchOs(); - this.nixSystem = getNixPlatform(this.archOs); - this.facts.$app_name = `${this.actionOptions.name}/action`; - this.facts.arch_os = this.archOs; - this.facts.nix_system = this.nixSystem; - getDetails().then((details) => { - if (details.name !== "unknown") this.addFact(FACT_OS, details.name); - if (details.version !== "unknown") this.addFact(FACT_OS_VERSION, details.version); - }).catch((e) => { - core.debug(`Failure getting platform details: ${stringifyError$1(e)}`); - }); - this.executionPhase = this.determineExecutionPhase(); - this.facts.execution_phase = this.executionPhase; - if (this.actionOptions.fetchStyle === "gh-env-style") this.architectureFetchSuffix = this.archOs; - else if (this.actionOptions.fetchStyle === "nix-style") this.architectureFetchSuffix = this.nixSystem; - else if (this.actionOptions.fetchStyle === "universal") this.architectureFetchSuffix = "universal"; - else throw new Error(`fetchStyle ${this.actionOptions.fetchStyle} is not a valid style`); - this.sourceParameters = constructSourceParameters(this.actionOptions.legacySourcePrefix); - this.recordEvent(`begin_${this.executionPhase}`); - } - /** - * Attach a file to the diagnostics data in error conditions. - * - * The file at `location` doesn't need to exist when stapleFile is called. - * - * If the file doesn't exist or is unreadable when trying to staple the attachments, the JS error will be stored in a context value at `staple_failure_{name}`. - * If the file is readable, the file's contents will be stored in a context value at `staple_value_{name}`. - */ - stapleFile(name, location) { - this.exceptionAttachments.set(name, location); - } - /** - * Execute the Action as defined. - */ - execute() { - this.executeAsync().catch((error) => { - console.log(error); - process.exitCode = 1; - }); - } - getTemporaryName() { - const tmpDir = process.env["RUNNER_TEMP"] || (0,external_node_os_.tmpdir)(); - return external_node_path_namespaceObject.join(tmpDir, `${this.actionOptions.name}-${(0,external_node_crypto_.randomUUID)()}`); - } - addFact(key, value) { - this.facts[key] = value; - } - async getDiagnosticsUrl() { - return await this.idsHost.getDiagnosticsUrl(); - } - getUniqueId() { - return this.identity.github_workflow_run_differentiator_hash || process.env.RUNNER_TRACKING_ID || (0,external_node_crypto_.randomUUID)(); - } - getCrossPhaseId() { - let crossPhaseId = core.getState(STATE_KEY_CROSS_PHASE_ID); - if (crossPhaseId === "") { - crossPhaseId = (0,external_node_crypto_.randomUUID)(); - core.saveState(STATE_KEY_CROSS_PHASE_ID, crossPhaseId); - } - return crossPhaseId; - } - getCorrelationHashes() { - return this.identity; - } - recordEvent(eventName, context = {}) { - const prefixedName = eventName === "$feature_flag_called" ? eventName : `${this.actionOptions.eventPrefix}${eventName}`; - this.events.push({ - name: prefixedName, - distinct_id: this.identity.$anon_distinct_id, - uuid: (0,external_node_crypto_.randomUUID)(), - timestamp: /* @__PURE__ */ new Date(), - properties: { - ...context, - ...this.identity, - ...this.facts, - ...Object.fromEntries(Object.entries(this.featureEventMetadata).map(([name, variant]) => [`$feature/${name}`, variant])) - } - }); - } - /** - * Unpacks the closure returned by `fetchArtifact()`, imports the - * contents into the Nix store, and returns the path of the executable at - * `/nix/store/STORE_PATH/bin/${bin}`. - */ - async unpackClosure(bin) { - const artifact = await this.fetchArtifact(); - const { stdout } = await (0,external_node_util_.promisify)(external_node_child_process_namespaceObject.exec)(`cat "${artifact}" | xz -d | nix-store --import`); - return `${stdout.split(external_node_os_.EOL).at(-2)}/bin/${bin}`; - } - /** - * Fetches the executable at the URL determined by the `source-*` inputs and - * other facts, `chmod`s it, and returns the path to the executable on disk. - */ - async fetchExecutable() { - const binaryPath = await this.fetchArtifact(); - await (0,promises_namespaceObject.chmod)(binaryPath, external_node_fs_.constants.S_IXUSR | external_node_fs_.constants.S_IXGRP); - return binaryPath; - } - get isMain() { - return this.executionPhase === "main"; - } - get isPost() { - return this.executionPhase === "post"; - } - async executeAsync() { - try { - await this.checkIn(); - const correlationHashes = JSON.stringify(this.getCorrelationHashes()); - process.env.DETSYS_CORRELATION = correlationHashes; - try { - await writeCorrelationHashes(correlationHashes); - } catch (error) { - this.recordEvent(EVENT_STORE_IDENTITY_FAILED, { error: String(error) }); - } - if (!await this.preflightRequireNix()) { - this.recordEvent(EVENT_PREFLIGHT_REQUIRE_NIX_DENIED); - return; - } else { - await this.preflightNixStoreInfo(); - await this.preflightNixVersion(); - this.addFact(FACT_NIX_STORE_TRUST, this.nixStoreTrust); - } - if (this.isMain) { - await this.main(); - await this.preflightNixVersion(); - } else if (this.isPost) await this.post(); - this.addFact(FACT_ENDED_WITH_EXCEPTION, false); - } catch (e) { - this.addFact(FACT_ENDED_WITH_EXCEPTION, true); - const reportable = stringifyError$1(e); - this.addFact(FACT_FINAL_EXCEPTION, reportable); - if (this.isPost) core.warning(reportable); - else core.setFailed(reportable); - const doGzip = (0,external_node_util_.promisify)(external_node_zlib_.gzip); - const exceptionContext = /* @__PURE__ */ new Map(); - for (const [attachmentLabel, filePath] of this.exceptionAttachments) try { - const logText = (0,external_node_fs_.readFileSync)(filePath); - const buf = await doGzip(logText); - exceptionContext.set(`staple_value_${attachmentLabel}`, buf.toString("base64")); - } catch (innerError) { - exceptionContext.set(`staple_failure_${attachmentLabel}`, stringifyError$1(innerError)); - } - this.recordEvent(EVENT_EXCEPTION, Object.fromEntries(exceptionContext)); - } finally { - if (this.isPost) await this.collectBacktraces(); - await this.complete(); - } - } - async getClient() { - return await this.idsHost.getGot((incitingError, prevUrl, nextUrl) => { - this.recordPlausibleTimeout(incitingError); - this.recordEvent("ids-failover", { - previousUrl: prevUrl.toString(), - nextUrl: nextUrl.toString() - }); - }); - } - async checkIn() { - const checkin = await this.requestCheckIn(); - if (checkin === void 0) return; - this.features = checkin.options; - for (const [key, feature] of Object.entries(this.features)) this.featureEventMetadata[key] = feature.variant; - const impactSymbol = new Map([ - ["none", "⚪"], - ["maintenance", "🛠️"], - ["minor", "🟡"], - ["major", "🟠"], - ["critical", "🔴"] - ]); - const defaultImpactSymbol = "🔵"; - if (checkin.status !== null) { - const summaries = []; - for (const incident of checkin.status.incidents) summaries.push(`${impactSymbol.get(incident.impact) || defaultImpactSymbol} ${incident.status.replace("_", " ")}: ${incident.name} (${incident.shortlink})`); - for (const maintenance of checkin.status.scheduled_maintenances) summaries.push(`${impactSymbol.get(maintenance.impact) || defaultImpactSymbol} ${maintenance.status.replace("_", " ")}: ${maintenance.name} (${maintenance.shortlink})`); - if (summaries.length > 0) { - core.info(`${checkin.status.page.name} Status`); - for (const notice of summaries) core.info(notice); - core.info(`See: ${checkin.status.page.url}`); - core.info(``); - } - } - } - getFeature(name) { - if (!this.features.hasOwnProperty(name)) return; - const result = this.features[name]; - if (result === void 0) return; - this.recordEvent("$feature_flag_called", { - $feature_flag: name, - $feature_flag_response: result.variant - }); - return result; - } - /** - * Check in to install.determinate.systems, to accomplish three things: - * - * 1. Preflight the server selected from IdsHost, to increase the chances of success. - * 2. Fetch any incidents and maintenance events to let users know in case things are weird. - * 3. Get feature flag data so we can gently roll out new features. - */ - async requestCheckIn() { - for (let attemptsRemaining = 5; attemptsRemaining > 0; attemptsRemaining--) { - const checkInUrl = await this.getCheckInUrl(); - if (checkInUrl === void 0) return; - try { - core.debug(`Preflighting via ${checkInUrl}`); - const props = { - distinct_id: this.identity.$anon_distinct_id, - anon_distinct_id: this.identity.$anon_distinct_id, - groups: this.identity.$groups, - person_properties: { - ci: "github", - ...this.identity, - ...this.facts - } - }; - return await (await this.getClient()).post(checkInUrl, { - json: props, - timeout: { request: CHECK_IN_ENDPOINT_TIMEOUT_MS } - }).json(); - } catch (e) { - this.recordPlausibleTimeout(e); - core.debug(`Error checking in: ${stringifyError$1(e)}`); - this.idsHost.markCurrentHostBroken(); - } - } - } - recordPlausibleTimeout(e) { - if (e instanceof TimeoutError && "timings" in e && "request" in e) { - const reportContext = { - url: e.request.requestUrl?.toString(), - retry_count: e.request.retryCount - }; - for (const [key, value] of Object.entries(e.timings.phases)) if (Number.isFinite(value)) reportContext[`timing_phase_${key}`] = value; - this.recordEvent("timeout", reportContext); - } - } - /** - * Fetch an artifact, such as a tarball, from the location determined by the - * `source-*` inputs. If `source-binary` is specified, this will return a path - * to a binary on disk; otherwise, the artifact will be downloaded from the - * URL determined by the other `source-*` inputs (`source-url`, `source-pr`, - * etc.). - */ - async fetchArtifact() { - const sourceBinary = getStringOrNull("source-binary"); - if (sourceBinary !== null && sourceBinary !== "") { - core.debug(`Using the provided source binary at ${sourceBinary}`); - return sourceBinary; - } - core.startGroup(`Downloading ${this.actionOptions.name} for ${this.architectureFetchSuffix}`); - try { - core.info(`Fetching from ${await this.getSourceUrl()}`); - const correlatedUrl = await this.getSourceUrl(); - correlatedUrl.searchParams.set("ci", "github"); - correlatedUrl.searchParams.set("correlation", JSON.stringify(this.identity)); - const versionCheckup = await (await this.getClient()).head(correlatedUrl); - if (versionCheckup.headers.etag) { - const v = versionCheckup.headers.etag; - this.addFact(FACT_SOURCE_URL_ETAG, v); - core.debug(`Checking the tool cache for ${await this.getSourceUrl()} at ${v}`); - const cached = await this.getCachedVersion(v); - if (cached) { - this.facts[FACT_ARTIFACT_FETCHED_FROM_CACHE] = true; - core.debug(`Tool cache hit.`); - return cached; - } - } - this.facts[FACT_ARTIFACT_FETCHED_FROM_CACHE] = false; - core.debug(`No match from the cache, re-fetching from the redirect: ${versionCheckup.url}`); - const destFile = this.getTemporaryName(); - const fetchStream = await this.downloadFile(new URL(versionCheckup.url), destFile); - if (fetchStream.response?.headers.etag) { - const v = fetchStream.response.headers.etag; - try { - await this.saveCachedVersion(v, destFile); - } catch (e) { - core.debug(`Error caching the artifact: ${stringifyError$1(e)}`); - } - } - return destFile; - } catch (e) { - this.recordPlausibleTimeout(e); - throw e; - } finally { - core.endGroup(); - } - } - /** - * A helper function for failing on error only if strict mode is enabled. - * This is intended only for CI environments testing Actions themselves. - */ - failOnError(msg) { - if (this.strictMode) core.setFailed(`strict mode failure: ${msg}`); - } - async downloadFile(url, destination) { - const client = await this.getClient(); - return new Promise((resolve, reject) => { - let writeStream; - let failed = false; - const retry = (stream) => { - if (writeStream) writeStream.destroy(); - writeStream = (0,external_node_fs_.createWriteStream)(destination, { - encoding: "binary", - mode: 493 - }); - writeStream.once("error", (error) => { - failed = true; - reject(error); - }); - writeStream.on("finish", () => { - if (!failed) resolve(stream); - }); - stream.once("retry", (_count, _error, createRetryStream) => { - retry(createRetryStream()); - }); - stream.pipe(writeStream); - }; - retry(client.stream(url)); - }); - } - async complete() { - this.recordEvent(`complete_${this.executionPhase}`); - await this.submitEvents(); - } - async getCheckInUrl() { - const checkInUrl = await this.idsHost.getDynamicRootUrl(); - if (checkInUrl === void 0) return; - checkInUrl.pathname += "check-in"; - return checkInUrl; - } - async getSourceUrl() { - const p = this.sourceParameters; - if (p.url) { - this.addFact(FACT_SOURCE_URL, p.url); - return new URL(p.url); - } - const fetchUrl = await this.idsHost.getRootUrl(); - fetchUrl.pathname += this.actionOptions.idsProjectName; - if (p.tag) fetchUrl.pathname += `/tag/${p.tag}`; - else if (p.pr) fetchUrl.pathname += `/pr/${p.pr}`; - else if (p.branch) fetchUrl.pathname += `/branch/${p.branch}`; - else if (p.revision) fetchUrl.pathname += `/rev/${p.revision}`; - else fetchUrl.pathname += `/stable`; - fetchUrl.pathname += `/${this.architectureFetchSuffix}`; - this.addFact(FACT_SOURCE_URL, fetchUrl.toString()); - return fetchUrl; - } - cacheKey(version) { - const cleanedVersion = version.replace(/[^a-zA-Z0-9-+.]/g, ""); - return `determinatesystem-${this.actionOptions.name}-${this.architectureFetchSuffix}-${cleanedVersion}`; - } - async getCachedVersion(version) { - const startCwd = process.cwd(); - try { - const tempDir = this.getTemporaryName(); - await (0,promises_namespaceObject.mkdir)(tempDir); - process.chdir(tempDir); - process.env.GITHUB_WORKSPACE_BACKUP = process.env.GITHUB_WORKSPACE; - delete process.env.GITHUB_WORKSPACE; - if (await cache.restoreCache([this.actionOptions.name], this.cacheKey(version), [], void 0, true)) { - this.recordEvent(EVENT_ARTIFACT_CACHE_HIT); - return `${tempDir}/${this.actionOptions.name}`; - } - this.recordEvent(EVENT_ARTIFACT_CACHE_MISS); - return; - } finally { - process.env.GITHUB_WORKSPACE = process.env.GITHUB_WORKSPACE_BACKUP; - delete process.env.GITHUB_WORKSPACE_BACKUP; - process.chdir(startCwd); - } - } - async saveCachedVersion(version, toolPath) { - const startCwd = process.cwd(); - try { - const tempDir = this.getTemporaryName(); - await (0,promises_namespaceObject.mkdir)(tempDir); - process.chdir(tempDir); - await (0,promises_namespaceObject.copyFile)(toolPath, `${tempDir}/${this.actionOptions.name}`); - process.env.GITHUB_WORKSPACE_BACKUP = process.env.GITHUB_WORKSPACE; - delete process.env.GITHUB_WORKSPACE; - await cache.saveCache([this.actionOptions.name], this.cacheKey(version), void 0, true); - this.recordEvent(EVENT_ARTIFACT_CACHE_PERSIST); - } finally { - process.env.GITHUB_WORKSPACE = process.env.GITHUB_WORKSPACE_BACKUP; - delete process.env.GITHUB_WORKSPACE_BACKUP; - process.chdir(startCwd); - } - } - collectBacktraceSetup() { - if (!process.env.DETSYS_BACKTRACE_COLLECTOR) { - core.exportVariable("DETSYS_BACKTRACE_COLLECTOR", this.getCrossPhaseId()); - core.saveState(STATE_BACKTRACE_START_TIMESTAMP, Date.now()); - } - } - async collectBacktraces() { - try { - if (process.env.DETSYS_BACKTRACE_COLLECTOR !== this.getCrossPhaseId()) return; - const backtraces = await collectBacktraces(this.actionOptions.binaryNamePrefixes, this.actionOptions.binaryNamesDenyList, parseInt(core.getState(STATE_BACKTRACE_START_TIMESTAMP))); - core.debug(`Backtraces identified: ${backtraces.size}`); - if (backtraces.size > 0) this.recordEvent(EVENT_BACKTRACES, Object.fromEntries(backtraces)); - } catch (innerError) { - core.debug(`Error collecting backtraces: ${stringifyError$1(innerError)}`); - } - } - async preflightRequireNix() { - let nixLocation; - const pathParts = (process.env["PATH"] || "").split(":"); - for (const location of pathParts) { - const candidateNix = external_node_path_namespaceObject.join(location, "nix"); - try { - await promises_namespaceObject.access(candidateNix, promises_namespaceObject.constants.X_OK); - core.debug(`Found Nix at ${candidateNix}`); - nixLocation = candidateNix; - break; - } catch { - core.debug(`Nix not at ${candidateNix}`); - } - } - this.addFact(FACT_NIX_LOCATION, nixLocation || ""); - if (this.actionOptions.requireNix === "ignore") return true; - if (core.getState(STATE_KEY_NIX_NOT_FOUND) === STATE_NOT_FOUND) return false; - if (nixLocation !== void 0) return true; - core.saveState(STATE_KEY_NIX_NOT_FOUND, STATE_NOT_FOUND); - switch (this.actionOptions.requireNix) { - case "fail": - core.setFailed(["This action can only be used when Nix is installed.", "Add `- uses: DeterminateSystems/determinate-nix-action@v3` earlier in your workflow."].join(" ")); - break; - case "warn": - core.warning(["This action is in no-op mode because Nix is not installed.", "Add `- uses: DeterminateSystems/determinate-nix-action@v3` earlier in your workflow."].join(" ")); - break; - } - return false; - } - async preflightNixStoreInfo() { - let output = ""; - const options = {}; - options.silent = true; - options.listeners = { stdout: (data) => { - output += data.toString(); - } }; - try { - output = ""; - await exec.exec("nix", [ - "store", - "info", - "--json" - ], options); - this.addFact(FACT_NIX_STORE_CHECK_METHOD, "info"); - } catch { - try { - output = ""; - await exec.exec("nix", [ - "store", - "ping", - "--json" - ], options); - this.addFact(FACT_NIX_STORE_CHECK_METHOD, "ping"); - } catch { - this.addFact(FACT_NIX_STORE_CHECK_METHOD, "none"); - return; - } - } - try { - const parsed = JSON.parse(output); - if (parsed.trusted === 1) this.nixStoreTrust = "trusted"; - else if (parsed.trusted === 0) this.nixStoreTrust = "untrusted"; - else if (parsed.trusted !== void 0) this.addFact(FACT_NIX_STORE_CHECK_ERROR, `Mysterious trusted value: ${JSON.stringify(parsed.trusted)}`); - this.addFact(FACT_NIX_STORE_VERSION, JSON.stringify(parsed.version)); - } catch (e) { - this.addFact(FACT_NIX_STORE_CHECK_ERROR, stringifyError$1(e)); - } - } - async preflightNixVersion() { - let output = "unknown"; - try { - ({stdout: output} = await exec.getExecOutput("nix", ["--version"], { silent: true })); - output = output.trim() || "unknown"; - } catch {} - this.addFact(FACT_NIX_VERSION, output); - } - async submitEvents() { - const diagnosticsUrl = await this.idsHost.getDiagnosticsUrl(); - if (diagnosticsUrl === void 0) { - core.debug("Diagnostics are disabled. Not sending the following events:"); - core.debug(JSON.stringify(this.events, void 0, 2)); - return; - } - const batch = { - sent_at: /* @__PURE__ */ new Date(), - batch: this.events - }; - try { - await (await this.getClient()).post(diagnosticsUrl, { - json: batch, - timeout: { request: DIAGNOSTIC_ENDPOINT_TIMEOUT_MS } - }); - } catch (err) { - this.recordPlausibleTimeout(err); - core.debug(`Error submitting diagnostics event to ${diagnosticsUrl}: ${stringifyError$1(err)}`); - } - this.events = []; - } + determineExecutionPhase() { + const currentPhase = core.getState(STATE_KEY_EXECUTION_PHASE); + if (currentPhase === "") { + core.saveState(STATE_KEY_EXECUTION_PHASE, "post"); + return "main"; + } else { + return "post"; + } + } + constructor(actionOptions) { + this.actionOptions = makeOptionsConfident(actionOptions); + this.idsHost = new IdsHost( + this.actionOptions.idsProjectName, + actionOptions.diagnosticsSuffix, + // Note: we don't use actionsCore.getInput('diagnostic-endpoint') on purpose: + // getInput silently converts absent data to an empty string. + process.env["INPUT_DIAGNOSTIC-ENDPOINT"] + ); + this.exceptionAttachments = /* @__PURE__ */ new Map(); + this.nixStoreTrust = "unknown"; + this.strictMode = getBool("_internal-strict-mode"); + if (getBoolOrUndefined( + "_internal-obliterate-actions-id-token-request-variables" + ) === true) { + process.env["ACTIONS_ID_TOKEN_REQUEST_URL"] = void 0; + process.env["ACTIONS_ID_TOKEN_REQUEST_TOKEN"] = void 0; + } + this.features = {}; + this.featureEventMetadata = {}; + this.events = []; + this.getCrossPhaseId(); + this.collectBacktraceSetup(); + this.facts = { + $lib: "idslib", + $lib_version: pkgVersion, + project: this.actionOptions.name, + ids_project: this.actionOptions.idsProjectName + }; + const params = [ + ["github_action_ref", "GITHUB_ACTION_REF"], + ["github_action_repository", "GITHUB_ACTION_REPOSITORY"], + ["github_event_name", "GITHUB_EVENT_NAME"], + ["$os", "RUNNER_OS"], + ["arch", "RUNNER_ARCH"] + ]; + for (const [target, env] of params) { + const value = process.env[env]; + if (value) { + this.facts[target] = value; + } + } + this.identity = identify(); + this.archOs = getArchOs(); + this.nixSystem = getNixPlatform(this.archOs); + this.facts.$app_name = `${this.actionOptions.name}/action`; + this.facts.arch_os = this.archOs; + this.facts.nix_system = this.nixSystem; + { + getDetails().then((details) => { + if (details.name !== "unknown") { + this.addFact(FACT_OS, details.name); + } + if (details.version !== "unknown") { + this.addFact(FACT_OS_VERSION, details.version); + } + }).catch((e) => { + core.debug( + `Failure getting platform details: ${stringifyError2(e)}` + ); + }); + } + this.executionPhase = this.determineExecutionPhase(); + this.facts.execution_phase = this.executionPhase; + if (this.actionOptions.fetchStyle === "gh-env-style") { + this.architectureFetchSuffix = this.archOs; + } else if (this.actionOptions.fetchStyle === "nix-style") { + this.architectureFetchSuffix = this.nixSystem; + } else if (this.actionOptions.fetchStyle === "universal") { + this.architectureFetchSuffix = "universal"; + } else { + throw new Error( + `fetchStyle ${this.actionOptions.fetchStyle} is not a valid style` + ); + } + this.sourceParameters = constructSourceParameters( + this.actionOptions.legacySourcePrefix + ); + this.recordEvent(`begin_${this.executionPhase}`); + } + /** + * Attach a file to the diagnostics data in error conditions. + * + * The file at `location` doesn't need to exist when stapleFile is called. + * + * If the file doesn't exist or is unreadable when trying to staple the attachments, the JS error will be stored in a context value at `staple_failure_{name}`. + * If the file is readable, the file's contents will be stored in a context value at `staple_value_{name}`. + */ + stapleFile(name, location) { + this.exceptionAttachments.set(name, location); + } + /** + * Execute the Action as defined. + */ + execute() { + this.executeAsync().catch((error3) => { + console.log(error3); + process.exitCode = 1; + }); + } + getTemporaryName() { + const tmpDir = process.env["RUNNER_TEMP"] || (0,external_os_.tmpdir)(); + return external_path_.join(tmpDir, `${this.actionOptions.name}-${(0,external_crypto_.randomUUID)()}`); + } + addFact(key, value) { + this.facts[key] = value; + } + async getDiagnosticsUrl() { + return await this.idsHost.getDiagnosticsUrl(); + } + getUniqueId() { + return this.identity.github_workflow_run_differentiator_hash || process.env.RUNNER_TRACKING_ID || (0,external_crypto_.randomUUID)(); + } + // This ID will be saved in the action's state, to be persisted across phase steps + getCrossPhaseId() { + let crossPhaseId = core.getState(STATE_KEY_CROSS_PHASE_ID); + if (crossPhaseId === "") { + crossPhaseId = (0,external_crypto_.randomUUID)(); + core.saveState(STATE_KEY_CROSS_PHASE_ID, crossPhaseId); + } + return crossPhaseId; + } + getCorrelationHashes() { + return this.identity; + } + recordEvent(eventName, context = {}) { + const prefixedName = eventName === "$feature_flag_called" ? eventName : `${this.actionOptions.eventPrefix}${eventName}`; + this.events.push({ + name: prefixedName, + // Use the anon distinct ID as the distinct ID until we actually have a distinct ID in the future + distinct_id: this.identity.$anon_distinct_id, + // distinct_id + uuid: (0,external_crypto_.randomUUID)(), + timestamp: /* @__PURE__ */ new Date(), + properties: { + ...context, + ...this.identity, + ...this.facts, + ...Object.fromEntries( + Object.entries(this.featureEventMetadata).map(([name, variant]) => [`$feature/${name}`, variant]) + ) + } + }); + } + /** + * Unpacks the closure returned by `fetchArtifact()`, imports the + * contents into the Nix store, and returns the path of the executable at + * `/nix/store/STORE_PATH/bin/${bin}`. + */ + async unpackClosure(bin) { + const artifact = await this.fetchArtifact(); + const { stdout } = await (0,external_util_.promisify)(external_child_process_.exec)( + `cat "${artifact}" | xz -d | nix-store --import` + ); + const paths = stdout.split(external_os_.EOL); + const lastPath = paths.at(-2); + return `${lastPath}/bin/${bin}`; + } + /** + * Fetches the executable at the URL determined by the `source-*` inputs and + * other facts, `chmod`s it, and returns the path to the executable on disk. + */ + async fetchExecutable() { + const binaryPath = await this.fetchArtifact(); + await (0,promises_namespaceObject.chmod)(binaryPath, promises_namespaceObject.constants.S_IXUSR | promises_namespaceObject.constants.S_IXGRP); + return binaryPath; + } + get isMain() { + return this.executionPhase === "main"; + } + get isPost() { + return this.executionPhase === "post"; + } + async executeAsync() { + try { + await this.checkIn(); + const correlationHashes = JSON.stringify(this.getCorrelationHashes()); + process.env.DETSYS_CORRELATION = correlationHashes; + try { + await writeCorrelationHashes(correlationHashes); + } catch (error3) { + this.recordEvent(EVENT_STORE_IDENTITY_FAILED, { error: String(error3) }); + } + if (!await this.preflightRequireNix()) { + this.recordEvent(EVENT_PREFLIGHT_REQUIRE_NIX_DENIED); + return; + } else { + await this.preflightNixStoreInfo(); + this.addFact(FACT_NIX_STORE_TRUST, this.nixStoreTrust); + } + if (this.isMain) { + await this.main(); + } else if (this.isPost) { + await this.post(); + } + this.addFact(FACT_ENDED_WITH_EXCEPTION, false); + } catch (e) { + this.addFact(FACT_ENDED_WITH_EXCEPTION, true); + const reportable = stringifyError2(e); + this.addFact(FACT_FINAL_EXCEPTION, reportable); + if (this.isPost) { + core.warning(reportable); + } else { + core.setFailed(reportable); + } + const doGzip = (0,external_util_.promisify)(external_zlib_.gzip); + const exceptionContext = /* @__PURE__ */ new Map(); + for (const [attachmentLabel, filePath] of this.exceptionAttachments) { + try { + const logText = (0,external_fs_.readFileSync)(filePath); + const buf = await doGzip(logText); + exceptionContext.set( + `staple_value_${attachmentLabel}`, + buf.toString("base64") + ); + } catch (innerError) { + exceptionContext.set( + `staple_failure_${attachmentLabel}`, + stringifyError2(innerError) + ); + } + } + this.recordEvent(EVENT_EXCEPTION, Object.fromEntries(exceptionContext)); + } finally { + if (this.isPost) { + await this.collectBacktraces(); + } + await this.complete(); + } + } + async getClient() { + return await this.idsHost.getGot( + (incitingError, prevUrl, nextUrl) => { + this.recordPlausibleTimeout(incitingError); + this.recordEvent("ids-failover", { + previousUrl: prevUrl.toString(), + nextUrl: nextUrl.toString() + }); + } + ); + } + async checkIn() { + const checkin = await this.requestCheckIn(); + if (checkin === void 0) { + return; + } + this.features = checkin.options; + for (const [key, feature] of Object.entries(this.features)) { + this.featureEventMetadata[key] = feature.variant; + } + const impactSymbol = /* @__PURE__ */ new Map([ + ["none", "\u26AA"], + ["maintenance", "\u{1F6E0}\uFE0F"], + ["minor", "\u{1F7E1}"], + ["major", "\u{1F7E0}"], + ["critical", "\u{1F534}"] + ]); + const defaultImpactSymbol = "\u{1F535}"; + if (checkin.status !== null) { + const summaries = []; + for (const incident of checkin.status.incidents) { + summaries.push( + `${impactSymbol.get(incident.impact) || defaultImpactSymbol} ${incident.status.replace("_", " ")}: ${incident.name} (${incident.shortlink})` + ); + } + for (const maintenance of checkin.status.scheduled_maintenances) { + summaries.push( + `${impactSymbol.get(maintenance.impact) || defaultImpactSymbol} ${maintenance.status.replace("_", " ")}: ${maintenance.name} (${maintenance.shortlink})` + ); + } + if (summaries.length > 0) { + core.info( + // Bright red, Bold, Underline + `${"\x1B[0;31m"}${"\x1B[1m"}${"\x1B[4m"}${checkin.status.page.name} Status` + ); + for (const notice of summaries) { + core.info(notice); + } + core.info(`See: ${checkin.status.page.url}`); + core.info(``); + } + } + } + getFeature(name) { + if (!this.features.hasOwnProperty(name)) { + return void 0; + } + const result = this.features[name]; + if (result === void 0) { + return void 0; + } + this.recordEvent("$feature_flag_called", { + $feature_flag: name, + $feature_flag_response: result.variant + }); + return result; + } + /** + * Check in to install.determinate.systems, to accomplish three things: + * + * 1. Preflight the server selected from IdsHost, to increase the chances of success. + * 2. Fetch any incidents and maintenance events to let users know in case things are weird. + * 3. Get feature flag data so we can gently roll out new features. + */ + async requestCheckIn() { + for (let attemptsRemaining = 5; attemptsRemaining > 0; attemptsRemaining--) { + const checkInUrl = await this.getCheckInUrl(); + if (checkInUrl === void 0) { + return void 0; + } + try { + core.debug(`Preflighting via ${checkInUrl}`); + const props = { + // Use a distinct_id when we actually have one + distinct_id: this.identity.$anon_distinct_id, + anon_distinct_id: this.identity.$anon_distinct_id, + groups: this.identity.$groups, + person_properties: { + ci: "github", + ...this.identity, + ...this.facts + } + }; + return await (await this.getClient()).post(checkInUrl, { + json: props, + timeout: { + request: CHECK_IN_ENDPOINT_TIMEOUT_MS + } + }).json(); + } catch (e) { + this.recordPlausibleTimeout(e); + core.debug(`Error checking in: ${stringifyError2(e)}`); + this.idsHost.markCurrentHostBroken(); + } + } + return void 0; + } + recordPlausibleTimeout(e) { + if (e instanceof TimeoutError && "timings" in e && "request" in e) { + const reportContext = { + url: e.request.requestUrl?.toString(), + retry_count: e.request.retryCount + }; + for (const [key, value] of Object.entries(e.timings.phases)) { + if (Number.isFinite(value)) { + reportContext[`timing_phase_${key}`] = value; + } + } + this.recordEvent("timeout", reportContext); + } + } + /** + * Fetch an artifact, such as a tarball, from the location determined by the + * `source-*` inputs. If `source-binary` is specified, this will return a path + * to a binary on disk; otherwise, the artifact will be downloaded from the + * URL determined by the other `source-*` inputs (`source-url`, `source-pr`, + * etc.). + */ + async fetchArtifact() { + const sourceBinary = getStringOrNull("source-binary"); + if (sourceBinary !== null && sourceBinary !== "") { + core.debug(`Using the provided source binary at ${sourceBinary}`); + return sourceBinary; + } + core.startGroup( + `Downloading ${this.actionOptions.name} for ${this.architectureFetchSuffix}` + ); + try { + core.info(`Fetching from ${await this.getSourceUrl()}`); + const correlatedUrl = await this.getSourceUrl(); + correlatedUrl.searchParams.set("ci", "github"); + correlatedUrl.searchParams.set( + "correlation", + JSON.stringify(this.identity) + ); + const versionCheckup = await (await this.getClient()).head(correlatedUrl); + if (versionCheckup.headers.etag) { + const v = versionCheckup.headers.etag; + this.addFact(FACT_SOURCE_URL_ETAG, v); + core.debug( + `Checking the tool cache for ${await this.getSourceUrl()} at ${v}` + ); + const cached = await this.getCachedVersion(v); + if (cached) { + this.facts[FACT_ARTIFACT_FETCHED_FROM_CACHE] = true; + core.debug(`Tool cache hit.`); + return cached; + } + } + this.facts[FACT_ARTIFACT_FETCHED_FROM_CACHE] = false; + core.debug( + `No match from the cache, re-fetching from the redirect: ${versionCheckup.url}` + ); + const destFile = this.getTemporaryName(); + const fetchStream = await this.downloadFile( + new URL(versionCheckup.url), + destFile + ); + if (fetchStream.response?.headers.etag) { + const v = fetchStream.response.headers.etag; + try { + await this.saveCachedVersion(v, destFile); + } catch (e) { + core.debug(`Error caching the artifact: ${stringifyError2(e)}`); + } + } + return destFile; + } catch (e) { + this.recordPlausibleTimeout(e); + throw e; + } finally { + core.endGroup(); + } + } + /** + * A helper function for failing on error only if strict mode is enabled. + * This is intended only for CI environments testing Actions themselves. + */ + failOnError(msg) { + if (this.strictMode) { + core.setFailed(`strict mode failure: ${msg}`); + } + } + async downloadFile(url, destination) { + const client = await this.getClient(); + return new Promise((resolve, reject) => { + let writeStream; + let failed = false; + const retry = (stream) => { + if (writeStream) { + writeStream.destroy(); + } + writeStream = (0,external_fs_.createWriteStream)(destination, { + encoding: "binary", + mode: 493 + }); + writeStream.once("error", (error3) => { + failed = true; + reject(error3); + }); + writeStream.on("finish", () => { + if (!failed) { + resolve(stream); + } + }); + stream.once("retry", (_count, _error, createRetryStream) => { + retry(createRetryStream()); + }); + stream.pipe(writeStream); + }; + retry(client.stream(url)); + }); + } + async complete() { + this.recordEvent(`complete_${this.executionPhase}`); + await this.submitEvents(); + } + async getCheckInUrl() { + const checkInUrl = await this.idsHost.getDynamicRootUrl(); + if (checkInUrl === void 0) { + return void 0; + } + checkInUrl.pathname += "check-in"; + return checkInUrl; + } + async getSourceUrl() { + const p = this.sourceParameters; + if (p.url) { + this.addFact(FACT_SOURCE_URL, p.url); + return new URL(p.url); + } + const fetchUrl = await this.idsHost.getRootUrl(); + fetchUrl.pathname += this.actionOptions.idsProjectName; + if (p.tag) { + fetchUrl.pathname += `/tag/${p.tag}`; + } else if (p.pr) { + fetchUrl.pathname += `/pr/${p.pr}`; + } else if (p.branch) { + fetchUrl.pathname += `/branch/${p.branch}`; + } else if (p.revision) { + fetchUrl.pathname += `/rev/${p.revision}`; + } else { + fetchUrl.pathname += `/stable`; + } + fetchUrl.pathname += `/${this.architectureFetchSuffix}`; + this.addFact(FACT_SOURCE_URL, fetchUrl.toString()); + return fetchUrl; + } + cacheKey(version) { + const cleanedVersion = version.replace(/[^a-zA-Z0-9-+.]/g, ""); + return `determinatesystem-${this.actionOptions.name}-${this.architectureFetchSuffix}-${cleanedVersion}`; + } + async getCachedVersion(version) { + const startCwd = process.cwd(); + try { + const tempDir = this.getTemporaryName(); + await (0,promises_namespaceObject.mkdir)(tempDir); + process.chdir(tempDir); + process.env.GITHUB_WORKSPACE_BACKUP = process.env.GITHUB_WORKSPACE; + delete process.env.GITHUB_WORKSPACE; + if (await cache.restoreCache( + [this.actionOptions.name], + this.cacheKey(version), + [], + void 0, + true + )) { + this.recordEvent(EVENT_ARTIFACT_CACHE_HIT); + return `${tempDir}/${this.actionOptions.name}`; + } + this.recordEvent(EVENT_ARTIFACT_CACHE_MISS); + return void 0; + } finally { + process.env.GITHUB_WORKSPACE = process.env.GITHUB_WORKSPACE_BACKUP; + delete process.env.GITHUB_WORKSPACE_BACKUP; + process.chdir(startCwd); + } + } + async saveCachedVersion(version, toolPath) { + const startCwd = process.cwd(); + try { + const tempDir = this.getTemporaryName(); + await (0,promises_namespaceObject.mkdir)(tempDir); + process.chdir(tempDir); + await (0,promises_namespaceObject.copyFile)(toolPath, `${tempDir}/${this.actionOptions.name}`); + process.env.GITHUB_WORKSPACE_BACKUP = process.env.GITHUB_WORKSPACE; + delete process.env.GITHUB_WORKSPACE; + await cache.saveCache( + [this.actionOptions.name], + this.cacheKey(version), + void 0, + true + ); + this.recordEvent(EVENT_ARTIFACT_CACHE_PERSIST); + } finally { + process.env.GITHUB_WORKSPACE = process.env.GITHUB_WORKSPACE_BACKUP; + delete process.env.GITHUB_WORKSPACE_BACKUP; + process.chdir(startCwd); + } + } + collectBacktraceSetup() { + if (!process.env.DETSYS_BACKTRACE_COLLECTOR) { + core.exportVariable( + "DETSYS_BACKTRACE_COLLECTOR", + this.getCrossPhaseId() + ); + core.saveState(STATE_BACKTRACE_START_TIMESTAMP, Date.now()); + } + } + async collectBacktraces() { + try { + if (process.env.DETSYS_BACKTRACE_COLLECTOR !== this.getCrossPhaseId()) { + return; + } + const backtraces = await collectBacktraces( + this.actionOptions.binaryNamePrefixes, + this.actionOptions.binaryNamesDenyList, + parseInt(core.getState(STATE_BACKTRACE_START_TIMESTAMP)) + ); + core.debug(`Backtraces identified: ${backtraces.size}`); + if (backtraces.size > 0) { + this.recordEvent(EVENT_BACKTRACES, Object.fromEntries(backtraces)); + } + } catch (innerError) { + core.debug( + `Error collecting backtraces: ${stringifyError2(innerError)}` + ); + } + } + async preflightRequireNix() { + let nixLocation; + const pathParts = (process.env["PATH"] || "").split(":"); + for (const location of pathParts) { + const candidateNix = external_path_.join(location, "nix"); + try { + await promises_namespaceObject.access(candidateNix, promises_namespaceObject.constants.X_OK); + core.debug(`Found Nix at ${candidateNix}`); + nixLocation = candidateNix; + break; + } catch { + core.debug(`Nix not at ${candidateNix}`); + } + } + this.addFact(FACT_NIX_LOCATION, nixLocation || ""); + if (this.actionOptions.requireNix === "ignore") { + return true; + } + const currentNotFoundState = core.getState(STATE_KEY_NIX_NOT_FOUND); + if (currentNotFoundState === STATE_NOT_FOUND) { + return false; + } + if (nixLocation !== void 0) { + return true; + } + core.saveState(STATE_KEY_NIX_NOT_FOUND, STATE_NOT_FOUND); + switch (this.actionOptions.requireNix) { + case "fail": + core.setFailed( + [ + "This action can only be used when Nix is installed.", + "Add `- uses: DeterminateSystems/determinate-nix-action@v3` earlier in your workflow." + ].join(" ") + ); + break; + case "warn": + core.warning( + [ + "This action is in no-op mode because Nix is not installed.", + "Add `- uses: DeterminateSystems/determinate-nix-action@v3` earlier in your workflow." + ].join(" ") + ); + break; + } + return false; + } + async preflightNixStoreInfo() { + let output = ""; + const options = {}; + options.silent = true; + options.listeners = { + stdout: (data) => { + output += data.toString(); + } + }; + try { + output = ""; + await exec.exec("nix", ["store", "info", "--json"], options); + this.addFact(FACT_NIX_STORE_CHECK_METHOD, "info"); + } catch { + try { + output = ""; + await exec.exec("nix", ["store", "ping", "--json"], options); + this.addFact(FACT_NIX_STORE_CHECK_METHOD, "ping"); + } catch { + this.addFact(FACT_NIX_STORE_CHECK_METHOD, "none"); + return; + } + } + try { + const parsed = JSON.parse(output); + if (parsed.trusted === 1) { + this.nixStoreTrust = "trusted"; + } else if (parsed.trusted === 0) { + this.nixStoreTrust = "untrusted"; + } else if (parsed.trusted !== void 0) { + this.addFact( + FACT_NIX_STORE_CHECK_ERROR, + `Mysterious trusted value: ${JSON.stringify(parsed.trusted)}` + ); + } + this.addFact(FACT_NIX_STORE_VERSION, JSON.stringify(parsed.version)); + } catch (e) { + this.addFact(FACT_NIX_STORE_CHECK_ERROR, stringifyError2(e)); + } + } + async submitEvents() { + const diagnosticsUrl = await this.idsHost.getDiagnosticsUrl(); + if (diagnosticsUrl === void 0) { + core.debug( + "Diagnostics are disabled. Not sending the following events:" + ); + core.debug(JSON.stringify(this.events, void 0, 2)); + return; + } + const batch = { + sent_at: /* @__PURE__ */ new Date(), + batch: this.events + }; + try { + await (await this.getClient()).post(diagnosticsUrl, { + json: batch, + timeout: { + request: DIAGNOSTIC_ENDPOINT_TIMEOUT_MS + } + }); + } catch (err) { + this.recordPlausibleTimeout(err); + core.debug( + `Error submitting diagnostics event to ${diagnosticsUrl}: ${stringifyError2(err)}` + ); + } + this.events = []; + } }; -function stringifyError$1(error) { - return error instanceof Error || typeof error == "string" ? error.toString() : JSON.stringify(error); +function stringifyError2(error3) { + return error3 instanceof Error || typeof error3 == "string" ? error3.toString() : JSON.stringify(error3); } function makeOptionsConfident(actionOptions) { - const idsProjectName = actionOptions.idsProjectName ?? actionOptions.name; - const finalOpts = { - name: actionOptions.name, - idsProjectName, - eventPrefix: actionOptions.eventPrefix || "action:", - fetchStyle: actionOptions.fetchStyle, - legacySourcePrefix: actionOptions.legacySourcePrefix, - requireNix: actionOptions.requireNix, - binaryNamePrefixes: actionOptions.binaryNamePrefixes ?? [ - "nix", - "determinate-nixd", - actionOptions.name - ], - binaryNamesDenyList: actionOptions.binaryNamePrefixes ?? PROGRAM_NAME_CRASH_DENY_LIST - }; - core.debug("idslib options:"); - core.debug(JSON.stringify(finalOpts, void 0, 2)); - return finalOpts; + const idsProjectName = actionOptions.idsProjectName ?? actionOptions.name; + const finalOpts = { + name: actionOptions.name, + idsProjectName, + eventPrefix: actionOptions.eventPrefix || "action:", + fetchStyle: actionOptions.fetchStyle, + legacySourcePrefix: actionOptions.legacySourcePrefix, + requireNix: actionOptions.requireNix, + binaryNamePrefixes: actionOptions.binaryNamePrefixes ?? [ + "nix", + "determinate-nixd", + actionOptions.name + ], + binaryNamesDenyList: actionOptions.binaryNamePrefixes ?? PROGRAM_NAME_CRASH_DENY_LIST + }; + core.debug("idslib options:"); + core.debug(JSON.stringify(finalOpts, void 0, 2)); + return finalOpts; } -//#endregion - +/*! + * linux-release-info + * Get Linux release info (distribution name, version, arch, release, etc.) + * from '/etc/os-release' or '/usr/lib/os-release' files and from native os + * module. On Windows and Darwin platforms it only returns common node os module + * info (platform, hostname, release, and arch) + * + * Licensed under MIT + * Copyright (c) 2018-2020 [Samuel Carreira] + */ //# sourceMappingURL=index.js.map ;// CONCATENATED MODULE: ./dist/index.js // src/nix.ts diff --git a/flake.lock b/flake.lock index 0f8165b..9b6e32e 100644 --- a/flake.lock +++ b/flake.lock @@ -2,12 +2,12 @@ "nodes": { "nixpkgs": { "locked": { - "lastModified": 1757487488, - "narHash": "sha256-zwE/e7CuPJUWKdvvTCB7iunV4E/+G0lKfv4kk/5Izdg=", - "rev": "ab0f3607a6c7486ea22229b92ed2d355f1482ee0", - "revCount": 859555, + "lastModified": 1761373498, + "narHash": "sha256-Q/uhWNvd7V7k1H1ZPMy/vkx3F8C13ZcdrKjO7Jv7v0c=", + "rev": "6a08e6bb4e46ff7fcbb53d409b253f6bad8a28ce", + "revCount": 883951, "type": "tarball", - "url": "https://api.flakehub.com/f/pinned/NixOS/nixpkgs/0.1.859555%2Brev-ab0f3607a6c7486ea22229b92ed2d355f1482ee0/01993860-4c2b-73a3-9c67-955d87cd3025/source.tar.gz" + "url": "https://api.flakehub.com/f/pinned/NixOS/nixpkgs/0.1.883951%2Brev-6a08e6bb4e46ff7fcbb53d409b253f6bad8a28ce/019a1fdc-d873-7c43-b344-e10191e3d592/source.tar.gz" }, "original": { "type": "tarball", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index a03fa5f..74022b9 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -16,7 +16,7 @@ importers: version: 1.1.1 detsys-ts: specifier: github:DeterminateSystems/detsys-ts - version: https://codeload.github.com/DeterminateSystems/detsys-ts/tar.gz/285768c0d657f9709cb689893f12895c36923093 + version: https://codeload.github.com/DeterminateSystems/detsys-ts/tar.gz/e439a01995ac029e7481a75c4661a7f60eeb8b19 devDependencies: '@trivago/prettier-plugin-sort-imports': specifier: ^4.3.0 @@ -83,17 +83,17 @@ packages: resolution: {integrity: sha512-nBrLsEWm4J2u5LpAPjxADTlq3trDgVZZXHNKabeXZtpq3d3AbN/KGO82R87rdDz5/lYB024rtEf10/q0urNgsA==} engines: {node: '>=18.0.0'} - '@azure/core-auth@1.10.1': - resolution: {integrity: sha512-ykRMW8PjVAn+RS6ww5cmK9U2CyH9p4Q88YJwvUslfuMmN98w/2rdGRLPqJYObapBCdzBVeDgYWdJnFPFb7qzpg==} + '@azure/core-auth@1.10.0': + resolution: {integrity: sha512-88Djs5vBvGbHQHf5ZZcaoNHo6Y8BKZkt3cw2iuJIQzLEgH4Ox6Tm4hjFhbqOxyYsgIG/eJbFEHpxRIfEEWv5Ow==} engines: {node: '>=20.0.0'} - '@azure/core-client@1.10.1': - resolution: {integrity: sha512-Nh5PhEOeY6PrnxNPsEHRr9eimxLwgLlpmguQaHKBinFYA/RU9+kOYVOQqOrTsCL+KSxrLLl1gD8Dk5BFW/7l/w==} + '@azure/core-client@1.10.0': + resolution: {integrity: sha512-O4aP3CLFNodg8eTHXECaH3B3CjicfzkxVtnrfLkOq0XNP7TIECGfHpK/C6vADZkWP75wzmdBnsIA8ksuJMk18g==} engines: {node: '>=20.0.0'} - '@azure/core-http-compat@2.3.1': - resolution: {integrity: sha512-az9BkXND3/d5VgdRRQVkiJb2gOmDU8Qcq4GvjtBmDICNiQ9udFmDk4ZpSB5Qq1OmtDJGlQAfBaS4palFsazQ5g==} - engines: {node: '>=20.0.0'} + '@azure/core-http-compat@2.3.0': + resolution: {integrity: sha512-qLQujmUypBBG0gxHd0j6/Jdmul6ttl24c8WGiLXIk7IHXdBlfoBqW27hyz3Xn6xbfdyVSarl1Ttbk0AwnZBYCw==} + engines: {node: '>=18.0.0'} '@azure/core-lro@2.7.2': resolution: {integrity: sha512-0YIpccoX8m/k00O7mDDMdJpbr6mf1yWo2dfmxt5A8XVZVVMz2SSKaEbMCeJRvgQ0IaSlqhjT47p4hVIRRy90xw==} @@ -103,16 +103,16 @@ packages: resolution: {integrity: sha512-YKWi9YuCU04B55h25cnOYZHxXYtEvQEbKST5vqRga7hWY9ydd3FZHdeQF8pyh+acWZvppw13M/LMGx0LABUVMA==} engines: {node: '>=18.0.0'} - '@azure/core-rest-pipeline@1.22.1': - resolution: {integrity: sha512-UVZlVLfLyz6g3Hy7GNDpooMQonUygH7ghdiSASOOHy97fKj/mPLqgDX7aidOijn+sCMU+WU8NjlPlNTgnvbcGA==} + '@azure/core-rest-pipeline@1.22.0': + resolution: {integrity: sha512-OKHmb3/Kpm06HypvB3g6Q3zJuvyXcpxDpCS1PnU8OV6AJgSFaee/covXBcPbWc6XDDxtEPlbi3EMQ6nUiPaQtw==} engines: {node: '>=20.0.0'} - '@azure/core-tracing@1.3.1': - resolution: {integrity: sha512-9MWKevR7Hz8kNzzPLfX4EAtGM2b8mr50HPDBvio96bURP/9C+HjdH3sBlLSNNrvRAr5/k/svoH457gB5IKpmwQ==} + '@azure/core-tracing@1.3.0': + resolution: {integrity: sha512-+XvmZLLWPe67WXNZo9Oc9CrPj/Tm8QnHR92fFAFdnbzwNdCH1h+7UdpaQgRSBsMY+oW1kHXNUZQLdZ1gHX3ROw==} engines: {node: '>=20.0.0'} - '@azure/core-util@1.13.1': - resolution: {integrity: sha512-XPArKLzsvl0Hf0CaGyKHUyVgF7oDnhKoP85Xv6M4StF/1AhfORhZudHtOyf2s+FcbuQ9dPRAjB8J2KvRRMUK2A==} + '@azure/core-util@1.13.0': + resolution: {integrity: sha512-o0psW8QWQ58fq3i24Q1K2XfS/jYTxr7O1HRcyUE9bV9NttLU+kYOH82Ixj8DGlMTOWgxm1Sss2QAfKK5UkSPxw==} engines: {node: '>=20.0.0'} '@azure/core-xml@1.5.0': @@ -170,8 +170,8 @@ packages: resolution: {integrity: sha512-D2hP9eA+Sqx1kBZgzxZh0y1trbuU+JoDkiEwqhQ36nodYqJwyEIhPSdMNd7lOm/4io72luTPWH20Yda0xOuUow==} engines: {node: '>=6.9.0'} - '@babel/parser@7.28.4': - resolution: {integrity: sha512-yZbBqeM6TkpP9du/I2pUZnJsRMGGvOuIrhjzC1AwHwW+6he4mni6Bp/m8ijn0iOuZuPI2BfkCoSRunpyjnrQKg==} + '@babel/parser@7.28.3': + resolution: {integrity: sha512-7+Ey1mAgYqFAx2h0RuoxcQT5+MlG3GTV0TQrgr7/ZliKsm/MNDxVVutlWaziMq7wJNAz8MTqz55XLpWvva6StA==} engines: {node: '>=6.0.0'} hasBin: true @@ -187,18 +187,18 @@ packages: resolution: {integrity: sha512-TmKSNO4D5rzhL5bjWFcVHHLETzfQ/AmbKpKPOSjlP0WoHZ6L911fgoOKY4Alp/emzG4cHJdyN49zpgkbXFEHHw==} engines: {node: '>=6.9.0'} - '@babel/types@7.28.4': - resolution: {integrity: sha512-bkFqkLhh3pMBUQQkpVgWDWq/lqzc2678eUyDlTBhRqhCHFguYYGM0Efga7tYk4TogG/3x0EEl66/OQ+WGbWB/Q==} + '@babel/types@7.28.2': + resolution: {integrity: sha512-ruv7Ae4J5dUYULmeXw1gmb7rYRz57OWCPM57pHojnLq/3Z1CK2lNSLTCVjxVk1F/TZHwOZZrOWi0ur95BbLxNQ==} engines: {node: '>=6.9.0'} - '@emnapi/core@1.5.0': - resolution: {integrity: sha512-sbP8GzB1WDzacS8fgNPpHlp6C9VZe+SJP3F90W9rLemaQj2PzIuTEl1qDOYQf58YIpyjViI24y9aPWCjEzY2cg==} + '@emnapi/core@1.4.5': + resolution: {integrity: sha512-XsLw1dEOpkSX/WucdqUhPWP7hDxSvZiY+fsUC14h+FtQ2Ifni4znbBt8punRX+Uj2JG/uDb8nEHVKvrVlvdZ5Q==} - '@emnapi/runtime@1.5.0': - resolution: {integrity: sha512-97/BJ3iXHww3djw6hYIfErCZFee7qCtrneuLa20UXFCOTCfBM2cvQHjWJ2EG0s0MtdNwInarqCTz35i4wWXHsQ==} + '@emnapi/runtime@1.4.5': + resolution: {integrity: sha512-++LApOtY0pEEz1zrd9vy1/zXVaVJJ/EbAF3u0fXIzPJEDtnITsBGbbK0EkM72amhl/R5b+5xx0Y/QhcVOpuulg==} - '@emnapi/wasi-threads@1.1.0': - resolution: {integrity: sha512-WI0DdZ8xFSbgMjR1sFsKABJ/C5OnRrjT06JXbZKexJGrDuPTzZdDYfFlsgcCXCyf+suG5QU2e/y1Wo2V/OapLQ==} + '@emnapi/wasi-threads@1.0.4': + resolution: {integrity: sha512-PJR+bOmMOPH8AtcTGAyYNiuJ3/Fcoj2XN/gBEWzDIKh254XO+mM9XoXHk5GNEhodxeMznbg7BlRojVbKN+gC6g==} '@esbuild/aix-ppc64@0.25.9': resolution: {integrity: sha512-OaGtL73Jck6pBKjNIe24BnFE6agGl+6KxDtTfHhy1HmhthfKouEcOhqpSL64K4/0WCtbKFLOdzD/44cJ4k9opA==} @@ -356,8 +356,8 @@ packages: cpu: [x64] os: [win32] - '@eslint-community/eslint-utils@4.9.0': - resolution: {integrity: sha512-ayVFHdtZ+hsq1t2Dy24wCmGXGe4q9Gu3smhLYALJrr473ZH27MsnSL+LKUlimp4BWJqMDMLmPpx/Q9R3OAlL4g==} + '@eslint-community/eslint-utils@4.7.0': + resolution: {integrity: sha512-dyybb3AcajC7uha6CvhdVRJqaKyn7w2YKqKyAN37NKYgZT36w+iRb0Dymmc5qEJ549c/S31cMMSFd75bteCpCw==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} peerDependencies: eslint: ^6.0.0 || ^7.0.0 || >=8.0.0 @@ -408,8 +408,8 @@ packages: '@jridgewell/sourcemap-codec@1.5.5': resolution: {integrity: sha512-cYQ9310grqxueWbl+WuIUIaiUaDcj7WOq5fVhEljNVgRfOUhY9fy2zTvfoqWsnebh8Sl70VScFbICvJnLKB0Og==} - '@jridgewell/trace-mapping@0.3.31': - resolution: {integrity: sha512-zzNR+SdQSDJzc8joaeP8QQoCQr8NuYx2dIIytl1QeBEZHJ9uW6hebsrYgbz8hJwUQao3TWCMtmfV8Nu1twOLAw==} + '@jridgewell/trace-mapping@0.3.30': + resolution: {integrity: sha512-GQ7Nw5G2lTu/BtHTKfXhKHok2WGetd4XYcVKGx00SjAk8GMwgJM3zr6zORiPGuOE+/vkc90KtTosSSvaCjKb2Q==} '@napi-rs/wasm-runtime@0.2.12': resolution: {integrity: sha512-ZVWUcfwY4E/yPitQJl481FjFo3K22D6qF0DuFH6Y/nbnE11GY5uguDxZMGXPQ8WQ0128MXQD7TnfHyK4oWoIJQ==} @@ -444,108 +444,103 @@ packages: '@protobuf-ts/runtime@2.11.1': resolution: {integrity: sha512-KuDaT1IfHkugM2pyz+FwiY80ejWrkH1pAtOBOZFuR6SXEFTsnb/jiQWQ1rCIrcKx2BtyxnxW6BWwsVSA/Ie+WQ==} - '@rollup/rollup-android-arm-eabi@4.50.1': - resolution: {integrity: sha512-HJXwzoZN4eYTdD8bVV22DN8gsPCAj3V20NHKOs8ezfXanGpmVPR7kalUHd+Y31IJp9stdB87VKPFbsGY3H/2ag==} + '@rollup/rollup-android-arm-eabi@4.48.1': + resolution: {integrity: sha512-rGmb8qoG/zdmKoYELCBwu7vt+9HxZ7Koos3pD0+sH5fR3u3Wb/jGcpnqxcnWsPEKDUyzeLSqksN8LJtgXjqBYw==} cpu: [arm] os: [android] - '@rollup/rollup-android-arm64@4.50.1': - resolution: {integrity: sha512-PZlsJVcjHfcH53mOImyt3bc97Ep3FJDXRpk9sMdGX0qgLmY0EIWxCag6EigerGhLVuL8lDVYNnSo8qnTElO4xw==} + '@rollup/rollup-android-arm64@4.48.1': + resolution: {integrity: sha512-4e9WtTxrk3gu1DFE+imNJr4WsL13nWbD/Y6wQcyku5qadlKHY3OQ3LJ/INrrjngv2BJIHnIzbqMk1GTAC2P8yQ==} cpu: [arm64] os: [android] - '@rollup/rollup-darwin-arm64@4.50.1': - resolution: {integrity: sha512-xc6i2AuWh++oGi4ylOFPmzJOEeAa2lJeGUGb4MudOtgfyyjr4UPNK+eEWTPLvmPJIY/pgw6ssFIox23SyrkkJw==} + '@rollup/rollup-darwin-arm64@4.48.1': + resolution: {integrity: sha512-+XjmyChHfc4TSs6WUQGmVf7Hkg8ferMAE2aNYYWjiLzAS/T62uOsdfnqv+GHRjq7rKRnYh4mwWb4Hz7h/alp8A==} cpu: [arm64] os: [darwin] - '@rollup/rollup-darwin-x64@4.50.1': - resolution: {integrity: sha512-2ofU89lEpDYhdLAbRdeyz/kX3Y2lpYc6ShRnDjY35bZhd2ipuDMDi6ZTQ9NIag94K28nFMofdnKeHR7BT0CATw==} + '@rollup/rollup-darwin-x64@4.48.1': + resolution: {integrity: sha512-upGEY7Ftw8M6BAJyGwnwMw91rSqXTcOKZnnveKrVWsMTF8/k5mleKSuh7D4v4IV1pLxKAk3Tbs0Lo9qYmii5mQ==} cpu: [x64] os: [darwin] - '@rollup/rollup-freebsd-arm64@4.50.1': - resolution: {integrity: sha512-wOsE6H2u6PxsHY/BeFHA4VGQN3KUJFZp7QJBmDYI983fgxq5Th8FDkVuERb2l9vDMs1D5XhOrhBrnqcEY6l8ZA==} + '@rollup/rollup-freebsd-arm64@4.48.1': + resolution: {integrity: sha512-P9ViWakdoynYFUOZhqq97vBrhuvRLAbN/p2tAVJvhLb8SvN7rbBnJQcBu8e/rQts42pXGLVhfsAP0k9KXWa3nQ==} cpu: [arm64] os: [freebsd] - '@rollup/rollup-freebsd-x64@4.50.1': - resolution: {integrity: sha512-A/xeqaHTlKbQggxCqispFAcNjycpUEHP52mwMQZUNqDUJFFYtPHCXS1VAG29uMlDzIVr+i00tSFWFLivMcoIBQ==} + '@rollup/rollup-freebsd-x64@4.48.1': + resolution: {integrity: sha512-VLKIwIpnBya5/saccM8JshpbxfyJt0Dsli0PjXozHwbSVaHTvWXJH1bbCwPXxnMzU4zVEfgD1HpW3VQHomi2AQ==} cpu: [x64] os: [freebsd] - '@rollup/rollup-linux-arm-gnueabihf@4.50.1': - resolution: {integrity: sha512-54v4okehwl5TaSIkpp97rAHGp7t3ghinRd/vyC1iXqXMfjYUTm7TfYmCzXDoHUPTTf36L8pr0E7YsD3CfB3ZDg==} + '@rollup/rollup-linux-arm-gnueabihf@4.48.1': + resolution: {integrity: sha512-3zEuZsXfKaw8n/yF7t8N6NNdhyFw3s8xJTqjbTDXlipwrEHo4GtIKcMJr5Ed29leLpB9AugtAQpAHW0jvtKKaQ==} cpu: [arm] os: [linux] - '@rollup/rollup-linux-arm-musleabihf@4.50.1': - resolution: {integrity: sha512-p/LaFyajPN/0PUHjv8TNyxLiA7RwmDoVY3flXHPSzqrGcIp/c2FjwPPP5++u87DGHtw+5kSH5bCJz0mvXngYxw==} + '@rollup/rollup-linux-arm-musleabihf@4.48.1': + resolution: {integrity: sha512-leo9tOIlKrcBmmEypzunV/2w946JeLbTdDlwEZ7OnnsUyelZ72NMnT4B2vsikSgwQifjnJUbdXzuW4ToN1wV+Q==} cpu: [arm] os: [linux] - '@rollup/rollup-linux-arm64-gnu@4.50.1': - resolution: {integrity: sha512-2AbMhFFkTo6Ptna1zO7kAXXDLi7H9fGTbVaIq2AAYO7yzcAsuTNWPHhb2aTA6GPiP+JXh85Y8CiS54iZoj4opw==} + '@rollup/rollup-linux-arm64-gnu@4.48.1': + resolution: {integrity: sha512-Vy/WS4z4jEyvnJm+CnPfExIv5sSKqZrUr98h03hpAMbE2aI0aD2wvK6GiSe8Gx2wGp3eD81cYDpLLBqNb2ydwQ==} cpu: [arm64] os: [linux] - '@rollup/rollup-linux-arm64-musl@4.50.1': - resolution: {integrity: sha512-Cgef+5aZwuvesQNw9eX7g19FfKX5/pQRIyhoXLCiBOrWopjo7ycfB292TX9MDcDijiuIJlx1IzJz3IoCPfqs9w==} + '@rollup/rollup-linux-arm64-musl@4.48.1': + resolution: {integrity: sha512-x5Kzn7XTwIssU9UYqWDB9VpLpfHYuXw5c6bJr4Mzv9kIv242vmJHbI5PJJEnmBYitUIfoMCODDhR7KoZLot2VQ==} cpu: [arm64] os: [linux] - '@rollup/rollup-linux-loongarch64-gnu@4.50.1': - resolution: {integrity: sha512-RPhTwWMzpYYrHrJAS7CmpdtHNKtt2Ueo+BlLBjfZEhYBhK00OsEqM08/7f+eohiF6poe0YRDDd8nAvwtE/Y62Q==} + '@rollup/rollup-linux-loongarch64-gnu@4.48.1': + resolution: {integrity: sha512-yzCaBbwkkWt/EcgJOKDUdUpMHjhiZT/eDktOPWvSRpqrVE04p0Nd6EGV4/g7MARXXeOqstflqsKuXVM3H9wOIQ==} cpu: [loong64] os: [linux] - '@rollup/rollup-linux-ppc64-gnu@4.50.1': - resolution: {integrity: sha512-eSGMVQw9iekut62O7eBdbiccRguuDgiPMsw++BVUg+1K7WjZXHOg/YOT9SWMzPZA+w98G+Fa1VqJgHZOHHnY0Q==} + '@rollup/rollup-linux-ppc64-gnu@4.48.1': + resolution: {integrity: sha512-UK0WzWUjMAJccHIeOpPhPcKBqax7QFg47hwZTp6kiMhQHeOYJeaMwzeRZe1q5IiTKsaLnHu9s6toSYVUlZ2QtQ==} cpu: [ppc64] os: [linux] - '@rollup/rollup-linux-riscv64-gnu@4.50.1': - resolution: {integrity: sha512-S208ojx8a4ciIPrLgazF6AgdcNJzQE4+S9rsmOmDJkusvctii+ZvEuIC4v/xFqzbuP8yDjn73oBlNDgF6YGSXQ==} + '@rollup/rollup-linux-riscv64-gnu@4.48.1': + resolution: {integrity: sha512-3NADEIlt+aCdCbWVZ7D3tBjBX1lHpXxcvrLt/kdXTiBrOds8APTdtk2yRL2GgmnSVeX4YS1JIf0imFujg78vpw==} cpu: [riscv64] os: [linux] - '@rollup/rollup-linux-riscv64-musl@4.50.1': - resolution: {integrity: sha512-3Ag8Ls1ggqkGUvSZWYcdgFwriy2lWo+0QlYgEFra/5JGtAd6C5Hw59oojx1DeqcA2Wds2ayRgvJ4qxVTzCHgzg==} + '@rollup/rollup-linux-riscv64-musl@4.48.1': + resolution: {integrity: sha512-euuwm/QTXAMOcyiFCcrx0/S2jGvFlKJ2Iro8rsmYL53dlblp3LkUQVFzEidHhvIPPvcIsxDhl2wkBE+I6YVGzA==} cpu: [riscv64] os: [linux] - '@rollup/rollup-linux-s390x-gnu@4.50.1': - resolution: {integrity: sha512-t9YrKfaxCYe7l7ldFERE1BRg/4TATxIg+YieHQ966jwvo7ddHJxPj9cNFWLAzhkVsbBvNA4qTbPVNsZKBO4NSg==} + '@rollup/rollup-linux-s390x-gnu@4.48.1': + resolution: {integrity: sha512-w8mULUjmPdWLJgmTYJx/W6Qhln1a+yqvgwmGXcQl2vFBkWsKGUBRbtLRuKJUln8Uaimf07zgJNxOhHOvjSQmBQ==} cpu: [s390x] os: [linux] - '@rollup/rollup-linux-x64-gnu@4.50.1': - resolution: {integrity: sha512-MCgtFB2+SVNuQmmjHf+wfI4CMxy3Tk8XjA5Z//A0AKD7QXUYFMQcns91K6dEHBvZPCnhJSyDWLApk40Iq/H3tA==} + '@rollup/rollup-linux-x64-gnu@4.48.1': + resolution: {integrity: sha512-90taWXCWxTbClWuMZD0DKYohY1EovA+W5iytpE89oUPmT5O1HFdf8cuuVIylE6vCbrGdIGv85lVRzTcpTRZ+kA==} cpu: [x64] os: [linux] - '@rollup/rollup-linux-x64-musl@4.50.1': - resolution: {integrity: sha512-nEvqG+0jeRmqaUMuwzlfMKwcIVffy/9KGbAGyoa26iu6eSngAYQ512bMXuqqPrlTyfqdlB9FVINs93j534UJrg==} + '@rollup/rollup-linux-x64-musl@4.48.1': + resolution: {integrity: sha512-2Gu29SkFh1FfTRuN1GR1afMuND2GKzlORQUP3mNMJbqdndOg7gNsa81JnORctazHRokiDzQ5+MLE5XYmZW5VWg==} cpu: [x64] os: [linux] - '@rollup/rollup-openharmony-arm64@4.50.1': - resolution: {integrity: sha512-RDsLm+phmT3MJd9SNxA9MNuEAO/J2fhW8GXk62G/B4G7sLVumNFbRwDL6v5NrESb48k+QMqdGbHgEtfU0LCpbA==} - cpu: [arm64] - os: [openharmony] - - '@rollup/rollup-win32-arm64-msvc@4.50.1': - resolution: {integrity: sha512-hpZB/TImk2FlAFAIsoElM3tLzq57uxnGYwplg6WDyAxbYczSi8O2eQ+H2Lx74504rwKtZ3N2g4bCUkiamzS6TQ==} + '@rollup/rollup-win32-arm64-msvc@4.48.1': + resolution: {integrity: sha512-6kQFR1WuAO50bxkIlAVeIYsz3RUx+xymwhTo9j94dJ+kmHe9ly7muH23sdfWduD0BA8pD9/yhonUvAjxGh34jQ==} cpu: [arm64] os: [win32] - '@rollup/rollup-win32-ia32-msvc@4.50.1': - resolution: {integrity: sha512-SXjv8JlbzKM0fTJidX4eVsH+Wmnp0/WcD8gJxIZyR6Gay5Qcsmdbi9zVtnbkGPG8v2vMR1AD06lGWy5FLMcG7A==} + '@rollup/rollup-win32-ia32-msvc@4.48.1': + resolution: {integrity: sha512-RUyZZ/mga88lMI3RlXFs4WQ7n3VyU07sPXmMG7/C1NOi8qisUg57Y7LRarqoGoAiopmGmChUhSwfpvQ3H5iGSQ==} cpu: [ia32] os: [win32] - '@rollup/rollup-win32-x64-msvc@4.50.1': - resolution: {integrity: sha512-StxAO/8ts62KZVRAm4JZYq9+NqNsV7RvimNK+YM7ry//zebEH6meuugqW/P5OFUCjyQgui+9fUxT6d5NShvMvA==} + '@rollup/rollup-win32-x64-msvc@4.48.1': + resolution: {integrity: sha512-8a/caCUN4vkTChxkaIJcMtwIVcBhi4X2PQRoT+yCK3qRYaZ7cURrmJFL5Ux9H9RaMIXj9RuihckdmkBX3zZsgg==} cpu: [x64] os: [win32] @@ -572,8 +567,8 @@ packages: '@vue/compiler-sfc': optional: true - '@tybys/wasm-util@0.10.1': - resolution: {integrity: sha512-9tTaPJLSiejZKx+Bmog4uSubteqTvFrVrURwkmHixBo0G4seD0zUxp98E1DzUBJxLQ3NPwXrGKDiVjwx/DpPsg==} + '@tybys/wasm-util@0.10.0': + resolution: {integrity: sha512-VyyPYFlOMNylG45GoAe0xDoLwWuowvf92F9kySqzYh8vmYm7D2u4iUJKa1tOUpS70Ku13ASrOkS4ScXFsTaCNQ==} '@types/chai@5.2.2': resolution: {integrity: sha512-8kB30R7Hwqf40JPiKhVzodJs2Qc1ZJ5zuT3uzw5Hq/dhNCl3G3l83jfpdI1e20BP348+fV7VIL/+FxaXkqBmWg==} @@ -648,8 +643,8 @@ packages: resolution: {integrity: sha512-cDF0/Gf81QpY3xYyJKDV14Zwdmid5+uuENhjH2EqFaF0ni+yAyq/LzMaIJdhNJXZI7uLzwIlA+V7oWoyn6Curg==} engines: {node: ^18.18.0 || >=20.0.0} - '@typespec/ts-http-runtime@0.3.1': - resolution: {integrity: sha512-SnbaqayTVFEA6/tYumdF0UmybY0KHyKwGPBXnyckFlrrKdhWFrL3a2HIPXHjht5ZOElKGcXfD2D63P36btb+ww==} + '@typespec/ts-http-runtime@0.3.0': + resolution: {integrity: sha512-sOx1PKSuFwnIl7z4RN0Ls7N9AQawmR9r66eI5rFCzLDIs8HTIYrIpH9QjYWoX0lkgGrkLxXhi4QnK7MizPRrIg==} engines: {node: '>=20.0.0'} '@ungap/structured-clone@1.3.0': @@ -808,16 +803,16 @@ packages: resolution: {integrity: sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==} engines: {node: '>=8'} - ansi-regex@6.2.2: - resolution: {integrity: sha512-Bq3SmSpyFHaWjPk8If9yc6svM8c56dB5BAtW4Qbw5jHTwwXXcTLoRMkpDJp6VL0XzlWaCHTXrkFURMYmD0sLqg==} + ansi-regex@6.2.0: + resolution: {integrity: sha512-TKY5pyBkHyADOPYlRT9Lx6F544mPl0vS5Ew7BJ45hA08Q+t3GjbueLliBWN3sMICk6+y7HdyxSzC4bWS8baBdg==} engines: {node: '>=12'} ansi-styles@4.3.0: resolution: {integrity: sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==} engines: {node: '>=8'} - ansi-styles@6.2.3: - resolution: {integrity: sha512-4Dj6M28JB+oAH8kFkTLUo+a2jwOFkuqb3yucU0CANcRRUbxS0cP0nZYCGjcc3BNXwRIsUVmDGgzawme7zvJHvg==} + ansi-styles@6.2.1: + resolution: {integrity: sha512-bN798gFfQX+viw3R7yrGWRqnrN2oRkEkUjjl4JNn4E8GxxbjtG3FbrEIIY3l8/hrwUwIeCZvi4QuOTP4MErVug==} engines: {node: '>=12'} any-promise@1.3.0: @@ -897,8 +892,8 @@ packages: resolution: {integrity: sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==} engines: {node: '>=8'} - browserslist@4.25.4: - resolution: {integrity: sha512-4jYpcjabC606xJ3kw2QwGEZKX0Aw7sgQdZCvIK9dhVSPh76BKo+C+btT1RRofH7B+8iNpEbgGNVWiLki5q93yg==} + browserslist@4.25.3: + resolution: {integrity: sha512-cDGv1kkDI4/0e5yON9yM5G/0A5u8sf5TnmdX5C9qHzI9PPu++sQ9zjm1k9NiOrf3riY4OkK0zSGqfvJyJsgCBQ==} engines: {node: ^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7} hasBin: true @@ -936,8 +931,8 @@ packages: resolution: {integrity: sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==} engines: {node: '>=6'} - caniuse-lite@1.0.30001741: - resolution: {integrity: sha512-QGUGitqsc8ARjLdgAfxETDhRbJ0REsP6O3I96TAth/mVjh2cYzN2u+3AzPP3aVSm2FehEItaJw1xd+IGBXWeSw==} + caniuse-lite@1.0.30001737: + resolution: {integrity: sha512-BiloLiXtQNrY5UyF0+1nSJLXUENuhka2pzy2Fx5pGxqavdrxSCW4U6Pn/PoG3Efspi2frRbHpBV2XsrPE6EDlw==} chai@5.3.3: resolution: {integrity: sha512-4zNhdJD/iOjSH0A05ea+Ke6MU5mmpQcbQsSOkgdaUMJ9zTlDTD/GYlwohmIE2u0gaxHYiVHEn1Fw9mZ/ktJWgw==} @@ -1043,8 +1038,8 @@ packages: resolution: {integrity: sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==} engines: {node: '>=0.4.0'} - detsys-ts@https://codeload.github.com/DeterminateSystems/detsys-ts/tar.gz/285768c0d657f9709cb689893f12895c36923093: - resolution: {tarball: https://codeload.github.com/DeterminateSystems/detsys-ts/tar.gz/285768c0d657f9709cb689893f12895c36923093} + detsys-ts@https://codeload.github.com/DeterminateSystems/detsys-ts/tar.gz/e439a01995ac029e7481a75c4661a7f60eeb8b19: + resolution: {tarball: https://codeload.github.com/DeterminateSystems/detsys-ts/tar.gz/e439a01995ac029e7481a75c4661a7f60eeb8b19} version: 1.0.0 dir-glob@3.0.1: @@ -1066,8 +1061,8 @@ packages: eastasianwidth@0.2.0: resolution: {integrity: sha512-I88TYZWc9XiYHRQ4/3c5rjjfgkjhLyW2luGIheGERbNQ6OY7yTybanSpDXZa8y7VUP9YmDcYa+eyq4ca7iLqWA==} - electron-to-chromium@1.5.218: - resolution: {integrity: sha512-uwwdN0TUHs8u6iRgN8vKeWZMRll4gBkz+QMqdS7DDe49uiK68/UX92lFb61oiFPrpYZNeZIqa4bA7O6Aiasnzg==} + electron-to-chromium@1.5.208: + resolution: {integrity: sha512-ozZyibehoe7tOhNaf16lKmljVf+3npZcJIEbJRVftVsmAg5TeA1mGS9dVCZzOwr2xT7xK15V0p7+GZqSPgkuPg==} emoji-regex@8.0.0: resolution: {integrity: sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==} @@ -1423,8 +1418,8 @@ packages: resolution: {integrity: sha512-ZUKRh6/kUFoAiTAtTYPZJ3hw9wNxx+BIBOijnlG9PnrJsCcSjs1wyyD6vJpaYtgnzDrKYRSqf3OO6Rfa93xsRg==} engines: {node: '>= 0.4'} - got@14.4.8: - resolution: {integrity: sha512-vxwU4HuR0BIl+zcT1LYrgBjM+IJjNElOjCzs0aPgHorQyr/V6H6Y73Sn3r3FOlUffvWD+Q5jtRuGWaXkU8Jbhg==} + got@14.4.7: + resolution: {integrity: sha512-DI8zV1231tqiGzOiOzQWDhsBmncFW7oQDH6Zgy6pDPrqJuVZMtoSgPLLsBZQj8Jg4JFfwoOsDA8NGtLQLnIx2g==} engines: {node: '>=20'} graphemer@1.4.0: @@ -1723,8 +1718,8 @@ packages: lru-cache@10.4.3: resolution: {integrity: sha512-JNAzZcXrCt42VGLuYz0zfAzDfAvJWW6AfYlDBQyDV5DClI2m5sAmK+OIO7s59XfsRsWHp02jAJrRadPRGTt6SQ==} - magic-string@0.30.19: - resolution: {integrity: sha512-2N21sPY9Ws53PZvsEpVtNuSW+ScYbQdp4b9qUaL+9QkHUrGFKo56Lg9Emg5s9V/qrtNBmiR01sYhUOwu3H+VOw==} + magic-string@0.30.18: + resolution: {integrity: sha512-yi8swmWbO17qHhwIBNeeZxTceJMeBvWJaId6dyvTSOwTipqeHhMhOrz6513r1sOKnpvQ7zkhlG8tPrpilwTxHQ==} math-intrinsics@1.1.0: resolution: {integrity: sha512-/IXtbwEk5HTPyEwyKX6hGkYXxM9nbj64B+ilVJnC/R6B0pH5G4V3b0pVbL7DBj4tkhBAppbQUlf6F6Xl9LHu1g==} @@ -1799,11 +1794,11 @@ packages: encoding: optional: true - node-releases@2.0.21: - resolution: {integrity: sha512-5b0pgg78U3hwXkCM8Z9b2FJdPZlr9Psr9V2gQPESdGHqbntyFJKFW4r5TeWGFzafGY3hzs1JC62VEQMbl1JFkw==} + node-releases@2.0.19: + resolution: {integrity: sha512-xxOWJsBKtzAq7DY0J+DTzuz58K8e7sJbdgwkbMWQe8UYB6ekmsQ45q0M/tJDsGaZmbC+l7n57UV8Hl5tHxO9uw==} - normalize-url@8.1.0: - resolution: {integrity: sha512-X06Mfd/5aKsRHc0O0J5CUedwnPmnDtLF2+nq+KN9KSDlJHkPuh0JUviWjEWMe0SW/9TDdSLVPuk7L5gGTIA1/w==} + normalize-url@8.0.2: + resolution: {integrity: sha512-Ee/R3SyN4BuynXcnTaekmaVdbDAEiNrHqjQIA37mHU8G9pf7aaAD4ZX3XjBLo6rsdcxA/gtkcNYZLt30ACgynw==} engines: {node: '>=14.16'} object-assign@4.1.1: @@ -2006,8 +2001,8 @@ packages: deprecated: Rimraf versions prior to v4 are no longer supported hasBin: true - rollup@4.50.1: - resolution: {integrity: sha512-78E9voJHwnXQMiQdiqswVLZwJIzdBKJ1GdI5Zx6XwoFKUIk09/sSrr+05QFzvYb8q6Y9pPV45zzDuYa3907TZA==} + rollup@4.48.1: + resolution: {integrity: sha512-jVG20NvbhTYDkGAty2/Yh7HK6/q3DGSRH4o8ALKGArmMuaauM9kLfoMZ+WliPwA5+JHr2lTn3g557FxBV87ifg==} engines: {node: '>=18.0.0', npm: '>=8.0.0'} hasBin: true @@ -2142,8 +2137,8 @@ packages: resolution: {integrity: sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==} engines: {node: '>=8'} - strip-ansi@7.1.2: - resolution: {integrity: sha512-gmBGslpoQJtgnMAvOVqGZpEz9dyoKTCzy2nfz/n8aIFhN/jCE/rCmcxabB6jOOHV+0WNnylOxaxBQPSvcWklhA==} + strip-ansi@7.1.0: + resolution: {integrity: sha512-iq6eVVI64nQQTRYq2KtEg2d2uU7LElhTJwsH4YzIHZshxlgZms/wIc4VoDQTlG/IvVIrBKG06CrZnp0qv7hkcQ==} engines: {node: '>=12'} strip-bom@3.0.0: @@ -2196,8 +2191,8 @@ packages: tinyexec@0.3.2: resolution: {integrity: sha512-KQQR9yN7R5+OSwaK0XQoj22pwHoTlgYqmUscPYoknOoWCWfj/5/ABTMRi69FrKU5ffPVh5QcFikpWJI/P1ocHA==} - tinyglobby@0.2.15: - resolution: {integrity: sha512-j2Zq4NyQYG5XMST4cbs02Ak8iJUdxRM0XI5QyxXuZOzKOINmWurp3smXu3y5wDcJrptwpSjgXHzIQxR0omXljQ==} + tinyglobby@0.2.14: + resolution: {integrity: sha512-tX5e7OM1HnYr2+a2C/4V0htOcSQcoSTH9KgJnVvNm5zm/cyEWKJ7j7YutsH9CxMdtOkkLFy2AHrMci9IM8IPZQ==} engines: {node: '>=12.0.0'} tinypool@1.1.1: @@ -2336,8 +2331,8 @@ packages: engines: {node: ^18.0.0 || ^20.0.0 || >=22.0.0} hasBin: true - vite@7.1.5: - resolution: {integrity: sha512-4cKBO9wR75r0BeIWWWId9XK9Lj6La5X846Zw9dFfzMRw38IlTk2iCcUt6hsyiDRcPidc55ZParFYDXi0nXOeLQ==} + vite@7.1.3: + resolution: {integrity: sha512-OOUi5zjkDxYrKhTV3V7iKsoS37VUM7v40+HuwEmcrsf11Cdx9y3DIr2Px6liIcZFwt3XSRpQvFpL3WVy7ApkGw==} engines: {node: ^20.19.0 || >=22.12.0} hasBin: true peerDependencies: @@ -2516,38 +2511,38 @@ snapshots: dependencies: tslib: 2.8.1 - '@azure/core-auth@1.10.1': + '@azure/core-auth@1.10.0': dependencies: '@azure/abort-controller': 2.1.2 - '@azure/core-util': 1.13.1 + '@azure/core-util': 1.13.0 tslib: 2.8.1 transitivePeerDependencies: - supports-color - '@azure/core-client@1.10.1': + '@azure/core-client@1.10.0': dependencies: '@azure/abort-controller': 2.1.2 - '@azure/core-auth': 1.10.1 - '@azure/core-rest-pipeline': 1.22.1 - '@azure/core-tracing': 1.3.1 - '@azure/core-util': 1.13.1 + '@azure/core-auth': 1.10.0 + '@azure/core-rest-pipeline': 1.22.0 + '@azure/core-tracing': 1.3.0 + '@azure/core-util': 1.13.0 '@azure/logger': 1.3.0 tslib: 2.8.1 transitivePeerDependencies: - supports-color - '@azure/core-http-compat@2.3.1': + '@azure/core-http-compat@2.3.0': dependencies: '@azure/abort-controller': 2.1.2 - '@azure/core-client': 1.10.1 - '@azure/core-rest-pipeline': 1.22.1 + '@azure/core-client': 1.10.0 + '@azure/core-rest-pipeline': 1.22.0 transitivePeerDependencies: - supports-color '@azure/core-lro@2.7.2': dependencies: '@azure/abort-controller': 2.1.2 - '@azure/core-util': 1.13.1 + '@azure/core-util': 1.13.0 '@azure/logger': 1.3.0 tslib: 2.8.1 transitivePeerDependencies: @@ -2557,26 +2552,26 @@ snapshots: dependencies: tslib: 2.8.1 - '@azure/core-rest-pipeline@1.22.1': + '@azure/core-rest-pipeline@1.22.0': dependencies: '@azure/abort-controller': 2.1.2 - '@azure/core-auth': 1.10.1 - '@azure/core-tracing': 1.3.1 - '@azure/core-util': 1.13.1 + '@azure/core-auth': 1.10.0 + '@azure/core-tracing': 1.3.0 + '@azure/core-util': 1.13.0 '@azure/logger': 1.3.0 - '@typespec/ts-http-runtime': 0.3.1 + '@typespec/ts-http-runtime': 0.3.0 tslib: 2.8.1 transitivePeerDependencies: - supports-color - '@azure/core-tracing@1.3.1': + '@azure/core-tracing@1.3.0': dependencies: tslib: 2.8.1 - '@azure/core-util@1.13.1': + '@azure/core-util@1.13.0': dependencies: '@azure/abort-controller': 2.1.2 - '@typespec/ts-http-runtime': 0.3.1 + '@typespec/ts-http-runtime': 0.3.0 tslib: 2.8.1 transitivePeerDependencies: - supports-color @@ -2588,14 +2583,14 @@ snapshots: '@azure/logger@1.3.0': dependencies: - '@typespec/ts-http-runtime': 0.3.1 + '@typespec/ts-http-runtime': 0.3.0 tslib: 2.8.1 transitivePeerDependencies: - supports-color '@azure/ms-rest-js@2.7.0': dependencies: - '@azure/core-auth': 1.10.1 + '@azure/core-auth': 1.10.0 abort-controller: 3.0.0 form-data: 2.5.5 node-fetch: 2.7.0 @@ -2610,14 +2605,14 @@ snapshots: '@azure/storage-blob@12.28.0': dependencies: '@azure/abort-controller': 2.1.2 - '@azure/core-auth': 1.10.1 - '@azure/core-client': 1.10.1 - '@azure/core-http-compat': 2.3.1 + '@azure/core-auth': 1.10.0 + '@azure/core-client': 1.10.0 + '@azure/core-http-compat': 2.3.0 '@azure/core-lro': 2.7.2 '@azure/core-paging': 1.6.2 - '@azure/core-rest-pipeline': 1.22.1 - '@azure/core-tracing': 1.3.1 - '@azure/core-util': 1.13.1 + '@azure/core-rest-pipeline': 1.22.0 + '@azure/core-tracing': 1.3.0 + '@azure/core-util': 1.13.0 '@azure/core-xml': 1.5.0 '@azure/logger': 1.3.0 '@azure/storage-common': 12.0.0 @@ -2629,11 +2624,11 @@ snapshots: '@azure/storage-common@12.0.0': dependencies: '@azure/abort-controller': 2.1.2 - '@azure/core-auth': 1.10.1 - '@azure/core-http-compat': 2.3.1 - '@azure/core-rest-pipeline': 1.22.1 - '@azure/core-tracing': 1.3.1 - '@azure/core-util': 1.13.1 + '@azure/core-auth': 1.10.0 + '@azure/core-http-compat': 2.3.0 + '@azure/core-rest-pipeline': 1.22.0 + '@azure/core-tracing': 1.3.0 + '@azure/core-util': 1.13.0 '@azure/logger': 1.3.0 events: 3.3.0 tslib: 2.8.1 @@ -2654,42 +2649,42 @@ snapshots: '@babel/generator@7.28.3': dependencies: - '@babel/parser': 7.28.4 - '@babel/types': 7.28.4 + '@babel/parser': 7.28.3 + '@babel/types': 7.28.2 '@jridgewell/gen-mapping': 0.3.13 - '@jridgewell/trace-mapping': 0.3.31 + '@jridgewell/trace-mapping': 0.3.30 jsesc: 3.1.0 '@babel/helper-environment-visitor@7.24.7': dependencies: - '@babel/types': 7.28.4 + '@babel/types': 7.28.2 '@babel/helper-function-name@7.24.7': dependencies: '@babel/template': 7.27.2 - '@babel/types': 7.28.4 + '@babel/types': 7.28.2 '@babel/helper-hoist-variables@7.24.7': dependencies: - '@babel/types': 7.28.4 + '@babel/types': 7.28.2 '@babel/helper-split-export-declaration@7.24.7': dependencies: - '@babel/types': 7.28.4 + '@babel/types': 7.28.2 '@babel/helper-string-parser@7.27.1': {} '@babel/helper-validator-identifier@7.27.1': {} - '@babel/parser@7.28.4': + '@babel/parser@7.28.3': dependencies: - '@babel/types': 7.28.4 + '@babel/types': 7.28.2 '@babel/template@7.27.2': dependencies: '@babel/code-frame': 7.27.1 - '@babel/parser': 7.28.4 - '@babel/types': 7.28.4 + '@babel/parser': 7.28.3 + '@babel/types': 7.28.2 '@babel/traverse@7.23.2': dependencies: @@ -2699,8 +2694,8 @@ snapshots: '@babel/helper-function-name': 7.24.7 '@babel/helper-hoist-variables': 7.24.7 '@babel/helper-split-export-declaration': 7.24.7 - '@babel/parser': 7.28.4 - '@babel/types': 7.28.4 + '@babel/parser': 7.28.3 + '@babel/types': 7.28.2 debug: 4.4.1 globals: 11.12.0 transitivePeerDependencies: @@ -2711,23 +2706,23 @@ snapshots: '@babel/helper-validator-identifier': 7.27.1 to-fast-properties: 2.0.0 - '@babel/types@7.28.4': + '@babel/types@7.28.2': dependencies: '@babel/helper-string-parser': 7.27.1 '@babel/helper-validator-identifier': 7.27.1 - '@emnapi/core@1.5.0': + '@emnapi/core@1.4.5': dependencies: - '@emnapi/wasi-threads': 1.1.0 + '@emnapi/wasi-threads': 1.0.4 tslib: 2.8.1 optional: true - '@emnapi/runtime@1.5.0': + '@emnapi/runtime@1.4.5': dependencies: tslib: 2.8.1 optional: true - '@emnapi/wasi-threads@1.1.0': + '@emnapi/wasi-threads@1.0.4': dependencies: tslib: 2.8.1 optional: true @@ -2810,7 +2805,7 @@ snapshots: '@esbuild/win32-x64@0.25.9': optional: true - '@eslint-community/eslint-utils@4.9.0(eslint@8.57.1)': + '@eslint-community/eslint-utils@4.7.0(eslint@8.57.1)': dependencies: eslint: 8.57.1 eslint-visitor-keys: 3.4.3 @@ -2853,7 +2848,7 @@ snapshots: dependencies: string-width: 5.1.2 string-width-cjs: string-width@4.2.3 - strip-ansi: 7.1.2 + strip-ansi: 7.1.0 strip-ansi-cjs: strip-ansi@6.0.1 wrap-ansi: 8.1.0 wrap-ansi-cjs: wrap-ansi@7.0.0 @@ -2861,22 +2856,22 @@ snapshots: '@jridgewell/gen-mapping@0.3.13': dependencies: '@jridgewell/sourcemap-codec': 1.5.5 - '@jridgewell/trace-mapping': 0.3.31 + '@jridgewell/trace-mapping': 0.3.30 '@jridgewell/resolve-uri@3.1.2': {} '@jridgewell/sourcemap-codec@1.5.5': {} - '@jridgewell/trace-mapping@0.3.31': + '@jridgewell/trace-mapping@0.3.30': dependencies: '@jridgewell/resolve-uri': 3.1.2 '@jridgewell/sourcemap-codec': 1.5.5 '@napi-rs/wasm-runtime@0.2.12': dependencies: - '@emnapi/core': 1.5.0 - '@emnapi/runtime': 1.5.0 - '@tybys/wasm-util': 0.10.1 + '@emnapi/core': 1.4.5 + '@emnapi/runtime': 1.4.5 + '@tybys/wasm-util': 0.10.0 optional: true '@nodelib/fs.scandir@2.1.5': @@ -2904,67 +2899,64 @@ snapshots: '@protobuf-ts/runtime@2.11.1': {} - '@rollup/rollup-android-arm-eabi@4.50.1': + '@rollup/rollup-android-arm-eabi@4.48.1': optional: true - '@rollup/rollup-android-arm64@4.50.1': + '@rollup/rollup-android-arm64@4.48.1': optional: true - '@rollup/rollup-darwin-arm64@4.50.1': + '@rollup/rollup-darwin-arm64@4.48.1': optional: true - '@rollup/rollup-darwin-x64@4.50.1': + '@rollup/rollup-darwin-x64@4.48.1': optional: true - '@rollup/rollup-freebsd-arm64@4.50.1': + '@rollup/rollup-freebsd-arm64@4.48.1': optional: true - '@rollup/rollup-freebsd-x64@4.50.1': + '@rollup/rollup-freebsd-x64@4.48.1': optional: true - '@rollup/rollup-linux-arm-gnueabihf@4.50.1': + '@rollup/rollup-linux-arm-gnueabihf@4.48.1': optional: true - '@rollup/rollup-linux-arm-musleabihf@4.50.1': + '@rollup/rollup-linux-arm-musleabihf@4.48.1': optional: true - '@rollup/rollup-linux-arm64-gnu@4.50.1': + '@rollup/rollup-linux-arm64-gnu@4.48.1': optional: true - '@rollup/rollup-linux-arm64-musl@4.50.1': + '@rollup/rollup-linux-arm64-musl@4.48.1': optional: true - '@rollup/rollup-linux-loongarch64-gnu@4.50.1': + '@rollup/rollup-linux-loongarch64-gnu@4.48.1': optional: true - '@rollup/rollup-linux-ppc64-gnu@4.50.1': + '@rollup/rollup-linux-ppc64-gnu@4.48.1': optional: true - '@rollup/rollup-linux-riscv64-gnu@4.50.1': + '@rollup/rollup-linux-riscv64-gnu@4.48.1': optional: true - '@rollup/rollup-linux-riscv64-musl@4.50.1': + '@rollup/rollup-linux-riscv64-musl@4.48.1': optional: true - '@rollup/rollup-linux-s390x-gnu@4.50.1': + '@rollup/rollup-linux-s390x-gnu@4.48.1': optional: true - '@rollup/rollup-linux-x64-gnu@4.50.1': + '@rollup/rollup-linux-x64-gnu@4.48.1': optional: true - '@rollup/rollup-linux-x64-musl@4.50.1': + '@rollup/rollup-linux-x64-musl@4.48.1': optional: true - '@rollup/rollup-openharmony-arm64@4.50.1': + '@rollup/rollup-win32-arm64-msvc@4.48.1': optional: true - '@rollup/rollup-win32-arm64-msvc@4.50.1': + '@rollup/rollup-win32-ia32-msvc@4.48.1': optional: true - '@rollup/rollup-win32-ia32-msvc@4.50.1': - optional: true - - '@rollup/rollup-win32-x64-msvc@4.50.1': + '@rollup/rollup-win32-x64-msvc@4.48.1': optional: true '@rtsao/scc@1.1.0': {} @@ -2980,7 +2972,7 @@ snapshots: '@trivago/prettier-plugin-sort-imports@4.3.0(prettier@3.6.2)': dependencies: '@babel/generator': 7.17.7 - '@babel/parser': 7.28.4 + '@babel/parser': 7.28.3 '@babel/traverse': 7.23.2 '@babel/types': 7.17.0 javascript-natural-sort: 0.7.1 @@ -2989,7 +2981,7 @@ snapshots: transitivePeerDependencies: - supports-color - '@tybys/wasm-util@0.10.1': + '@tybys/wasm-util@0.10.0': dependencies: tslib: 2.8.1 optional: true @@ -3073,7 +3065,7 @@ snapshots: '@typescript-eslint/utils@7.18.0(eslint@8.57.1)(typescript@5.9.2)': dependencies: - '@eslint-community/eslint-utils': 4.9.0(eslint@8.57.1) + '@eslint-community/eslint-utils': 4.7.0(eslint@8.57.1) '@typescript-eslint/scope-manager': 7.18.0 '@typescript-eslint/types': 7.18.0 '@typescript-eslint/typescript-estree': 7.18.0(typescript@5.9.2) @@ -3087,7 +3079,7 @@ snapshots: '@typescript-eslint/types': 7.18.0 eslint-visitor-keys: 3.4.3 - '@typespec/ts-http-runtime@0.3.1': + '@typespec/ts-http-runtime@0.3.0': dependencies: http-proxy-agent: 7.0.2 https-proxy-agent: 7.0.6 @@ -3166,13 +3158,13 @@ snapshots: chai: 5.3.3 tinyrainbow: 2.0.0 - '@vitest/mocker@3.2.4(vite@7.1.5)': + '@vitest/mocker@3.2.4(vite@7.1.3)': dependencies: '@vitest/spy': 3.2.4 estree-walker: 3.0.3 - magic-string: 0.30.19 + magic-string: 0.30.18 optionalDependencies: - vite: 7.1.5 + vite: 7.1.3 '@vitest/pretty-format@3.2.4': dependencies: @@ -3187,7 +3179,7 @@ snapshots: '@vitest/snapshot@3.2.4': dependencies: '@vitest/pretty-format': 3.2.4 - magic-string: 0.30.19 + magic-string: 0.30.18 pathe: 2.0.3 '@vitest/spy@3.2.4': @@ -3221,13 +3213,13 @@ snapshots: ansi-regex@5.0.1: {} - ansi-regex@6.2.2: {} + ansi-regex@6.2.0: {} ansi-styles@4.3.0: dependencies: color-convert: 2.0.1 - ansi-styles@6.2.3: {} + ansi-styles@6.2.1: {} any-promise@1.3.0: {} @@ -3318,12 +3310,12 @@ snapshots: dependencies: fill-range: 7.1.1 - browserslist@4.25.4: + browserslist@4.25.3: dependencies: - caniuse-lite: 1.0.30001741 - electron-to-chromium: 1.5.218 - node-releases: 2.0.21 - update-browserslist-db: 1.1.3(browserslist@4.25.4) + caniuse-lite: 1.0.30001737 + electron-to-chromium: 1.5.208 + node-releases: 2.0.19 + update-browserslist-db: 1.1.3(browserslist@4.25.3) bundle-require@5.1.0(esbuild@0.25.9): dependencies: @@ -3341,7 +3333,7 @@ snapshots: http-cache-semantics: 4.2.0 keyv: 4.5.4 mimic-response: 4.0.0 - normalize-url: 8.1.0 + normalize-url: 8.0.2 responselike: 3.0.0 call-bind-apply-helpers@1.0.2: @@ -3363,7 +3355,7 @@ snapshots: callsites@3.1.0: {} - caniuse-lite@1.0.30001741: {} + caniuse-lite@1.0.30001737: {} chai@5.3.3: dependencies: @@ -3460,12 +3452,12 @@ snapshots: delayed-stream@1.0.0: {} - detsys-ts@https://codeload.github.com/DeterminateSystems/detsys-ts/tar.gz/285768c0d657f9709cb689893f12895c36923093: + detsys-ts@https://codeload.github.com/DeterminateSystems/detsys-ts/tar.gz/e439a01995ac029e7481a75c4661a7f60eeb8b19: dependencies: '@actions/cache': 4.0.5 '@actions/core': 1.11.1 '@actions/exec': 1.1.1 - got: 14.4.8 + got: 14.4.7 type-fest: 4.41.0 transitivePeerDependencies: - encoding @@ -3491,7 +3483,7 @@ snapshots: eastasianwidth@0.2.0: {} - electron-to-chromium@1.5.218: {} + electron-to-chromium@1.5.208: {} emoji-regex@8.0.0: {} @@ -3636,7 +3628,7 @@ snapshots: get-tsconfig: 4.10.1 is-bun-module: 2.0.0 stable-hash: 0.0.5 - tinyglobby: 0.2.15 + tinyglobby: 0.2.14 unrs-resolver: 1.11.1 optionalDependencies: eslint-plugin-import: 2.32.0(@typescript-eslint/parser@7.18.0(eslint@8.57.1)(typescript@5.9.2))(eslint-import-resolver-typescript@3.10.1)(eslint@8.57.1) @@ -3656,7 +3648,7 @@ snapshots: eslint-plugin-escompat@3.11.4(eslint@8.57.1): dependencies: - browserslist: 4.25.4 + browserslist: 4.25.3 eslint: 8.57.1 eslint-plugin-eslint-comments@3.2.0(eslint@8.57.1): @@ -3774,7 +3766,7 @@ snapshots: eslint@8.57.1: dependencies: - '@eslint-community/eslint-utils': 4.9.0(eslint@8.57.1) + '@eslint-community/eslint-utils': 4.7.0(eslint@8.57.1) '@eslint-community/regexpp': 4.12.1 '@eslint/eslintrc': 2.1.4 '@eslint/js': 8.57.1 @@ -3886,9 +3878,9 @@ snapshots: fix-dts-default-cjs-exports@1.0.1: dependencies: - magic-string: 0.30.19 + magic-string: 0.30.18 mlly: 1.8.0 - rollup: 4.50.1 + rollup: 4.48.1 flat-cache@3.2.0: dependencies: @@ -4017,7 +4009,7 @@ snapshots: gopd@1.2.0: {} - got@14.4.8: + got@14.4.7: dependencies: '@sindresorhus/is': 7.0.2 '@szmarczak/http-timer': 5.0.1 @@ -4303,7 +4295,7 @@ snapshots: lru-cache@10.4.3: {} - magic-string@0.30.19: + magic-string@0.30.18: dependencies: '@jridgewell/sourcemap-codec': 1.5.5 @@ -4363,9 +4355,9 @@ snapshots: dependencies: whatwg-url: 5.0.0 - node-releases@2.0.21: {} + node-releases@2.0.19: {} - normalize-url@8.1.0: {} + normalize-url@8.0.2: {} object-assign@4.1.1: {} @@ -4544,31 +4536,30 @@ snapshots: dependencies: glob: 7.2.3 - rollup@4.50.1: + rollup@4.48.1: dependencies: '@types/estree': 1.0.8 optionalDependencies: - '@rollup/rollup-android-arm-eabi': 4.50.1 - '@rollup/rollup-android-arm64': 4.50.1 - '@rollup/rollup-darwin-arm64': 4.50.1 - '@rollup/rollup-darwin-x64': 4.50.1 - '@rollup/rollup-freebsd-arm64': 4.50.1 - '@rollup/rollup-freebsd-x64': 4.50.1 - '@rollup/rollup-linux-arm-gnueabihf': 4.50.1 - '@rollup/rollup-linux-arm-musleabihf': 4.50.1 - '@rollup/rollup-linux-arm64-gnu': 4.50.1 - '@rollup/rollup-linux-arm64-musl': 4.50.1 - '@rollup/rollup-linux-loongarch64-gnu': 4.50.1 - '@rollup/rollup-linux-ppc64-gnu': 4.50.1 - '@rollup/rollup-linux-riscv64-gnu': 4.50.1 - '@rollup/rollup-linux-riscv64-musl': 4.50.1 - '@rollup/rollup-linux-s390x-gnu': 4.50.1 - '@rollup/rollup-linux-x64-gnu': 4.50.1 - '@rollup/rollup-linux-x64-musl': 4.50.1 - '@rollup/rollup-openharmony-arm64': 4.50.1 - '@rollup/rollup-win32-arm64-msvc': 4.50.1 - '@rollup/rollup-win32-ia32-msvc': 4.50.1 - '@rollup/rollup-win32-x64-msvc': 4.50.1 + '@rollup/rollup-android-arm-eabi': 4.48.1 + '@rollup/rollup-android-arm64': 4.48.1 + '@rollup/rollup-darwin-arm64': 4.48.1 + '@rollup/rollup-darwin-x64': 4.48.1 + '@rollup/rollup-freebsd-arm64': 4.48.1 + '@rollup/rollup-freebsd-x64': 4.48.1 + '@rollup/rollup-linux-arm-gnueabihf': 4.48.1 + '@rollup/rollup-linux-arm-musleabihf': 4.48.1 + '@rollup/rollup-linux-arm64-gnu': 4.48.1 + '@rollup/rollup-linux-arm64-musl': 4.48.1 + '@rollup/rollup-linux-loongarch64-gnu': 4.48.1 + '@rollup/rollup-linux-ppc64-gnu': 4.48.1 + '@rollup/rollup-linux-riscv64-gnu': 4.48.1 + '@rollup/rollup-linux-riscv64-musl': 4.48.1 + '@rollup/rollup-linux-s390x-gnu': 4.48.1 + '@rollup/rollup-linux-x64-gnu': 4.48.1 + '@rollup/rollup-linux-x64-musl': 4.48.1 + '@rollup/rollup-win32-arm64-msvc': 4.48.1 + '@rollup/rollup-win32-ia32-msvc': 4.48.1 + '@rollup/rollup-win32-x64-msvc': 4.48.1 fsevents: 2.3.3 run-parallel@1.2.0: @@ -4693,7 +4684,7 @@ snapshots: dependencies: eastasianwidth: 0.2.0 emoji-regex: 9.2.2 - strip-ansi: 7.1.2 + strip-ansi: 7.1.0 string.prototype.includes@2.0.1: dependencies: @@ -4728,9 +4719,9 @@ snapshots: dependencies: ansi-regex: 5.0.1 - strip-ansi@7.1.2: + strip-ansi@7.1.0: dependencies: - ansi-regex: 6.2.2 + ansi-regex: 6.2.0 strip-bom@3.0.0: {} @@ -4778,7 +4769,7 @@ snapshots: tinyexec@0.3.2: {} - tinyglobby@0.2.15: + tinyglobby@0.2.14: dependencies: fdir: 6.5.0(picomatch@4.0.3) picomatch: 4.0.3 @@ -4833,11 +4824,11 @@ snapshots: picocolors: 1.1.1 postcss-load-config: 6.0.1(postcss@8.5.6) resolve-from: 5.0.0 - rollup: 4.50.1 + rollup: 4.48.1 source-map: 0.8.0-beta.0 sucrase: 3.35.0 tinyexec: 0.3.2 - tinyglobby: 0.2.15 + tinyglobby: 0.2.14 tree-kill: 1.2.2 optionalDependencies: postcss: 8.5.6 @@ -4930,9 +4921,9 @@ snapshots: '@unrs/resolver-binding-win32-ia32-msvc': 1.11.1 '@unrs/resolver-binding-win32-x64-msvc': 1.11.1 - update-browserslist-db@1.1.3(browserslist@4.25.4): + update-browserslist-db@1.1.3(browserslist@4.25.3): dependencies: - browserslist: 4.25.4 + browserslist: 4.25.3 escalade: 3.2.0 picocolors: 1.1.1 @@ -4948,7 +4939,7 @@ snapshots: debug: 4.4.1 es-module-lexer: 1.7.0 pathe: 2.0.3 - vite: 7.1.5 + vite: 7.1.3 transitivePeerDependencies: - '@types/node' - jiti @@ -4963,14 +4954,14 @@ snapshots: - tsx - yaml - vite@7.1.5: + vite@7.1.3: dependencies: esbuild: 0.25.9 fdir: 6.5.0(picomatch@4.0.3) picomatch: 4.0.3 postcss: 8.5.6 - rollup: 4.50.1 - tinyglobby: 0.2.15 + rollup: 4.48.1 + tinyglobby: 0.2.14 optionalDependencies: fsevents: 2.3.3 @@ -4978,7 +4969,7 @@ snapshots: dependencies: '@types/chai': 5.2.2 '@vitest/expect': 3.2.4 - '@vitest/mocker': 3.2.4(vite@7.1.5) + '@vitest/mocker': 3.2.4(vite@7.1.3) '@vitest/pretty-format': 3.2.4 '@vitest/runner': 3.2.4 '@vitest/snapshot': 3.2.4 @@ -4987,16 +4978,16 @@ snapshots: chai: 5.3.3 debug: 4.4.1 expect-type: 1.2.2 - magic-string: 0.30.19 + magic-string: 0.30.18 pathe: 2.0.3 picomatch: 4.0.3 std-env: 3.9.0 tinybench: 2.9.0 tinyexec: 0.3.2 - tinyglobby: 0.2.15 + tinyglobby: 0.2.14 tinypool: 1.1.1 tinyrainbow: 2.0.0 - vite: 7.1.5 + vite: 7.1.3 vite-node: 3.2.4 why-is-node-running: 2.3.0 transitivePeerDependencies: @@ -5088,9 +5079,9 @@ snapshots: wrap-ansi@8.1.0: dependencies: - ansi-styles: 6.2.3 + ansi-styles: 6.2.1 string-width: 5.1.2 - strip-ansi: 7.1.2 + strip-ansi: 7.1.0 wrappy@1.0.2: {}