Skip to content
Snippets Groups Projects
Unverified Commit 1115f83b authored by Emanuel Ferreira's avatar Emanuel Ferreira Committed by GitHub
Browse files

fix: pipeline not found (#672)

parent 60a16036
No related branches found
No related tags found
No related merge requests found
---
"llamaindex": patch
---
fix: throw error when no pipelines exist for the retriever
...@@ -65,7 +65,7 @@ export class LlamaCloudRetriever implements BaseRetriever { ...@@ -65,7 +65,7 @@ export class LlamaCloudRetriever implements BaseRetriever {
projectName: this.projectName, projectName: this.projectName,
pipelineName: this.pipelineName, pipelineName: this.pipelineName,
}); });
if (pipelines.length !== 1 && !pipelines[0].id) { if (pipelines.length !== 1 && !pipelines[0]?.id) {
throw new Error( throw new Error(
`No pipeline found with name ${this.pipelineName} in project ${this.projectName}`, `No pipeline found with name ${this.pipelineName} in project ${this.projectName}`,
); );
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment