@hatchet-dev/typescript-sdk 1.10.5 → 1.10.6

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hatchet-dev/typescript-sdk",
3
- "version": "1.10.5",
3
+ "version": "1.10.6",
4
4
  "description": "Background task orchestration & visibility for developers",
5
5
  "types": "dist/index.d.ts",
6
6
  "files": [
@@ -62,7 +62,7 @@
62
62
  "nice-grpc": "^2.1.12",
63
63
  "nice-grpc-common": "^2.0.2",
64
64
  "protobufjs": "^7.4.0",
65
- "qs": "^6.14.0",
65
+ "qs": "^6.14.1",
66
66
  "semver": "^7.7.1",
67
67
  "yaml": "^2.7.1",
68
68
  "zod": "^3.24.2"
@@ -410,8 +410,11 @@ class V1Worker {
410
410
  return step(context);
411
411
  });
412
412
  const success = (result) => __awaiter(this, void 0, void 0, function* () {
413
- this.logger.info(`Step run ${action.stepRunId} succeeded`);
414
413
  try {
414
+ if (context.cancelled) {
415
+ return;
416
+ }
417
+ this.logger.info(`Step run ${action.stepRunId} succeeded`);
415
418
  // Send the action event to the dispatcher
416
419
  const event = this.getStepActionEvent(action, dispatcher_1.StepActionEventType.STEP_EVENT_TYPE_COMPLETED, false, result || null, action.retryCount);
417
420
  yield this.client._v0.dispatcher.sendStepActionEvent(event);
@@ -435,12 +438,15 @@ class V1Worker {
435
438
  }
436
439
  });
437
440
  const failure = (error) => __awaiter(this, void 0, void 0, function* () {
438
- this.logger.error(`Step run ${action.stepRunId} failed: ${error.message}`);
439
- if (error.stack) {
440
- this.logger.error(error.stack);
441
- }
442
441
  const shouldNotRetry = error instanceof task_1.NonRetryableError;
443
442
  try {
443
+ if (context.cancelled) {
444
+ return;
445
+ }
446
+ this.logger.error(`Step run ${action.stepRunId} failed: ${error.message}`);
447
+ if (error.stack) {
448
+ this.logger.error(error.stack);
449
+ }
444
450
  // Send the action event to the dispatcher
445
451
  const event = this.getStepActionEvent(action, dispatcher_1.StepActionEventType.STEP_EVENT_TYPE_FAILED, shouldNotRetry, {
446
452
  message: error === null || error === void 0 ? void 0 : error.message,
package/version.d.ts CHANGED
@@ -1 +1 @@
1
- export declare const HATCHET_VERSION = "1.10.5";
1
+ export declare const HATCHET_VERSION = "1.10.6";
package/version.js CHANGED
@@ -1,4 +1,4 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.HATCHET_VERSION = void 0;
4
- exports.HATCHET_VERSION = '1.10.5';
4
+ exports.HATCHET_VERSION = '1.10.6';