@argos-ci/core 0.1.0 → 0.2.0

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.
Files changed (2) hide show
  1. package/dist/index.mjs +7 -1
  2. package/package.json +2 -2
package/dist/index.mjs CHANGED
@@ -239,6 +239,12 @@ const createArgosApiClient = (options)=>{
239
239
  });
240
240
  return response.data;
241
241
  } catch (error) {
242
+ if (error?.response?.data?.error?.message) {
243
+ // @ts-ignore
244
+ throw new Error(error.response.data.error.message, {
245
+ cause: error
246
+ });
247
+ }
242
248
  throw error;
243
249
  }
244
250
  };
@@ -328,7 +334,7 @@ const getConfigFromOptions = (options)=>{
328
334
  name: config.buildName,
329
335
  parallel: config.parallel,
330
336
  parallelNonce: config.parallelNonce,
331
- screenshotKeys: screenshots.map((screenshot)=>screenshot.hash)
337
+ screenshotKeys: Array.from(new Set(screenshots.map((screenshot)=>screenshot.hash)))
332
338
  });
333
339
  debug("Got screenshots", result);
334
340
  // Upload screenshots
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@argos-ci/core",
3
3
  "description": "Visual testing solution to avoid visual regression. The core component of Argos SDK that handles build creation.",
4
- "version": "0.1.0",
4
+ "version": "0.2.0",
5
5
  "scripts": {
6
6
  "prebuild": "rm -rf dist",
7
7
  "build": "rollup -c",
@@ -60,5 +60,5 @@
60
60
  "rollup-plugin-dts": "^4.2.2",
61
61
  "rollup-plugin-swc3": "^0.3.0"
62
62
  },
63
- "gitHead": "ff22c7f1ecf8cbbd1468440b3247d10b3b7b7310"
63
+ "gitHead": "5702f6d5dd18b3e783a7936270e191c999751875"
64
64
  }