Skip to content

Commit 63afba9

Browse files
committed
Fix styling
1 parent de50e75 commit 63afba9

File tree

2 files changed

+6
-10
lines changed

2 files changed

+6
-10
lines changed

dist/setup/index.js

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -66763,16 +66763,15 @@ function installCpythonFromRelease(release) {
6676366763
yield installPython(pythonExtractedFolder);
6676466764
}
6676566765
catch (err) {
66766-
if (err instanceof Error) {
66766+
if (err instanceof tc.HTTPError) {
6676766767
// Rate limit?
66768-
if (err instanceof tc.HTTPError &&
66769-
(err.httpStatusCode === 403 || err.httpStatusCode === 429)) {
66768+
if (err.httpStatusCode === 403 || err.httpStatusCode === 429) {
6677066769
core.info(`Received HTTP status code ${err.httpStatusCode}. This usually indicates the rate limit has been exceeded`);
6677166770
}
6677266771
else {
6677366772
core.info(err.message);
6677466773
}
66775-
if (err.stack !== undefined) {
66774+
if (err.stack) {
6677666775
core.debug(err.stack);
6677766776
}
6677866777
}

src/install-python.ts

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -86,19 +86,16 @@ export async function installCpythonFromRelease(release: tc.IToolRelease) {
8686
core.info('Execute installation script');
8787
await installPython(pythonExtractedFolder);
8888
} catch (err) {
89-
if (err instanceof Error) {
89+
if (err instanceof tc.HTTPError) {
9090
// Rate limit?
91-
if (
92-
err instanceof tc.HTTPError &&
93-
(err.httpStatusCode === 403 || err.httpStatusCode === 429)
94-
) {
91+
if (err.httpStatusCode === 403 || err.httpStatusCode === 429) {
9592
core.info(
9693
`Received HTTP status code ${err.httpStatusCode}. This usually indicates the rate limit has been exceeded`
9794
);
9895
} else {
9996
core.info(err.message);
10097
}
101-
if (err.stack !== undefined) {
98+
if (err.stack) {
10299
core.debug(err.stack);
103100
}
104101
}

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy