Fix component input error. (#4231)

### What problem does this PR solve?

#4108

### Type of change

- [x] Bug Fix (non-breaking change which fixes an issue)
This commit is contained in:
Kevin Hu 2024-12-26 10:13:47 +08:00 committed by GitHub
parent 85511cb1fd
commit 28eeb29b88
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -480,7 +480,8 @@ class ComponentBase(ABC):
if q["component_id"].lower().find("answer") == 0:
for r, c in self._canvas.history[::-1]:
if r == "user":
self._param.inputs.append(pd.DataFrame([{"content": c, "component_id": q["component_id"]}]))
self._param.inputs.append({"content": c, "component_id": q["component_id"]})
outs.append(pd.DataFrame([{"content": c}]))
break
continue