From ebdda4ddf4c154beaac62c694af7228ed74171aa Mon Sep 17 00:00:00 2001 From: Rhys Arkins <rhys@arkins.net> Date: Sat, 28 Mar 2020 17:38:43 +0100 Subject: [PATCH] fix(gitlab): platform error for 429 --- lib/platform/gitlab/gl-got-wrapper.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/platform/gitlab/gl-got-wrapper.ts b/lib/platform/gitlab/gl-got-wrapper.ts index e98b1f9a60..71338af501 100644 --- a/lib/platform/gitlab/gl-got-wrapper.ts +++ b/lib/platform/gitlab/gl-got-wrapper.ts @@ -33,7 +33,10 @@ async function get(path: string, options: any): Promise<GotResponse> { } return res; } catch (err) /* istanbul ignore next */ { - if (err.statusCode >= 500 && err.statusCode < 600) { + if ( + err.statusCode === 429 || + (err.statusCode >= 500 && err.statusCode < 600) + ) { throw new Error(PLATFORM_FAILURE); } const platformFailureCodes = [ -- GitLab