Build Agentic workflows, RAG pipelines, with rich AI model and tool support on one collaborative workspace. Deploy on cloud, VPC, or self-hosted, so teams move from prototype to production without rebuilding the stack.
Python agentagentic-aiagentic-frameworkagentic-workflowaiautomationclaudedeepseekgenaigptllmlow-codemcpnextjsno-codeopenaipythonskillsworkflow
feat: add NotFound error for dataset service (#9215)
crazywoolae0c8189f1ab6
diff --git a/api/services/dataset_service.py b/api/services/dataset_service.pyindex b8f80a9f77e..4f77fdc18cb 100644--- a/api/services/dataset_service.py+++ b/api/services/dataset_service.py@@ -8,6 +8,7 @@ from typing import Optionalfrom flask_login import current_userfrom sqlalchemy import func+from werkzeug.exceptions import NotFoundfrom configs import dify_configfrom core.errors.error import LLMBadRequestError, ProviderTokenNotInitError@@ -975,6 +976,8 @@ class DocumentService:):DatasetService.check_dataset_model_setting(dataset)document = DocumentService.get_document(dataset.id, document_data["original_document_id"])+ if document is None:+ raise NotFound("Document not found")if document.display_status != "available":raise ValueError("Document is not available")# update document name