Skip to content

Commit 56610bd

Browse files
authored
[Workflows] Clarify NonRetryableError information (cloudflare#26619)
[Workflows] Clarify NonRetryableError information
1 parent dde6527 commit 56610bd

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/content/docs/workflows/build/workers-api.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -156,8 +156,8 @@ Refer to the [documentation on sleeping and retrying](/workflows/build/sleeping-
156156

157157
{/* prettier-ignore */}
158158
- <code>throw new NonRetryableError(message: <Type text="string" />, name <Type text="string" /> <MetaInfo text="optional" />)</code>: <Type text="NonRetryableError" />
159-
- Throws an error that forces the current Workflow instance to fail and not be retried.
160-
- Refer to the [documentation on sleeping and retrying](/workflows/build/sleeping-and-retrying/) to learn more about how Workflows are retried.
159+
- When thrown inside [`step.do()`](/workflows/build/workers-api/#step), this error stops step retries, propagating the error to the top level (the [run](/workflows/build/workers-api/#run) function). Any error not handled at this top level will cause the Workflow instance to fail.
160+
- Refer to the [documentation on sleeping and retrying](/workflows/build/sleeping-and-retrying/) to learn more about how Workflows steps are retried.
161161

162162
## Call Workflows from Workers
163163

0 commit comments

Comments
 (0)