From d0e7743ef6bade86927cb76319da4a7a55137439 Mon Sep 17 00:00:00 2001 From: Ed_ Date: Thu, 5 Mar 2026 09:51:11 -0500 Subject: [PATCH] chore(conductor): Archive completed and deprecated tracks - Moved codebase_migration_20260302 to archive - Moved gui_decoupling_controller_20260302 to archive - Moved test_architecture_integrity_audit_20260304 to archive - Removed deprecated test_suite_performance_and_flakiness_20260302 --- .../codebase_migration_20260302/index.md | 0 .../codebase_migration_20260302/metadata.json | 0 .../codebase_migration_20260302/plan.md | 0 .../codebase_migration_20260302/spec.md | 0 .../SESSION_POSTMORTEM_20260304.md | 0 .../debrief.md | 0 .../index.md | 0 .../metadata.json | 0 .../plan.md | 0 .../spec.md | 0 .../index.md | 0 .../metadata.json | 0 .../plan.md | 0 .../report.md | 0 .../report_claude.md | 0 .../report_gemini.md | 0 .../spec.md | 0 .../index.md | 5 -- .../metadata.json | 8 --- .../plan.md | 51 ------------------- .../spec.md | 19 ------- 21 files changed, 83 deletions(-) rename conductor/{tracks => archive}/codebase_migration_20260302/index.md (100%) rename conductor/{tracks => archive}/codebase_migration_20260302/metadata.json (100%) rename conductor/{tracks => archive}/codebase_migration_20260302/plan.md (100%) rename conductor/{tracks => archive}/codebase_migration_20260302/spec.md (100%) rename conductor/{tracks => archive}/gui_decoupling_controller_20260302/SESSION_POSTMORTEM_20260304.md (100%) rename conductor/{tracks => archive}/gui_decoupling_controller_20260302/debrief.md (100%) rename conductor/{tracks => archive}/gui_decoupling_controller_20260302/index.md (100%) rename conductor/{tracks => archive}/gui_decoupling_controller_20260302/metadata.json (100%) rename conductor/{tracks => archive}/gui_decoupling_controller_20260302/plan.md (100%) rename conductor/{tracks => archive}/gui_decoupling_controller_20260302/spec.md (100%) rename conductor/{tracks => archive}/test_architecture_integrity_audit_20260304/index.md (100%) rename conductor/{tracks => archive}/test_architecture_integrity_audit_20260304/metadata.json (100%) rename conductor/{tracks => archive}/test_architecture_integrity_audit_20260304/plan.md (100%) rename conductor/{tracks => archive}/test_architecture_integrity_audit_20260304/report.md (100%) rename conductor/{tracks => archive}/test_architecture_integrity_audit_20260304/report_claude.md (100%) rename conductor/{tracks => archive}/test_architecture_integrity_audit_20260304/report_gemini.md (100%) rename conductor/{tracks => archive}/test_architecture_integrity_audit_20260304/spec.md (100%) delete mode 100644 conductor/tracks/test_suite_performance_and_flakiness_20260302/index.md delete mode 100644 conductor/tracks/test_suite_performance_and_flakiness_20260302/metadata.json delete mode 100644 conductor/tracks/test_suite_performance_and_flakiness_20260302/plan.md delete mode 100644 conductor/tracks/test_suite_performance_and_flakiness_20260302/spec.md diff --git a/conductor/tracks/codebase_migration_20260302/index.md b/conductor/archive/codebase_migration_20260302/index.md similarity index 100% rename from conductor/tracks/codebase_migration_20260302/index.md rename to conductor/archive/codebase_migration_20260302/index.md diff --git a/conductor/tracks/codebase_migration_20260302/metadata.json b/conductor/archive/codebase_migration_20260302/metadata.json similarity index 100% rename from conductor/tracks/codebase_migration_20260302/metadata.json rename to conductor/archive/codebase_migration_20260302/metadata.json diff --git a/conductor/tracks/codebase_migration_20260302/plan.md b/conductor/archive/codebase_migration_20260302/plan.md similarity index 100% rename from conductor/tracks/codebase_migration_20260302/plan.md rename to conductor/archive/codebase_migration_20260302/plan.md diff --git a/conductor/tracks/codebase_migration_20260302/spec.md b/conductor/archive/codebase_migration_20260302/spec.md similarity index 100% rename from conductor/tracks/codebase_migration_20260302/spec.md rename to conductor/archive/codebase_migration_20260302/spec.md diff --git a/conductor/tracks/gui_decoupling_controller_20260302/SESSION_POSTMORTEM_20260304.md b/conductor/archive/gui_decoupling_controller_20260302/SESSION_POSTMORTEM_20260304.md similarity index 100% rename from conductor/tracks/gui_decoupling_controller_20260302/SESSION_POSTMORTEM_20260304.md rename to conductor/archive/gui_decoupling_controller_20260302/SESSION_POSTMORTEM_20260304.md diff --git a/conductor/tracks/gui_decoupling_controller_20260302/debrief.md b/conductor/archive/gui_decoupling_controller_20260302/debrief.md similarity index 100% rename from conductor/tracks/gui_decoupling_controller_20260302/debrief.md rename to conductor/archive/gui_decoupling_controller_20260302/debrief.md diff --git a/conductor/tracks/gui_decoupling_controller_20260302/index.md b/conductor/archive/gui_decoupling_controller_20260302/index.md similarity index 100% rename from conductor/tracks/gui_decoupling_controller_20260302/index.md rename to conductor/archive/gui_decoupling_controller_20260302/index.md diff --git a/conductor/tracks/gui_decoupling_controller_20260302/metadata.json b/conductor/archive/gui_decoupling_controller_20260302/metadata.json similarity index 100% rename from conductor/tracks/gui_decoupling_controller_20260302/metadata.json rename to conductor/archive/gui_decoupling_controller_20260302/metadata.json diff --git a/conductor/tracks/gui_decoupling_controller_20260302/plan.md b/conductor/archive/gui_decoupling_controller_20260302/plan.md similarity index 100% rename from conductor/tracks/gui_decoupling_controller_20260302/plan.md rename to conductor/archive/gui_decoupling_controller_20260302/plan.md diff --git a/conductor/tracks/gui_decoupling_controller_20260302/spec.md b/conductor/archive/gui_decoupling_controller_20260302/spec.md similarity index 100% rename from conductor/tracks/gui_decoupling_controller_20260302/spec.md rename to conductor/archive/gui_decoupling_controller_20260302/spec.md diff --git a/conductor/tracks/test_architecture_integrity_audit_20260304/index.md b/conductor/archive/test_architecture_integrity_audit_20260304/index.md similarity index 100% rename from conductor/tracks/test_architecture_integrity_audit_20260304/index.md rename to conductor/archive/test_architecture_integrity_audit_20260304/index.md diff --git a/conductor/tracks/test_architecture_integrity_audit_20260304/metadata.json b/conductor/archive/test_architecture_integrity_audit_20260304/metadata.json similarity index 100% rename from conductor/tracks/test_architecture_integrity_audit_20260304/metadata.json rename to conductor/archive/test_architecture_integrity_audit_20260304/metadata.json diff --git a/conductor/tracks/test_architecture_integrity_audit_20260304/plan.md b/conductor/archive/test_architecture_integrity_audit_20260304/plan.md similarity index 100% rename from conductor/tracks/test_architecture_integrity_audit_20260304/plan.md rename to conductor/archive/test_architecture_integrity_audit_20260304/plan.md diff --git a/conductor/tracks/test_architecture_integrity_audit_20260304/report.md b/conductor/archive/test_architecture_integrity_audit_20260304/report.md similarity index 100% rename from conductor/tracks/test_architecture_integrity_audit_20260304/report.md rename to conductor/archive/test_architecture_integrity_audit_20260304/report.md diff --git a/conductor/tracks/test_architecture_integrity_audit_20260304/report_claude.md b/conductor/archive/test_architecture_integrity_audit_20260304/report_claude.md similarity index 100% rename from conductor/tracks/test_architecture_integrity_audit_20260304/report_claude.md rename to conductor/archive/test_architecture_integrity_audit_20260304/report_claude.md diff --git a/conductor/tracks/test_architecture_integrity_audit_20260304/report_gemini.md b/conductor/archive/test_architecture_integrity_audit_20260304/report_gemini.md similarity index 100% rename from conductor/tracks/test_architecture_integrity_audit_20260304/report_gemini.md rename to conductor/archive/test_architecture_integrity_audit_20260304/report_gemini.md diff --git a/conductor/tracks/test_architecture_integrity_audit_20260304/spec.md b/conductor/archive/test_architecture_integrity_audit_20260304/spec.md similarity index 100% rename from conductor/tracks/test_architecture_integrity_audit_20260304/spec.md rename to conductor/archive/test_architecture_integrity_audit_20260304/spec.md diff --git a/conductor/tracks/test_suite_performance_and_flakiness_20260302/index.md b/conductor/tracks/test_suite_performance_and_flakiness_20260302/index.md deleted file mode 100644 index 827a4a9..0000000 --- a/conductor/tracks/test_suite_performance_and_flakiness_20260302/index.md +++ /dev/null @@ -1,5 +0,0 @@ -# Track test_suite_performance_and_flakiness_20260302 Context - -- [Specification](./spec.md) -- [Implementation Plan](./plan.md) -- [Metadata](./metadata.json) \ No newline at end of file diff --git a/conductor/tracks/test_suite_performance_and_flakiness_20260302/metadata.json b/conductor/tracks/test_suite_performance_and_flakiness_20260302/metadata.json deleted file mode 100644 index f678b90..0000000 --- a/conductor/tracks/test_suite_performance_and_flakiness_20260302/metadata.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "track_id": "test_suite_performance_and_flakiness_20260302", - "type": "chore", - "status": "new", - "created_at": "2026-03-02T22:30:00Z", - "updated_at": "2026-03-02T22:30:00Z", - "description": "Replace arbitrary time.sleep() calls with deterministic polling/Events and optimize test speed." -} \ No newline at end of file diff --git a/conductor/tracks/test_suite_performance_and_flakiness_20260302/plan.md b/conductor/tracks/test_suite_performance_and_flakiness_20260302/plan.md deleted file mode 100644 index 48842d5..0000000 --- a/conductor/tracks/test_suite_performance_and_flakiness_20260302/plan.md +++ /dev/null @@ -1,51 +0,0 @@ -# Implementation Plan: Test Suite Performance & Flakiness (test_suite_performance_and_flakiness_20260302) - -> **TEST DEBT FIX:** This track is responsible for eliminating the `RuntimeError: Event loop is closed` deadlocks and zombie subprocesses discovered during the `test_architecture_integrity_audit_20260304` audit. - -## Phase 1: Asyncio Decoupling & Queue Refactor -- [ ] Task: Initialize MMA Environment `activate_skill mma-orchestrator` -- [ ] Task: Rip out `asyncio` from `AppController` - - [ ] WHERE: `src/app_controller.py` and `src/events.py` - - [ ] WHAT: Replace `events.AsyncEventQueue` with a standard `queue.Queue`. Convert `_process_event_queue` to a synchronous `while True` loop running in a daemon thread. - - [ ] HOW: Remove all `async`/`await` and `asyncio.run_coroutine_threadsafe` calls related to the internal event queue. - - [ ] SAFETY: Ensures test teardowns no longer violently crash background event loops. -- [ ] Task: Ensure Phantom Processes are Killed - - [ ] WHERE: `tests/conftest.py` - - [ ] WHAT: Verify the `kill_process_tree` implementation added in the audit is fully robust against hanging `sloppy.py` instances. - - [ ] HOW: Test with intentional process hangs. -- [ ] Task: Conductor - User Manual Verification 'Phase 1: Asyncio Decoupling' - -## Phase 2: Audit & Polling Primitives -- [ ] Task: Initialize MMA Environment `activate_skill mma-orchestrator` -- [ ] Task: Create Deterministic Polling Primitives - - [ ] WHERE: `tests/conftest.py` - - [ ] WHAT: Implement a `wait_until(predicate_fn, timeout=5.0, interval=0.05)` utility. - - [ ] HOW: Standard while loop that evaluates `predicate_fn()`. - - [ ] SAFETY: Ensure it raises a clear `TimeoutError` if it fails. -- [ ] Task: Conductor - User Manual Verification 'Phase 1: Polling Primitives' (Protocol in workflow.md) - -## Phase 2: Refactoring Integration Tests -- [ ] Task: Refactor `test_spawn_interception.py` - - [ ] WHERE: `tests/test_spawn_interception.py` - - [ ] WHAT: Replace hardcoded sleeps with `wait_until` checking the `event_queue` or internal state. - - [ ] HOW: Use the new `conftest.py` utility. - - [ ] SAFETY: Prevent event loop deadlocks. -- [ ] Task: Refactor Simulation Waits - - [ ] WHERE: `simulation/*.py` and `tests/test_live_gui_integration.py` - - [ ] WHAT: Replace `time.sleep()` blocks with `ApiHookClient.wait_for_event` or `client.wait_until_value_equals`. - - [ ] HOW: Expand `ApiHookClient` polling capabilities if necessary. - - [ ] SAFETY: Ensure the GUI hook server remains responsive during rapid polling. -- [ ] Task: Conductor - User Manual Verification 'Phase 2: Refactoring Sleeps' (Protocol in workflow.md) - -## Phase 3: Test Marking & Final Validation -- [ ] Task: Apply Slow Test Marks - - [ ] WHERE: Across all `tests/` - - [ ] WHAT: Add `@pytest.mark.slow` to any test requiring a live GUI boot or API mocking that takes >2 seconds. - - [ ] HOW: Import pytest and apply the decorator. - - [ ] SAFETY: Update `pyproject.toml` to register the `slow` marker. -- [ ] Task: Full Suite Performance Validation - - [ ] WHERE: Project root - - [ ] WHAT: Run `uv run pytest -m "not slow"` and verify execution time < 10 seconds. Run `uv run pytest` to ensure total suite passes. - - [ ] HOW: Time the terminal command. - - [ ] SAFETY: None. -- [ ] Task: Conductor - User Manual Verification 'Phase 3: Final Validation' (Protocol in workflow.md) \ No newline at end of file diff --git a/conductor/tracks/test_suite_performance_and_flakiness_20260302/spec.md b/conductor/tracks/test_suite_performance_and_flakiness_20260302/spec.md deleted file mode 100644 index 6f4d1f8..0000000 --- a/conductor/tracks/test_suite_performance_and_flakiness_20260302/spec.md +++ /dev/null @@ -1,19 +0,0 @@ -# Track Specification: Test Suite Performance & Flakiness (test_suite_performance_and_flakiness_20260302) - -## Overview -The test suite currently takes over 5.0 minutes to execute and frequently hangs on integration tests (e.g., `test_spawn_interception.py`). Several simulation tests are flaky or timing out. This track replaces arbitrary `time.sleep()` calls with deterministic polling (`threading.Event()`), aiming to drive the core TDD test execution time down to under 10 seconds. - -## Architectural Constraints -- **Zero Arbitrary Sleeps**: `time.sleep(1.0)` is banned in test files unless testing actual rate-limiting or debounce functionality. -- **Deterministic Waits**: Tests must use state-polling (with aggressive micro-sleeps) or `asyncio.Event` / `threading.Event` to proceed exactly when the system is ready. - -## Functional Requirements -- Audit all `tests/` and `simulation/` files for `time.sleep()`. -- Implement polling helper functions in `conftest.py` (e.g., `wait_until(condition_func, timeout)`). -- Refactor all integration tests to use the deterministic polling helpers. -- Apply `@pytest.mark.slow` to any test that legitimately takes >2 seconds, allowing developers to skip them during rapid TDD loops. - -## Acceptance Criteria -- [ ] `time.sleep` occurrences in the test suite are eliminated or strictly justified. -- [ ] The core unit test suite (excluding `@pytest.mark.slow`) executes in under 10 seconds. -- [ ] Integration tests pass consistently without flakiness across 10 consecutive runs. \ No newline at end of file