Skip to content

fix(core): do not re-enter lifecycle from a failed outcome - #98

Open
justkyriecai wants to merge 1 commit into
cordiverse:mainfrom
justkyriecai:fix/failed-fiber-reload-reentry
Open

fix(core): do not re-enter lifecycle from a failed outcome#98
justkyriecai wants to merge 1 commit into
cordiverse:mainfrom
justkyriecai:fix/failed-fiber-reload-reentry

Conversation

@justkyriecai

Copy link
Copy Markdown

fix #95

After a plugin fails, a dependency refresh can make the target satisfiable again and start _reload() while _error is still set, so the body runs again but the fiber keeps reporting FAILED. Skip epoch-driven lifecycle transitions while failed; update() clears _error and restarts.

@justkyriecai

Copy link
Copy Markdown
Author

for the reason that cordis is vendored into dsh, and fiber state feeds the core agent loop, when a FAILED fiber silently rerun its plugin body means duplicate registrations and side effects while the agent keeps seeing FAILED.

Like a wrong state and phantom execution.
I just hardened that. Also test all pass.

Request to merge. Love to contribute.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

FAILED Fiber re-enters _reload() on dependency refresh while retaining _error

1 participant