URL/Location
https://github.com/aws/aws-durable-execution-docs/blob/main/aws-lambda-durable-functions-power/steering/error-handling.md#unrecoverable-errors
Describe What's Incorrect or Lacking
error-handling.md shows this example:
import { UnrecoverableInvocationError } from '@aws/durable-execution-sdk-js';
throw new UnrecoverableInvocationError('User not found');
This causes a TypeScript compile error:
Module '@aws/durable-execution-sdk-js' has no exported member 'UnrecoverableInvocationError'
Root Cause
UnrecoverableInvocationError is defined internally in the SDK, but:
- It is abstract, hence cannot be instantiated
- It is not exported from index.ts and is not part of the public API
Suggested Improvement
Until the SDK exports a public equivalent, the TypeScript example should either:
- Be removed and replaced with a note that TypeScript currently has no direct equivalent. Raised a feature request in the SDK.
- Show the workaround using retryStrategy: () => ({ shouldRetry: false })
URL/Location
https://github.com/aws/aws-durable-execution-docs/blob/main/aws-lambda-durable-functions-power/steering/error-handling.md#unrecoverable-errors
Describe What's Incorrect or Lacking
error-handling.mdshows this example:This causes a TypeScript compile error:
Root Cause
UnrecoverableInvocationError is defined internally in the SDK, but:
Suggested Improvement
Until the SDK exports a public equivalent, the TypeScript example should either: