Skip to content

emrg: remove scheduler workspace self-heal + origin probe + evolution-log archival (rants 14:16/14:18/14:20) - #869

Merged
argszero merged 2 commits into
masterfrom
feature/remove-scheduler-workspace-machinery
Aug 19, 2026
Merged

emrg: remove scheduler workspace self-heal + origin probe + evolution-log archival (rants 14:16/14:18/14:20)#869
argszero merged 2 commits into
masterfrom
feature/remove-scheduler-workspace-machinery

Conversation

@argszero

Copy link
Copy Markdown
Owner

Summary

Three host-mandated deletions (rants 2026-08-19T14:16:15 / 14:18:40 / 14:20:52) — remove scheduler-side git workspace machinery and disk archival that the agent no longer needs.

1. _ensure_origin_reachable deleted (rant 14:16:15)

The https→SSH origin probe is useless in a fully network-blocked environment and its unbounded git ls-remote timeout (15s, TimeoutExpired uncaught) crashed cycles. _clone_workspace already had its own https→SSH retry (#858), making the origin switch redundant.

  • Deleted the method + _origin_probed state + git_origin_url import.

2. _write_evolution_log deleted (rant 14:18:40)

Disk archival of evolution-<ts>.json (with 27-file rotation) was never consumed: GUI recent-runs and evolution_count both read the in-memory self.evolutions list. The cycle now only appends to the in-memory list. _write_final_summary (summary.json) kept per host evaluation.

3. Workspace self-heal family deleted (rant 14:20:52)

Git workspace management (clone / tag-align / git identity / projects.yml self-heal) belongs to the agent via its tools, not the scheduler — it was also a crash source when git timed out on a blocked network.

  • Deleted: _ensure_evolution_workspace, _clone_workspace, _align_to_installed_version, _ensure_git_identity, _is_usable_git_repo, _repo_url_from_install_info, _ensure_project_entry, plus the _run_evolution_cycle workspace check (cycle now goes straight to prompt build / daemon connect).
  • Kept_ensure_self_evolution_task (ensures the emrg task exists — not git management), EVOLUTION_CWD (used by it + prompt context), _source_dir, _detect_git_remote/owner-repo resolution (task config + prompt {repo} context).
  • Imports cleaned: subprocess, win32_no_window_kwargs, INSTALL_INFO, git_origin_url, https_to_ssh_url, is_git_connection_error, no_prompt_env all removed from scheduler.py.

Tests

  • Deleted 10 scheduler tests covering the removed machinery (self-heal persist/clone/backoff, origin probe ×4, offload-to-thread) + the unused FakeGitRun helper.
  • Rewrote 2: test_task_handler_no_repo_skips_self_heal (asserts default source_dir now), test_saturation_heartbeat_makes_no_network_calls (asserts scheduler no longer imports subprocess at all).
  • _make_cycle_handler captures the cycle log via a lazy proxy to handler.evolutions (in-memory list) — all 12 cycle tests unchanged in behavior.
  • Suite: 963 collected, 962 passed + 1 skipped; import + CLI checks green. Agent.md test count 974 → 963.

@argszeroargszero left a comment

Copy link
Copy Markdown
OwnerAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ LGTM — cycle. CI test + test-windows PASS (run 32223576427); deletions complete with no residual refs (subprocess/win32_no_window_kwargs/git_origin_url/https_to_ssh/is_git_connection_error/INSTALL_INFO all removed); _ensure_self_evolution_task + EVOLUTION_CWD correctly kept; suite 963 collected (962 passed + 1 skipped).

@argszeroargszero left a comment

Copy link
Copy Markdown
OwnerAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ LGTM — cycle. CI test + test-windows PASS (rerun 32225463117 after a transient Windows-runner hang); head unchanged; deletions complete with no residual refs.

@argszeroargszero left a comment

Copy link
Copy Markdown
OwnerAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ LGTM — cycle. Third consecutive approval (cycles 911/912/913); head unchanged (85b92b8), CI test + test-windows PASS, MERGEABLE/CLEAN.

@argszero
argszero merged commit e401246 into masterAug 19, 2026
5 of 6 checks passed
argszero added a commit that referenced this pull request Aug 19, 2026
Co-authored-by: EMRG Evolution <emrg@argszero.dev>
@argszero
argszero deleted the feature/remove-scheduler-workspace-machinery branch August 19, 2026 11:28
Sign up for freeto 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

@argszero