Skip to content

Commit bdc84ba

Browse files
fix(Packages): Adds patch for google-cloud to debug timeout backend error (LLC-1156) (#795)
1 parent 03d2d75 commit bdc84ba

File tree

5 files changed

+622
-592
lines changed

5 files changed

+622
-592
lines changed

Dockerfile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ WORKDIR /usr/src/app
44

55
COPY package.json package.json
66
COPY yarn.lock yarn.lock
7+
COPY patches patches
78
RUN yarn install --production --ignore-engines --frozen-lockfile
89
COPY dist dist
910

package.json

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,8 @@
3131
"lint": "eslint --cache --quiet --fix src",
3232
"lint-ci": "eslint --quiet src",
3333
"semantic-release": "ht2-release-public-circleci-app",
34-
"codecov": "nyc report --reporter=text-lcov > coverage.lcov && codecov"
34+
"codecov": "nyc report --reporter=text-lcov > coverage.lcov && codecov",
35+
"postinstall": "patch-package"
3536
},
3637
"engines": {
3738
"node": ">6.0.0",
@@ -61,6 +62,8 @@
6162
"mongodb": "^3.0.2",
6263
"node-fetch": "^2.0.0",
6364
"object-hash": "^2.0.0",
65+
"patch-package": "^6.4.7",
66+
"postinstall-postinstall": "^2.1.0",
6467
"query-string": "^6.8.2",
6568
"redis": "^3.0.0",
6669
"rulr": "^4.0.0",
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
diff --git a/node_modules/@google-cloud/common/build/src/util.js b/node_modules/@google-cloud/common/build/src/util.js
2+
index 4860a5d..022210e 100644
3+
--- a/node_modules/@google-cloud/common/build/src/util.js
4+
+++ b/node_modules/@google-cloud/common/build/src/util.js
5+
@@ -49,8 +49,12 @@ class ApiError extends Error {
6+
this.code = errorBody.code;
7+
this.errors = errorBody.errors;
8+
this.response = errorBody.response;
9+
+
10+
+ console.log("API Error. errorBody: ", errorBody);
11+
+
12+
try {
13+
this.errors = JSON.parse(this.response.body).error.errors;
14+
+ console.log("TRY. parsed response body errors: ", JSON.parse(this.response.body).error.errors);
15+
}
16+
catch (e) {
17+
this.errors = errorBody.errors;

renovate.json

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,8 @@
11
{
2-
"extends": [
3-
"@ht2-labs:base"
4-
],
2+
"enabled": false,
3+
"extends": ["@ht2-labs:base"],
54
"lockFileMaintenance": {
65
"enabled": true,
7-
"schedule": [
8-
"before 5am on monday"
9-
]
6+
"schedule": ["before 5am on monday"]
107
}
11-
}
8+
}

0 commit comments

Comments
 (0)