@friggframework/core 1.1.3--canary.296.b068936.0 → 1.1.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,3 +1,30 @@
1
+ # v1.1.4 (Fri Apr 05 2024)
2
+
3
+ #### 🐛 Bug Fix
4
+
5
+ - Socket hang up / ECONNRESET error retry for requester [#297](https://github.com/friggframework/frigg/pull/297) ([@seanspeaks](https://github.com/seanspeaks))
6
+ - Check linear task description for offending error. Unclear if this is the best approach. ([@seanspeaks](https://github.com/seanspeaks))
7
+
8
+ #### Authors: 1
9
+
10
+ - Sean Matthews ([@seanspeaks](https://github.com/seanspeaks))
11
+
12
+ ---
13
+
14
+ # v1.1.3 (Tue Apr 02 2024)
15
+
16
+ #### 🐛 Bug Fix
17
+
18
+ - test release [#296](https://github.com/friggframework/frigg/pull/296) ([@MichaelRyanWebber](https://github.com/MichaelRyanWebber))
19
+ - add a commit to fix canary and workaround auto bug ([@MichaelRyanWebber](https://github.com/MichaelRyanWebber))
20
+ - bump to test release ([@MichaelRyanWebber](https://github.com/MichaelRyanWebber))
21
+
22
+ #### Authors: 1
23
+
24
+ - [@MichaelRyanWebber](https://github.com/MichaelRyanWebber)
25
+
26
+ ---
27
+
1
28
  # v2.0.0 (Sat Mar 30 2024)
2
29
 
3
30
  #### 🚀 Enhancement
@@ -48,7 +48,21 @@ class Requester extends Delegate {
48
48
 
49
49
  if (this.agent) options.agent = this.agent;
50
50
 
51
- const response = await this.fetch(encodedUrl, options);
51
+ let response;
52
+ try {
53
+ response = await this.fetch(encodedUrl, options);
54
+ } catch (e) {
55
+ if (e.code === 'ECONNRESET' && i < this.backOff.length) {
56
+ const delay = this.backOff[i] * 1000;
57
+ await new Promise((resolve) => setTimeout(resolve, delay));
58
+ return this._request(url, options, i + 1);
59
+ }
60
+ throw await FetchError.create({
61
+ resource: encodedUrl,
62
+ init: options,
63
+ responseBody: e,
64
+ });
65
+ }
52
66
  const { status } = response;
53
67
 
54
68
  // If the status is retriable and there are back off requests left, retry the request
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@friggframework/core",
3
3
  "prettier": "@friggframework/prettier-config",
4
- "version": "1.1.3--canary.296.b068936.0",
4
+ "version": "1.1.4",
5
5
  "dependencies": {
6
6
  "@hapi/boom": "^10.0.1",
7
7
  "aws-sdk": "^2.1200.0",
@@ -15,9 +15,9 @@
15
15
  "node-fetch": "^2.6.7"
16
16
  },
17
17
  "devDependencies": {
18
- "@friggframework/eslint-config": "1.1.3--canary.296.b068936.0",
19
- "@friggframework/prettier-config": "1.1.3--canary.296.b068936.0",
20
- "@friggframework/test": "1.1.3--canary.296.b068936.0",
18
+ "@friggframework/eslint-config": "^1.1.4",
19
+ "@friggframework/prettier-config": "^1.1.4",
20
+ "@friggframework/test": "^1.1.4",
21
21
  "@types/lodash": "^4.14.191",
22
22
  "@typescript-eslint/eslint-plugin": "^5.55.0",
23
23
  "chai": "^4.3.6",
@@ -49,5 +49,5 @@
49
49
  },
50
50
  "homepage": "https://github.com/friggframework/frigg#readme",
51
51
  "description": "",
52
- "gitHead": "b0689366e283ca192f43cb6d03e0181bd3bb11c3"
52
+ "gitHead": "29600061d60d711eaf83ca7016f18949e67f0c8c"
53
53
  }