langgenius/dify · error · NotFoundError
variable not found, id={variable_id_str}
Error message
variable not found, id={variable_id_str} What it means
Error "variable not found, id={variable_id_str}" thrown in langgenius/dify.
Source
Thrown at api/controllers/console/datasets/rag_pipeline/rag_pipeline_draft_variable.py:190
return Response("", 204)
@console_ns.route("/rag/pipelines/<uuid:pipeline_id>/workflows/draft/variables/<uuid:variable_id>")
class RagPipelineVariableApi(Resource):
_PATCH_NAME_FIELD = "name"
_PATCH_VALUE_FIELD = "value"
@console_ns.response(200, "Variable retrieved successfully", workflow_draft_variable_model)
@_api_prerequisite
@marshal_with(workflow_draft_variable_model)
def get(self, _current_user: Account, pipeline: Pipeline, variable_id: UUID):
draft_var_srv = WorkflowDraftVariableService(
session=db.session(),
)
variable_id_str = str(variable_id)
variable = draft_var_srv.get_variable(variable_id=variable_id_str)
if variable is None:
raise NotFoundError(description=f"variable not found, id={variable_id_str}")
if variable.app_id != pipeline.id:
raise NotFoundError(description=f"variable not found, id={variable_id_str}")
return variable
@console_ns.response(200, "Variable updated successfully", workflow_draft_variable_model)
@_api_prerequisite
@marshal_with(workflow_draft_variable_model)
@console_ns.expect(console_ns.models[WorkflowDraftVariablePatchPayload.__name__])
@model_validate(WorkflowDraftVariablePatchPayload)
def patch(
self,
req_data: WorkflowDraftVariablePatchPayload,
_current_user: Account,
pipeline: Pipeline,
variable_id: UUID,
):
# Request payload for file types:
#View on GitHub (pinned to ef8544b173)
When it happens
Trigger: Thrown at api/controllers/console/datasets/rag_pipeline/rag_pipeline_draft_variable.py:190 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of langgenius/dify@ef8544b173 (2026-08-12).
Data as JSON: /api/errors/61c49ea9f9a79f15.
Report an issue: GitHub.