TRY and THROW nodes provide error handling capabilities, allowing you to catch errors and throw custom errors in flows.Documentation Index
Fetch the complete documentation index at: https://hypha-docs.plinqx.app/llms.txt
Use this file to discover all available pages before exploring further.
TRY Node
The TRY node implements try-catch-finally error handling:- Try Block: Execute nodes that may fail
- Catch Block: Handle errors from try block
- Finally Block: Always execute (cleanup, logging)
How TRY Works
Configuration
Try Block
Define nodes to execute in try block:- Subgraph: Nodes that may throw errors
- Error Handling: Errors caught automatically
- Error Access: Access error details in catch block
Catch Block
Handle errors from try block:- Error Access: Access error details
- Error Handling: Log, transform, or recover from errors
- Flow Continuation: Decide whether to continue or fail
Finally Block
Always execute (optional):- Cleanup: Cleanup operations
- Logging: Log execution details
- Resource Release: Release resources
Error Details
Access error details in catch block:THROW Node
The THROW node throws custom errors:- Error Code: Custom error code
- Error Message: Descriptive error message
- Error Details: Additional error context
Configuration
Error Definition
Define error to throw:- Code: Error code identifier
- Message: Human-readable error message
- Details: Additional error context (optional)
Use Cases
Error Recovery
Use TRY to recover from errors:Error Validation
Validate data and throw on invalid:Error Logging
Log errors before rethrowing:Best Practices
Specific Errors
Throw specific error codes for different scenarios
Error Messages
Provide clear, actionable error messages
Error Context
Include relevant context in error details
Error Handling
Always handle errors appropriately
Next Steps
LOG Node
Log errors and execution details
VALIDATE Node
Validate data before operations