Repository navigation
fix(executor): stop persisting runtime running state - #2310
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (6)
🚧 Files skipped from review as they are similar to previous changes (5)
📝 WalkthroughWalkthrough
ChangesRuntime running-state contract
Estimated code review effort: 2 (Simple) | ~10 minutes Possibly related PRs
Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
c523e4d to
74ae78f
Compare
74ae78f to
78c5472
Compare
What changed
RuntimeTaskLink.runningfrom serialization and deserializationrunningvalues instead of treating them as executor stateWhy
The runtime-work index persisted the same
runningfield that is returned by the runtime API. When a release Wework process and a dev process shared one executor home, each process had an independent active-task set but read and wrote the sameruntime-work/index.json. A process that did not own another process's task could therefore rewrite its running state.runningis process-owned execution state. It must come only from the current executor's active-task set and must never be restored from disk.Compatibility
There is intentionally no migration or fallback path. Older
runningfields are ignored on read, and all new writes omit the field.Validation
cargo fmt --all -- --checkcargo test -p wegent-executor --lib runtime_task_link_does_not_persist_running_statecargo test -p wegent-executor --test app_runtime_work_native_update_contractcargo test --all-features --libcargo clippypnpm --filter wework ai:verify start; verified the local executor connected and the workbench loaded, then stopped and cleaned the sessionSummary by CodeRabbit
runningstate is no longer persisted, so task listings now reflect the currently active executor state.runningflag are ignored to prevent stale “running” indicators.runningis determined and what runtime data is retained.