@sentry/bundler-plugin-core 3.1.1 → 3.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.
package/dist/cjs/index.js CHANGED
@@ -8111,7 +8111,7 @@ function createSentryInstance(options, shouldSendTelemetry, bundler) {
8111
8111
  dsn: "https://4c2bae7d9fbc413e8f7385f55c515d51@o1.ingest.sentry.io/6690737",
8112
8112
  tracesSampleRate: 1,
8113
8113
  sampleRate: 1,
8114
- release: "3.1.1",
8114
+ release: "3.2.0",
8115
8115
  integrations: [],
8116
8116
  tracePropagationTargets: ["sentry.io/api"],
8117
8117
  stackParser: stackParser,
@@ -8999,30 +8999,34 @@ function fileDeletionPlugin(_ref) {
8999
8999
  name: "sentry-file-deletion-plugin",
9000
9000
  writeBundle: function writeBundle() {
9001
9001
  return _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
9002
- var filePathsToDelete;
9002
+ var filesToDelete, filePathsToDelete;
9003
9003
  return _regeneratorRuntime().wrap(function _callee$(_context) {
9004
9004
  while (1) switch (_context.prev = _context.next) {
9005
9005
  case 0:
9006
9006
  _context.prev = 0;
9007
- if (!(filesToDeleteAfterUpload !== undefined)) {
9008
- _context.next = 11;
9007
+ _context.next = 3;
9008
+ return filesToDeleteAfterUpload;
9009
+ case 3:
9010
+ filesToDelete = _context.sent;
9011
+ if (!(filesToDelete !== undefined)) {
9012
+ _context.next = 14;
9009
9013
  break;
9010
9014
  }
9011
- _context.next = 4;
9012
- return glob.glob(filesToDeleteAfterUpload, {
9015
+ _context.next = 7;
9016
+ return glob.glob(filesToDelete, {
9013
9017
  absolute: true,
9014
9018
  nodir: true
9015
9019
  });
9016
- case 4:
9020
+ case 7:
9017
9021
  filePathsToDelete = _context.sent;
9018
9022
  logger.debug("Waiting for dependencies on generated files to be freed before deleting...");
9019
- _context.next = 8;
9023
+ _context.next = 11;
9020
9024
  return waitUntilSourcemapFileDependenciesAreFreed();
9021
- case 8:
9025
+ case 11:
9022
9026
  filePathsToDelete.forEach(function (filePathToDelete) {
9023
9027
  logger.debug("Deleting asset after upload: ".concat(filePathToDelete));
9024
9028
  });
9025
- _context.next = 11;
9029
+ _context.next = 14;
9026
9030
  return Promise.all(filePathsToDelete.map(function (filePathToDelete) {
9027
9031
  return fs__default["default"].promises.rm(filePathToDelete, {
9028
9032
  force: true
@@ -9031,22 +9035,22 @@ function fileDeletionPlugin(_ref) {
9031
9035
  logger.debug("An error occurred while attempting to delete asset: ".concat(filePathToDelete), e);
9032
9036
  });
9033
9037
  }));
9034
- case 11:
9035
- _context.next = 19;
9038
+ case 14:
9039
+ _context.next = 22;
9036
9040
  break;
9037
- case 13:
9038
- _context.prev = 13;
9041
+ case 16:
9042
+ _context.prev = 16;
9039
9043
  _context.t0 = _context["catch"](0);
9040
9044
  sentryScope.captureException('Error in "sentry-file-deletion-plugin" buildEnd hook');
9041
- _context.next = 18;
9045
+ _context.next = 21;
9042
9046
  return safeFlushTelemetry(sentryClient);
9043
- case 18:
9047
+ case 21:
9044
9048
  handleRecoverableError(_context.t0);
9045
- case 19:
9049
+ case 22:
9046
9050
  case "end":
9047
9051
  return _context.stop();
9048
9052
  }
9049
- }, _callee, null, [[0, 13]]);
9053
+ }, _callee, null, [[0, 16]]);
9050
9054
  }))();
9051
9055
  }
9052
9056
  };
@@ -9152,7 +9156,7 @@ function sentryUnpluginFactory(_ref) {
9152
9156
  });
9153
9157
 
9154
9158
  // Set the User-Agent that Sentry CLI will use when interacting with Sentry
9155
- process.env["SENTRY_PIPELINE"] = "".concat(unpluginMetaContext.framework, "-plugin/", "3.1.1");
9159
+ process.env["SENTRY_PIPELINE"] = "".concat(unpluginMetaContext.framework, "-plugin/", "3.2.0");
9156
9160
  function handleRecoverableError(unknownError) {
9157
9161
  sentrySession.status = "abnormal";
9158
9162
  try {