Skip to content

Commit 6a3436c

Browse files
chore(deps-dev): Bump prettier from 3.2.2 to 3.2.4 (#359)
* chore(deps-dev): Bump prettier from 3.2.2 to 3.2.4 Bumps [prettier](https://github.com/prettier/prettier) from 3.2.2 to 3.2.4. - [Release notes](https://github.com/prettier/prettier/releases) - [Changelog](https://github.com/prettier/prettier/blob/main/CHANGELOG.md) - [Commits](prettier/prettier@3.2.2...3.2.4) --- updated-dependencies: - dependency-name: prettier dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Scott Brenner <[email protected]>
1 parent 60b9f42 commit 6a3436c

File tree

4 files changed

+2708
-1283
lines changed

4 files changed

+2708
-1283
lines changed

.devcontainer/devcontainer.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,13 @@
66
"dockerfile": "Dockerfile",
77
// Update 'VARIANT' to pick a Node version: 10, 12, 14
88
"args": {
9-
"VARIANT": "14"
10-
}
9+
"VARIANT": "20",
10+
},
1111
},
1212

1313
// Set *default* container specific settings.json values on container create.
1414
"settings": {
15-
"terminal.integrated.shell.linux": "/bin/bash"
15+
"terminal.integrated.shell.linux": "/bin/bash",
1616
},
1717

1818
// Add the IDs of extensions you want installed when the container is created.
@@ -25,5 +25,5 @@
2525
"postCreateCommand": "npm install",
2626

2727
// Comment out connect as root instead. More info: https://aka.ms/vscode-remote/containers/non-root.
28-
"remoteUser": "node"
28+
"remoteUser": "node",
2929
}

dist/index.js

Lines changed: 37 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -765,7 +765,7 @@ class OidcClient {
765765
.catch(error => {
766766
throw new Error(`Failed to get ID Token. \n
767767
Error Code : ${error.statusCode}\n
768-
Error Message: ${error.result.message}`);
768+
Error Message: ${error.message}`);
769769
});
770770
const id_token = (_a = res.result) === null || _a === void 0 ? void 0 : _a.value;
771771
if (!id_token) {
@@ -2153,6 +2153,19 @@ class HttpClientResponse {
21532153
}));
21542154
});
21552155
}
2156+
readBodyBuffer() {
2157+
return __awaiter(this, void 0, void 0, function* () {
2158+
return new Promise((resolve) => __awaiter(this, void 0, void 0, function* () {
2159+
const chunks = [];
2160+
this.message.on('data', (chunk) => {
2161+
chunks.push(chunk);
2162+
});
2163+
this.message.on('end', () => {
2164+
resolve(Buffer.concat(chunks));
2165+
});
2166+
}));
2167+
});
2168+
}
21562169
}
21572170
exports.HttpClientResponse = HttpClientResponse;
21582171
function isHttps(requestUrl) {
@@ -2657,7 +2670,13 @@ function getProxyUrl(reqUrl) {
26572670
}
26582671
})();
26592672
if (proxyVar) {
2660-
return new URL(proxyVar);
2673+
try {
2674+
return new URL(proxyVar);
2675+
}
2676+
catch (_a) {
2677+
if (!proxyVar.startsWith('http://') && !proxyVar.startsWith('https://'))
2678+
return new URL(`http://${proxyVar}`);
2679+
}
26612680
}
26622681
else {
26632682
return undefined;
@@ -2668,6 +2687,10 @@ function checkBypass(reqUrl) {
26682687
if (!reqUrl.hostname) {
26692688
return false;
26702689
}
2690+
const reqHost = reqUrl.hostname;
2691+
if (isLoopbackAddress(reqHost)) {
2692+
return true;
2693+
}
26712694
const noProxy = process.env['no_proxy'] || process.env['NO_PROXY'] || '';
26722695
if (!noProxy) {
26732696
return false;
@@ -2693,13 +2716,24 @@ function checkBypass(reqUrl) {
26932716
.split(',')
26942717
.map(x => x.trim().toUpperCase())
26952718
.filter(x => x)) {
2696-
if (upperReqHosts.some(x => x === upperNoProxyItem)) {
2719+
if (upperNoProxyItem === '*' ||
2720+
upperReqHosts.some(x => x === upperNoProxyItem ||
2721+
x.endsWith(`.${upperNoProxyItem}`) ||
2722+
(upperNoProxyItem.startsWith('.') &&
2723+
x.endsWith(`${upperNoProxyItem}`)))) {
26972724
return true;
26982725
}
26992726
}
27002727
return false;
27012728
}
27022729
exports.checkBypass = checkBypass;
2730+
function isLoopbackAddress(host) {
2731+
const hostLower = host.toLowerCase();
2732+
return (hostLower === 'localhost' ||
2733+
hostLower.startsWith('127.') ||
2734+
hostLower.startsWith('[::1]') ||
2735+
hostLower.startsWith('[0:0:0:0:0:0:0:1]'));
2736+
}
27032737
//# sourceMappingURL=proxy.js.map
27042738

27052739
/***/ }),

0 commit comments

Comments
 (0)