fix pylint

This commit is contained in:
geekan 2024-01-15 23:12:09 +08:00
parent b0af1e88ac
commit 7005a1e86f

View file

@ -481,6 +481,8 @@ class Role(SerializationMixin, ContextMixin, BaseModel):
rsp = await self._act_by_order()
elif self.rc.react_mode == RoleReactMode.PLAN_AND_ACT:
rsp = await self._plan_and_act()
else:
raise ValueError(f"Unsupported react mode: {self.rc.react_mode}")
self._set_state(state=-1) # current reaction is complete, reset state to -1 and todo back to None
return rsp