fix(controller): "agent task already running" (#1516)
* fix agent task already running bug
* attemp to fix "Current task state not recognized"
* Revert "attemp to fix "Current task state not recognized""
This reverts commit f5cbfe1ebba3f9ed9d9ee8f47d228e2d0117347a.
---------
Co-authored-by: Leo <ifuryst@gmail.com>