mirror of
https://github.com/infiniflow/ragflow.git
synced 2026-11-10 21:32:43 +08:00
fix(sdk): reject conflicting dataset ID filters (#19047)
Python SDK list_datasets now rejects both id and ids together (client-side), matching server and list_documents. Co-authored-by: root <kinsonnee@gmail.com>
This commit is contained in:
1 parent
8347d1c566
commit
480a4e436c
2 files changed
+52
No files matched your search
@@ -98,6 +98,9 @@ class RAGFlow:
|
||||
def list_datasets(
|
||||
self, page: int = 1, page_size: int = 30, orderby: str = "create_time", desc: bool = True, id: str | None = None, ids: list[str] | None = None, name: str | None = None
|
||||
) -> list[DataSet]:
|
||||
if id and ids:
|
||||
raise ValueError("Cannot use both 'id' and 'ids' parameters at the same time.")
|
||||
|
||||
res = self.get(
|
||||
"/datasets",
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user