{ "track_id": "default_layout_extract_20260629", "name": "Default Layout Extract + Hard Visual Verification", "status": "active", "created_date": "2026-06-29", "summary": "Extract tier-2's GOOD default-layout work (layouts/, src/layouts.py, install helpers, orphan-end-child fix, reset_layout cleanup) into master via hybrid porting + cherry-pick. Build 4-layer visual verification infrastructure (per-panel sentinel + Win32 PrintWindow pixel baseline + forced viewport/theme env vars + cannot-skip tags) that catches 'panels don't render' regressions every time they occur.", "estimated_effort": { "method": "scope (per workflow.md §Tier 1 Track Initialization Rules). NO day estimates.", "scope": "9 phases, 36 tasks. 3 new files (src/layouts.py, layouts/default.ini, scripts/check_visual_baseline.py, docs/guide_visual_verification.md, tests/artifacts/visual_baseline_default.png). 6 modified files (src/gui_2.py, src/paths.py, src/commands.py, scripts/run_tests_batched.py, conductor/tracks.md, docs/Readme.md). 9 new test files (RED tests for each helper + 3 negative tests). ~36 atomic commits.", "phase_1": "6 tasks: foundational assets (layouts/, src/layouts.py, get_layouts_dir)", "phase_2": "4 tasks: install helpers (_install_default_layout_if_empty + pre_run)", "phase_3": "5 tasks: wiring (App._post_init + App.run)", "phase_4": "2 tasks: surgical cherry-picks (c2155593 + 3b966288)", "phase_5": "3 tasks: Layer 1 sentinel", "phase_6": "5 tasks: Layer 2 pixel baseline", "phase_7": "4 tasks: Layer 3 forced viewport/theme", "phase_8": "5 tasks: Layer 4 cannot-skip gates", "phase_9": "7 tasks: negative test + verification + track completion" }, "scope": { "new_files": [ "src/layouts.py", "layouts/default.ini", "scripts/check_visual_baseline.py", "docs/guide_visual_verification.md", "tests/artifacts/visual_baseline_default.png", "tests/test_layouts.py", "tests/test_paths_layouts.py", "tests/test_layouts_bundled.py", "tests/test_install_default_layout.py", "tests/test_app_wiring_install.py", "tests/test_panels_visible_after_install.py", "tests/test_visual_baseline_default.py", "tests/test_test_mode_env_vars.py", "tests/test_visual_baseline_catches_corrupt_ini.py" ], "modified_files": [ "src/gui_2.py", "src/paths.py", "src/commands.py", "scripts/run_tests_batched.py", "conductor/tracks.md", "docs/Readme.md" ], "deleted_files": [] }, "goals": [ "G1. Master has layouts/ + src/layouts.py + get_layouts_dir() so app boots with non-empty INI on first launch", "G2. Master has _install_default_layout_* helpers wired into App._post_init + App.run so empty-INI install works at both phases", "G3. Master has reset_layout cleaned up to remove dead test-fixture path", "G4. Master has orphan imgui.end_child() at src/gui_2.py:6990 removed", "G5. Master has HARD 4-layer visual verification infrastructure (sentinel + pixel baseline + forced viewport/theme + cannot-skip gates)", "G6. A regression test demonstrates the verification catches the original 'panels don't render' bug" ], "verification_criteria": [ "All Phase 1-9 tasks committed (atomic per-task, ~36 commits)", "tests/test_panels_visible_after_install.py passes (Layer 1 sentinel)", "tests/test_visual_baseline_default.py passes (Layer 2 pixel diff < 1%)", "tests/test_test_mode_env_vars.py passes (Layer 3 env vars honored)", "tests/test_visual_baseline_catches_corrupt_ini.py passes (FR8 negative test)", "scripts/check_visual_baseline.py --help works; --strict mode exits 1 on diff > 1%", "scripts/run_tests_batched.py includes the visual verification tests", "tests/artifacts/visual_baseline_default.png is committed to master", "docs/guide_visual_verification.md is committed; cross-referenced from docs/Readme.md", "conductor/tracks.md schema updated to require VERIFIED- tag for [x]-completion of tracks touching src/gui_2.py", "MANUAL GATE: user runs uv run sloppy.py from master, confirms panels render visibly. User commits the VERIFIED- tag.", "docs/reports/TRACK_COMPLETION_default_layout_extract_20260629.md committed", "Tier-2 branch status: marked for archival (user's responsibility per AGENTS.md Inherited-Cruft)" ], "blocked_by": { "default_layout_install_20260629": "superseded (this track replaces it)" }, "blocks": { "panel_defs_fleury_migration": "future (consumes LayoutFile + get_layouts_dir from this track)" }, "tier_2_specific_commits_to_skip": { "rationale": "Tier-2 branch is 143 commits ahead of master. Only 8 commits are the default-layout work. The rest (RAG fixes, MMA stress tests, module taxonomy refactors) are NOT relevant to this track. Specific tier-2 commits NOT to extract:", "skip_list": [ "e9654518 (wrong-theory INI strip — superseded by 2afb0126 which we DO extract)", "13ad9d3e (commit message 'idk' — meaningless)", "28527851 (commit message 'artifacts' — meaningless)", "9437af6c (27 diagnostic scripts — noise)", "4acf8b15, b80e5afb, c42a7599, cf5244b1, b1632f46, 06476c56, 519e1340, cf6a2e20, 4bf5ecd6, 5e53d477, d4116f19, 7d5a5492 (tier-2 internal track-marking commits)", "71028dad (drop stale from src.command_palette import — tier-2 specific; master has src/command_palette.py so the import WORKS on master; do NOT cherry-pick)" ], "extract_list": [ "7577d7d2 (chore: introduce layouts/ + src/layouts.py) — port fresh via FR1.1 + FR1.2", "f3cd7bc2 (feat: install-on-empty-INI helpers) — port fresh via FR2.1 + FR2.2", "3d87f8e7 (fix: wire into App._post_init) — port fresh via FR2.4", "3b966288 (chore: remove dead test-fixture path) — cherry-pick via FR3.2", "2afb0126 (fix: restore [Docking] structure) — port fresh via FR1.1", "79c25a32 (fix: pre-run install timing) — port fresh via FR2.3 + FR2.5", "71028dad SKIPPED (master has src/command_palette.py)", "c2155593 (fix: remove orphan imgui.end_child) — cherry-pick via FR3.1" ] }, "regressions_and_pre_existing_failures": [], "pre_existing_failures_remaining": [], "deferred_to_followup_tracks": [ { "title": "panel_defs_fleury_migration", "description": "Migrate src/gui_2.py render_*_window functions to Ryan Fleury's declarative view-constructs pattern. PANELS: tuple[PanelDef, ...]. Per docs/transcripts/rcJwvx2CTZY_ryan_fleury_raddbg_codebase_intro.json v1@2237s and docs/transcripts/_9_bK_WjuYY_ryan_fleury_raddbg_walkthrough.json v2@7697s.", "track_status": "deferred", "depends_on_this_track": ["src/layouts.py", "LayoutFile", "get_layouts_dir"] }, { "title": "render_persona_editor_window empty-content bug fix", "description": "src/gui_2.py:3433+ opens + immediately closes the Persona Editor window when not embedded. Pre-existing bug, unrelated to panel visibility. Will be discovered via Layer 1 sentinel (panel renders but content is empty).", "track_status": "deferred", "depends_on_this_track": ["Layer 1 per-panel sentinel"] }, { "title": "test_engine_integration_20260627", "description": "imgui-bundle test engine integration. Provides ctx.capture_screenshot_window() + pixel-level diff via imgui.test_engine. Our Win32 PrintWindow approach is simpler but Windows-only. The two approaches are complementary.", "track_status": "in_progress (separate track)" }, { "title": "tier2_default_layout_install_20260629 archival", "description": "Tier-2 sandbox at C:\\projects\\manual_slop_tier2 has uncommitted edits (deleted manual_slop.toml + manual_slop_history.toml). User's responsibility per AGENTS.md Inherited-Cruft rule. Does NOT block this track.", "track_status": "user_action_required" } ], "risk_register": [ { "id": "R1", "description": "Win32 PrintWindow may fail for imgui-bundle HelloImGui window (HWND lookup or print flags)", "likelihood": "medium (the implementation is larger than the spec suggests)", "mitigation": "pre-flight check win32gui.IsWindow(hwnd) before capture; fall back to BitBlt of the screen region" }, { "id": "R2", "description": "Pixel baseline may be too sensitive (font hinting, GPU driver variations)", "likelihood": "medium", "mitigation": "tolerance is 1%; if false positives appear, raise to 2% and document" }, { "id": "R3", "description": "Forced viewport env var may not work on multi-monitor systems", "likelihood": "low", "mitigation": "scope the env var to test fixtures only (tests/conftest.py sets it before spawning)" }, { "id": "R4", "description": "Tier-2 sandbox has uncommitted edits that may conflict when cherry-picking", "likelihood": "low (cherry-pick to master directly; master is clean)", "mitigation": "cherry-pick to master directly (master is clean); tier-2 archival is user's responsibility" }, { "id": "R5", "description": "User-visible panel rendering depends on _install_default_layout_pre_run_result firing BEFORE immapp.run. If cwd already has a valid INI, install is skipped. The pixel baseline test must run with cwd-deleted manualslop_layout.ini to exercise the install path.", "likelihood": "low", "mitigation": "live_gui fixture already cleans cwd before spawning" } ], "documentation_deliverables": [ "conductor/tracks/default_layout_extract_20260629/spec.md", "conductor/tracks/default_layout_extract_20260629/plan.md", "conductor/tracks/default_layout_extract_20260629/metadata.json", "conductor/tracks/default_layout_extract_20260629/state.toml", "docs/guide_visual_verification.md (Layer 1-4 protocol)", "docs/reports/TRACK_COMPLETION_default_layout_extract_20260629.md (at end)" ] }