snyk 1.768.0 → 1.769.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.
@@ -491,21 +491,6 @@ class JsonTestCommandResult extends TestCommandResult {
491
491
  }
492
492
 
493
493
 
494
- /***/ }),
495
-
496
- /***/ 70527:
497
- /***/ ((__unused_webpack_module, exports) => {
498
-
499
- "use strict";
500
-
501
- Object.defineProperty(exports, "__esModule", ({ value: true }));
502
- exports.sleep = void 0;
503
- async function sleep(ms) {
504
- return new Promise((resolve) => setTimeout(resolve, ms));
505
- }
506
- exports.sleep = sleep;
507
-
508
-
509
494
  /***/ }),
510
495
 
511
496
  /***/ 65623:
@@ -1466,17 +1451,17 @@ Object.defineProperty(exports, "createDockerBinaryHeading", ({ enumerable: true,
1466
1451
  /***/ }),
1467
1452
 
1468
1453
  /***/ 13232:
1469
- /***/ ((__unused_webpack_module, exports) => {
1454
+ /***/ ((__unused_webpack_module, exports, __webpack_require__) => {
1470
1455
 
1471
1456
  "use strict";
1472
1457
 
1473
1458
  Object.defineProperty(exports, "__esModule", ({ value: true }));
1474
1459
  exports.summariseErrorResults = void 0;
1460
+ const errors_1 = __webpack_require__(55191);
1475
1461
  function summariseErrorResults(errorResultsLength) {
1476
1462
  const projects = errorResultsLength > 1 ? 'projects' : 'project';
1477
1463
  if (errorResultsLength > 0) {
1478
- return (` Failed to test ${errorResultsLength} ${projects}.\n` +
1479
- 'Run with `-d` for debug output and contact support@snyk.io');
1464
+ return errors_1.errorMessageWithRetry(` Failed to test ${errorResultsLength} ${projects}.`);
1480
1465
  }
1481
1466
  return '';
1482
1467
  }
@@ -3328,7 +3313,7 @@ async function monitorDepTree(root, meta, scannedProject, pluginMeta, options, t
3328
3313
  let depTree = scannedProject.depTree;
3329
3314
  if (!depTree) {
3330
3315
  debug('scannedProject is missing depGraph or depTree, cannot run test/monitor');
3331
- throw new errors_1.FailedToRunTestError('Your monitor request could not be completed. Please email support@snyk.io');
3316
+ throw new errors_1.FailedToRunTestError(errors_1.errorMessageWithRetry('Your monitor request could not be completed.'));
3332
3317
  }
3333
3318
  let prePruneDepCount;
3334
3319
  if (meta.prune) {
@@ -3381,7 +3366,7 @@ async function monitorDepTree(root, meta, scannedProject, pluginMeta, options, t
3381
3366
  }
3382
3367
  if (!depTree) {
3383
3368
  debug('scannedProject is missing depGraph or depTree, cannot run test/monitor');
3384
- throw new errors_1.FailedToRunTestError('Your monitor request could not be completed. Please email support@snyk.io');
3369
+ throw new errors_1.FailedToRunTestError(errors_1.errorMessageWithRetry('Your monitor request could not be completed.'));
3385
3370
  }
3386
3371
  const { res, body } = await request_1.makeRequest({
3387
3372
  body: {
@@ -3454,7 +3439,7 @@ async function monitorDepGraph(root, meta, scannedProject, pluginMeta, options,
3454
3439
  let depGraph = scannedProject.depGraph;
3455
3440
  if (!depGraph) {
3456
3441
  debug('scannedProject is missing depGraph or depTree, cannot run test/monitor');
3457
- throw new errors_1.FailedToRunTestError('Your monitor request could not be completed. Please email support@snyk.io');
3442
+ throw new errors_1.FailedToRunTestError('Your monitor request could not be completed. ');
3458
3443
  }
3459
3444
  let targetFileDir;
3460
3445
  if (targetFileRelativePath) {
@@ -3493,7 +3478,7 @@ async function monitorDepGraph(root, meta, scannedProject, pluginMeta, options,
3493
3478
  }
3494
3479
  if (!depGraph) {
3495
3480
  debug('scannedProject is missing depGraph or depTree, cannot run test/monitor');
3496
- throw new errors_1.FailedToRunTestError('Your monitor request could not be completed. Please email support@snyk.io');
3481
+ throw new errors_1.FailedToRunTestError(errors_1.errorMessageWithRetry('Your monitor request could not be completed.'));
3497
3482
  }
3498
3483
  const { res, body } = await request_1.makeRequest({
3499
3484
  body: {
@@ -3557,7 +3542,7 @@ async function monitorDepGraphFromDepTree(root, meta, scannedProject, pluginMeta
3557
3542
  let depTree = scannedProject.depTree;
3558
3543
  if (!depTree) {
3559
3544
  debug('scannedProject is missing depGraph or depTree, cannot run test/monitor');
3560
- throw new errors_1.FailedToRunTestError('Your monitor request could not be completed. Please email support@snyk.io');
3545
+ throw new errors_1.FailedToRunTestError(errors_1.errorMessageWithRetry('Your monitor request could not be completed'));
3561
3546
  }
3562
3547
  let targetFileDir;
3563
3548
  if (targetFileRelativePath) {
@@ -3588,7 +3573,7 @@ async function monitorDepGraphFromDepTree(root, meta, scannedProject, pluginMeta
3588
3573
  }
3589
3574
  if (!depTree) {
3590
3575
  debug('scannedProject is missing depGraph or depTree, cannot run test/monitor');
3591
- throw new errors_1.FailedToRunTestError('Your monitor request could not be completed. Please email support@snyk.io');
3576
+ throw new errors_1.FailedToRunTestError(errors_1.errorMessageWithRetry('Your monitor request could not be completed.'));
3592
3577
  }
3593
3578
  const { res, body } = await request_1.makeRequest({
3594
3579
  body: {
@@ -4103,7 +4088,7 @@ async function getMultiPluginResult(root, options, targetFiles) {
4103
4088
  }
4104
4089
  }
4105
4090
  if (!allResults.length) {
4106
- throw new errors_1.FailedToRunTestError(`Failed to get dependencies for all ${targetFiles.length} potential projects. Run with \`-d\` for debug output and contact support@snyk.io`);
4091
+ throw new errors_1.FailedToRunTestError(errors_1.errorMessageWithRetry(`Failed to get dependencies for all ${targetFiles.length} potential projects.`));
4107
4092
  }
4108
4093
  return {
4109
4094
  plugin: {
@@ -6508,7 +6493,7 @@ async function assembleLocalPayloads(root, options) {
6508
6493
  for (const scannedProject of deps.scannedProjects) {
6509
6494
  if (!scannedProject.depTree && !scannedProject.depGraph) {
6510
6495
  debug('scannedProject is missing depGraph or depTree, cannot run test/monitor');
6511
- throw new errors_1.FailedToRunTestError('Your test request could not be completed. Please email support@snyk.io');
6496
+ throw new errors_1.FailedToRunTestError(errors_1.errorMessageWithRetry('Your test request could not be completed.'));
6512
6497
  }
6513
6498
  // prefer dep-graph fallback on dep tree
6514
6499
  // TODO: clean up once dep-graphs only