Spaces:
Running
Running
Download src/backend/base/langflow/exceptions/component.py from opendigital/agent-flow: direct link, hf CLI and curl.
- Browser
- Download file 534 Bytes
-
https://huggingface.co/spaces/opendigital/agent-flow/resolve/main/src/backend/base/langflow/exceptions/component.py
- Command line
-
hf download hf://spaces/opendigital/agent-flow/src/backend/base/langflow/exceptions/component.py
-
curl -L -o component.py https://huggingface.co/spaces/opendigital/agent-flow/resolve/main/src/backend/base/langflow/exceptions/component.py
534 Bytes
| # Create an exception class that receives the message and the formatted traceback | |
| from langflow.schema.properties import Source | |
| class ComponentBuildError(Exception): | |
| def __init__(self, message: str, formatted_traceback: str): | |
| self.message = message | |
| self.formatted_traceback = formatted_traceback | |
| super().__init__(message) | |
| class StreamingError(Exception): | |
| def __init__(self, cause: Exception, source: Source): | |
| self.cause = cause | |
| self.source = source | |
| super().__init__(cause) | |