We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6764937 commit 89491a8Copy full SHA for 89491a8
backend/apps/chat/curd/chat.py
@@ -701,7 +701,7 @@ def get_old_questions(session: SessionDep, datasource: int):
701
if not datasource:
702
return records
703
stmt = select(ChatRecord.question).where(
704
- and_(ChatRecord.datasource == datasource, ChatRecord.question.isnot(None))).order_by(
+ and_(ChatRecord.datasource == datasource, ChatRecord.question.isnot(None), ChatRecord.error.is_(None))).order_by(
705
ChatRecord.create_time.desc()).limit(20)
706
result = session.execute(stmt)
707
for r in result:
0 commit comments