mirror of
https://git.mirrors.martin98.com/https://github.com/langgenius/dify.git
synced 2025-08-15 08:16:01 +08:00
unify moderation and annotation's response behavior in message log of chatflow app with other types of app (#14800)
This commit is contained in:
parent
43ab7c22a7
commit
f0fb38fed4
@ -582,6 +582,15 @@ class AdvancedChatAppGenerateTaskPipeline:
|
|||||||
session.commit()
|
session.commit()
|
||||||
|
|
||||||
yield workflow_finish_resp
|
yield workflow_finish_resp
|
||||||
|
elif event.stopped_by in (
|
||||||
|
QueueStopEvent.StopBy.INPUT_MODERATION,
|
||||||
|
QueueStopEvent.StopBy.ANNOTATION_REPLY,
|
||||||
|
):
|
||||||
|
# When hitting input-moderation or annotation-reply, the workflow will not start
|
||||||
|
with Session(db.engine, expire_on_commit=False) as session:
|
||||||
|
# Save message
|
||||||
|
self._save_message(session=session)
|
||||||
|
session.commit()
|
||||||
|
|
||||||
yield self._message_end_to_stream_response()
|
yield self._message_end_to_stream_response()
|
||||||
break
|
break
|
||||||
|
Loading…
x
Reference in New Issue
Block a user