@wix/evalforge-evaluator 0.224.0 → 0.226.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/index.js +51 -8
- package/build/index.js.map +1 -1
- package/build/index.mjs +51 -8
- package/build/index.mjs.map +1 -1
- package/package.json +13 -13
package/build/index.mjs
CHANGED
|
@@ -5135,7 +5135,7 @@ var require_http_client_node = __commonJS({
|
|
|
5135
5135
|
* will retry in 1 second.
|
|
5136
5136
|
*/
|
|
5137
5137
|
reportProxyMetric(injectedMeasured, proxyOptions, triesCount = 1) {
|
|
5138
|
-
const gaugeName = !(proxyOptions === null || proxyOptions === void 0 ? void 0 : proxyOptions.httpsAgent) ? "NoProxy" : "Proxy";
|
|
5138
|
+
const gaugeName = !(proxyOptions === null || proxyOptions === void 0 ? void 0 : proxyOptions.httpsAgent) && !(proxyOptions === null || proxyOptions === void 0 ? void 0 : proxyOptions.httpAgent) ? "NoProxy" : "Proxy";
|
|
5139
5139
|
const gauge = initHttpClientInfoGauge(gaugeName, injectedMeasured);
|
|
5140
5140
|
if (gauge) {
|
|
5141
5141
|
gauge(1);
|
|
@@ -5152,16 +5152,35 @@ var require_http_client_node = __commonJS({
|
|
|
5152
5152
|
}
|
|
5153
5153
|
exports.createHttpClient = createHttpClientNode;
|
|
5154
5154
|
function resolveProxyOptions(disableSquidProxy) {
|
|
5155
|
+
if (disableSquidProxy) {
|
|
5156
|
+
return {};
|
|
5157
|
+
}
|
|
5155
5158
|
const proxyUrlAsString = process.env.WIX_HTTP_CLIENT_PROXY_URL;
|
|
5156
|
-
if (
|
|
5159
|
+
if (proxyUrlAsString === null || proxyUrlAsString === void 0 ? void 0 : proxyUrlAsString.length) {
|
|
5160
|
+
const fullProxyUrl = resolveProxyUrl(proxyUrlAsString);
|
|
5161
|
+
return {
|
|
5162
|
+
// please see axios issue - https://github.com/axios/axios/issues/925#issuecomment-359982190
|
|
5163
|
+
httpsAgent: new https_proxy_agent_1.HttpsProxyAgent(fullProxyUrl),
|
|
5164
|
+
httpAgent: new http_proxy_agent_1.HttpProxyAgent(fullProxyUrl)
|
|
5165
|
+
};
|
|
5166
|
+
}
|
|
5167
|
+
return resolveStandardProxyOptions();
|
|
5168
|
+
}
|
|
5169
|
+
function resolveStandardProxyOptions() {
|
|
5170
|
+
var _a, _b, _c;
|
|
5171
|
+
const httpProxy = (_a = process.env.HTTP_PROXY) !== null && _a !== void 0 ? _a : process.env.http_proxy;
|
|
5172
|
+
const httpsProxy = (_c = (_b = process.env.HTTPS_PROXY) !== null && _b !== void 0 ? _b : process.env.https_proxy) !== null && _c !== void 0 ? _c : httpProxy;
|
|
5173
|
+
if (!httpsProxy && !httpProxy) {
|
|
5157
5174
|
return {};
|
|
5158
5175
|
}
|
|
5159
|
-
const
|
|
5160
|
-
|
|
5161
|
-
|
|
5162
|
-
|
|
5163
|
-
|
|
5164
|
-
|
|
5176
|
+
const options = { proxy: false };
|
|
5177
|
+
if (httpsProxy) {
|
|
5178
|
+
options.httpsAgent = new https_proxy_agent_1.HttpsProxyAgent(httpsProxy);
|
|
5179
|
+
}
|
|
5180
|
+
if (httpProxy) {
|
|
5181
|
+
options.httpAgent = new http_proxy_agent_1.HttpProxyAgent(httpProxy);
|
|
5182
|
+
}
|
|
5183
|
+
return options;
|
|
5165
5184
|
}
|
|
5166
5185
|
function resolveProxyUrl(proxyUrl) {
|
|
5167
5186
|
if (proxyUrl.startsWith("http")) {
|
|
@@ -6060,6 +6079,12 @@ function resolveWixEvalforgeV1AgentServiceUrl(opts) {
|
|
|
6060
6079
|
srcPath: "/_api/evalforge-backend",
|
|
6061
6080
|
destPath: ""
|
|
6062
6081
|
}
|
|
6082
|
+
],
|
|
6083
|
+
"www.wixapis.com": [
|
|
6084
|
+
{
|
|
6085
|
+
srcPath: "/_api/evalforge-backend",
|
|
6086
|
+
destPath: ""
|
|
6087
|
+
}
|
|
6063
6088
|
]
|
|
6064
6089
|
};
|
|
6065
6090
|
return resolveUrl(Object.assign(opts, { domainToMappings }));
|
|
@@ -6136,6 +6161,12 @@ function resolveWixEvalforgeV1ProjectServiceUrl(opts) {
|
|
|
6136
6161
|
srcPath: "/_api/evalforge-backend",
|
|
6137
6162
|
destPath: ""
|
|
6138
6163
|
}
|
|
6164
|
+
],
|
|
6165
|
+
"www.wixapis.com": [
|
|
6166
|
+
{
|
|
6167
|
+
srcPath: "/_api/evalforge-backend",
|
|
6168
|
+
destPath: ""
|
|
6169
|
+
}
|
|
6139
6170
|
]
|
|
6140
6171
|
};
|
|
6141
6172
|
return resolveUrl(Object.assign(opts, { domainToMappings }));
|
|
@@ -6212,6 +6243,12 @@ function resolveWixEvalforgeV1PresetServiceUrl(opts) {
|
|
|
6212
6243
|
srcPath: "/_api/evalforge-backend",
|
|
6213
6244
|
destPath: ""
|
|
6214
6245
|
}
|
|
6246
|
+
],
|
|
6247
|
+
"www.wixapis.com": [
|
|
6248
|
+
{
|
|
6249
|
+
srcPath: "/_api/evalforge-backend",
|
|
6250
|
+
destPath: ""
|
|
6251
|
+
}
|
|
6215
6252
|
]
|
|
6216
6253
|
};
|
|
6217
6254
|
return resolveUrl(Object.assign(opts, { domainToMappings }));
|
|
@@ -6435,6 +6472,12 @@ function resolveWixEvalforgeV1SiteProvisioningServiceUrl(opts) {
|
|
|
6435
6472
|
srcPath: "/_api/evalforge-backend",
|
|
6436
6473
|
destPath: ""
|
|
6437
6474
|
}
|
|
6475
|
+
],
|
|
6476
|
+
"www.wixapis.com": [
|
|
6477
|
+
{
|
|
6478
|
+
srcPath: "/_api/evalforge-backend",
|
|
6479
|
+
destPath: ""
|
|
6480
|
+
}
|
|
6438
6481
|
]
|
|
6439
6482
|
};
|
|
6440
6483
|
return resolveUrl(Object.assign(opts, { domainToMappings }));
|