May 29, 2026

v0.8.0 prep: dead-code removal, theme fixes, test tier cleanup

Pre-release cleanup for v0

Pre-release cleanup for v0.8.0: dropped an unused Path import and added an E402 noqa in test_search_embedding_cache to clear the ruff gate (both regressions from rc-0.8.0), bumped VERSION to 0.8.0 to align with pyproject.toml, and regenerated skills.sqlite (byte layout only, content unchanged).

Two dead-code removals. extract_html was simplified to trafilatura-only — the BeautifulSoup and regex-strip fallback tiers were unreachable because beautifulsoup4 was never declared or transitively pulled in, so both were dropped along with the _strip_html_tags helper and two fallback-chain tests. Separately, a stale _ALLOWED_REGISTRY_ALL_CALLERS entry for services/self_model_service.py was removed (TKT-648, TKT-670); the file itself was deleted in the earlier SelfModelService rip-out (-756 LOC), and the leftover entry would have silently pre-authorized a recreated file containing an AbilityRegistry.all() call — a covert governance bypass.

Two theme fixes on the frontend. The Brain sidebar theme-toggle button defaulted to type=“submit” and could navigate users away from /brain/ on click; it now has an explicit type=“button” and calls preventDefault()/stopPropagation() so only the theme flips (TKT-687). The api-key-dialog content panel hardcoded a near-black background that produced dark-on-dark text in light theme, and the shared scrollbar thumb used a white rgba with no light override — both swapped to theme-aware tokens mirroring the existing Brain dashboard pattern (TKT-685, TKT-686).

Two test-suite reorganizations. test_web_download.py was marked unit but made six live HTTP calls to httpbin.org plus an NXDOMAIN-dependent assertion, breaking deterministic unit guarantees and failing in air-gapped CI; the module-level unit marker was dropped, pure URL-validation tests stayed under @pytest.mark.unit (no network), and the three real-download tests moved to @pytest.mark.integration behind a lazy httpbin reachability probe so pytest -m unit collection makes zero network calls (TKT-649, TKT-669, TKT-681). The NXDOMAIN assertion was removed in favor of the deterministic missing-URL path. Separately, test_generate_concept_lut.py hardcoded count == 27 (a pre-alias magic number) and hard-failed when the encoder was available; counts are now derived from the live source YAML (28 canonical keys, 365 total labels), with an encoder-availability skip guard for clean skips when ONNX is unavailable (TKT-644, TKT-668, TKT-678).

  • v0.8.0 version bump and ruff gate cleared ahead of rc-0.8.0

  • HTML extraction collapsed to trafilatura-only, unreachable BS4/regex fallbacks removed

  • Stale self_model_service.py allowlist entry removed to close a covert governance bypass

  • Brain theme-toggle button now type=“button” with preventDefault/stopPropagation

  • web_download tests split: pure URL checks stay unit, live HTTP gated to integration

  • Concept LUT test counts derived from source YAML with an ONNX-availability skip guard