Skip to content

Commit

Permalink
Fix styling
Browse files Browse the repository at this point in the history
  • Loading branch information
dsame committed Oct 20, 2022
1 parent a1df4f3 commit fbddfe7
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions src/install-python.ts
Expand Up @@ -86,19 +86,16 @@ export async function installCpythonFromRelease(release: tc.IToolRelease) {
core.info('Execute installation script');
await installPython(pythonExtractedFolder);
} catch (err) {
if (err instanceof Error) {
if (err instanceof tc.HTTPError) {
// Rate limit?
if (
err instanceof tc.HTTPError &&
(err.httpStatusCode === 403 || err.httpStatusCode === 429)
) {
if (err.httpStatusCode === 403 || err.httpStatusCode === 429) {
core.info(
`Received HTTP status code ${err.httpStatusCode}. This usually indicates the rate limit has been exceeded`
);
} else {
core.info(err.message);
}
if (err.stack !== undefined) {
if (err.stack) {
core.debug(err.stack);
}
}
Expand Down

0 comments on commit fbddfe7

Please sign in to comment.