onshape 0.1.3 → 0.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.
@@ -4,8 +4,8 @@ exports.OnshapeClient = exports.HttpError = void 0;
4
4
  const node_url_1 = require("node:url");
5
5
  const promises_1 = require("node:timers/promises");
6
6
  const READ_RETRY_STATUSES = new Set([408, 429, 500, 502, 503, 504]);
7
- const MAX_READ_ATTEMPTS = 5;
8
- const MAX_RETRY_DELAY_MS = 10_000;
7
+ const MAX_READ_ATTEMPTS = 8;
8
+ const MAX_RETRY_DELAY_MS = 30_000;
9
9
  class HttpError extends Error {
10
10
  status;
11
11
  detail;
@@ -117,5 +117,5 @@ function retryDelayMs(response, attempt) {
117
117
  return Math.min(Math.max(dateMs - Date.now(), 0), MAX_RETRY_DELAY_MS);
118
118
  }
119
119
  }
120
- return Math.min(500 * 2 ** (attempt - 1), MAX_RETRY_DELAY_MS);
120
+ return Math.min(1000 * 2 ** (attempt - 1), MAX_RETRY_DELAY_MS);
121
121
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "onshape",
3
- "version": "0.1.3",
3
+ "version": "0.1.4",
4
4
  "description": "Node.js CLI for Onshape CAD automation with the same JSON contract as onshape-cli.",
5
5
  "license": "MIT",
6
6
  "type": "commonjs",