Opus finding
`do_nothing` handler signature mismatches BasePlatform dispatch contract — will crash dispatcher with annotated agent_id
mediumbughigh
- backend/wonderwall/simulations/base.py:233-236
- backend/wonderwall/simulations/base.py:175-195
BaseAction.do_nothing calls `await self.perform_action(None, "do_nothing")`. On platform side, `do_nothing(self, agent_id)` has 2 params (self+agent_id) → len_param_names=2 → dispatcher passes only `agent_id`. That's fine. But agent-side `BaseAction.do_nothing` sends message=None; if a subclass overrides to take `(self, agent_id, message)` they need to expect message=None. Looks OK. However, this is a fragile contract — the dispatcher silently drops the second tuple element. Combined with the >3 param hard rejection, this dispatcher is brittle.
Recommendation
Document and unit-test the platform handler signature contract clearly. Consider a typed decorator or explicit registry instead of introspection.