feat(api): adjust model fields and cleanup form creation logic

This commit is contained in:
QuantumGhost
2026-01-08 10:27:52 +08:00
parent de428bc9bb
commit f988619d2c
14 changed files with 60 additions and 11 deletions

View File

@ -299,6 +299,7 @@ class WorkflowResponseConverter:
form_content=reason.form_content,
inputs=reason.inputs,
actions=reason.actions,
display_in_ui=reason.display_in_ui,
form_token=reason.form_token,
resolved_placeholder_values=reason.resolved_placeholder_values,
),

View File

@ -326,6 +326,8 @@ def _topic_msg_generator(
) -> Generator[Mapping[str, Any], None, None]:
last_msg_time = time.time()
with topic.subscribe() as sub:
# on_subscribe fires only after the Redis subscription is active.
# This is used to gate task start and reduce pub/sub race for the first event.
if on_subscribe is not None:
on_subscribe()
while True:

View File

@ -44,6 +44,8 @@ def _topic_msg_generator(
) -> Generator[Mapping[str, Any], None, None]:
last_msg_time = time.time()
with topic.subscribe() as sub:
# on_subscribe fires only after the Redis subscription is active.
# This is used to gate task start and reduce pub/sub race for the first event.
if on_subscribe is not None:
on_subscribe()
while True: