Skip to content

fix(assistant): advance Life Pulse periodic growth anchor - #151

Draft
cursor[bot] wants to merge 2 commits into
mainfrom
cursor/critical-bug-investigation-2846
Draft

cursor[bot] wants to merge 2 commits into
mainfrom
cursor/critical-bug-investigation-2846

Conversation

@cursor

@cursor cursor Bot commented Sep 4, 2026

Copy link
Copy Markdown

Summary

  • Desktop Life Pulse never advanced last_periodic_growth_unix, so inspect_growth_due treated every heartbeat as first-tick and the advertised periodic evolution arm never fired.
  • After a successful skilllite evolution status --json inspect, seed a missing anchor to now and refresh it when arm_periodic is true (including skipped no-proposal ticks), matching in-process growth_due.

Task Linkage

  • Task ID: TASK-2026-071
  • Task folder: tasks/TASK-2026-071-life-pulse-periodic-anchor/

Injected Specs

  • spec/architecture-boundaries.md (if architecture/layering changed)
  • spec/security-nonnegotiables.md (if sandbox/security changed)
  • spec/testing-policy.md (required for any code change)
  • spec/docs-sync.md (if behavior/docs/env/commands changed)

Also injected: spec/verification-integrity.md, spec/task-artifact-language.md, spec/rust-conventions.md.

Validation Evidence

  • Commands executed:
    • python3 scripts/validate_tasks.py
    • rustfmt --check --edition 2021 crates/skilllite-assistant/src-tauri/src/skilllite_bridge/integrations/evolution_ui/growth.rs
    • cargo fmt --check
    • cargo clippy --all-targets -- -D warnings
    • cargo test
    • cargo test --manifest-path crates/skilllite-assistant/src-tauri/Cargo.toml next_periodic_anchor
    • cargo test --manifest-path crates/skilllite-assistant/src-tauri/Cargo.toml should_spawn_growth
  • Key results:
    • Task validation: Task validation passed (71 task directories checked).
    • Workspace clippy/tests: exit 0
    • Targeted assistant tests: 6 passed (next_periodic_anchor_*, should_spawn_growth_*)

Regression Scope

Docs Sync (EN/ZH)

  • Not needed
  • Updated EN + ZH docs
  • Files:
    • Code now matches already-documented A9 periodic interval in docs/en/ENV_REFERENCE.md / docs/zh/ENV_REFERENCE.md.

Review Checklist

  • Acceptance criteria in tasks/TASK-2026-071-life-pulse-periodic-anchor/TASK.md satisfied (or explicitly deferred)
  • tasks/TASK-2026-071-life-pulse-periodic-anchor/STATUS.md updated with latest progress
  • tasks/TASK-2026-071-life-pulse-periodic-anchor/REVIEW.md includes merge readiness decision
  • tasks/board.md status is up to date

Bug / impact

Enable Life Pulse with high signal/sweep thresholds so only the periodic arm can fire, then wait past SKILLLITE_EVOLUTION_INTERVAL_SECS. Expected: spawn skilllite evolution run. Actual: no periodic spawn. Chat/agent-rpc still worked because it uses mutating growth_due.

Root cause

L2 evolution_growth_due read the mutex and passed it to inspect-only CLI status, but never wrote the mutex. inspect_growth_due uses anchor_eff = last.unwrap_or(now), so a persistent None keeps arm_periodic false.

Fix

After inspect, persist None -> now and refresh on arm_periodic. Spawn gating is unchanged.

Open in Web View Automation 

cursoragent and others added 2 commits September 4, 2026 11:20
Desktop evolution_growth_due only inspected CLI status and never wrote
last_periodic_growth_unix, so inspect_growth_due treated every heartbeat
as first-tick and the advertised periodic arm never fired.

Co-authored-by: EXboy <EXboys@users.noreply.github.com>
Co-authored-by: EXboy <EXboys@users.noreply.github.com>
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.

1 participant