Skip to content

test(ci): stabilize CI harness, debloat test suites, and modernize tooling - #783

Merged
cofin merged 15 commits into
mainfrom
flow/ci-test-harness-stabilization
Sep 14, 2026
Merged

cofin merged 15 commits into
mainfrom
flow/ci-test-harness-stabilization

Conversation

@cofin

@cofin cofin commented Sep 13, 2026

Copy link
Copy Markdown
Member

Summary

Stabilize CI infrastructure, pytest harness, Makefile targets, and consolidate test suite assertions and parametrization.

Changes

  • Tooling & Makefile:

    • Pruned 7 obsolete infra-* targets from Makefile; consolidated make check-all to run lint coverage once without duplicate test runs.
    • Replaced custom AST pre-commit hook (no_future_annotations.py) and PyPI README generator with native Ruff TID251 rule; deleted docs/PYPI_README.md.
    • Bounded CI watchdog to runner process group (pytest_pgid) with exit trap and signal escalation (SIGABRT -> SIGTERM -> SIGKILL).
  • Documentation & Examples:

    • Relocated migration CLI workflow scenarios from docs/examples/quickstart_migrations.py to tests/integration/cli/test_migration_quickstart.py.
    • Replaced tools/build_docs.py with direct make docs in .github/workflows/docs.yml.
    • Pruned 7 unused Sphinx extensions and dependencies (jupyter_sphinx, nbsphinx, sphinx_datatables, sphinx_tabs, sphinx_togglebutton, sphinx.ext.todo, tools.sphinx_ext.changelog).
    • Removed redundant .gitkeep placeholders and unused theme.js.
  • Test Fixtures & Concurrency:

    • Isolated mutable extension_config per test in tests/integration/adapters/postgres/psqlpy/extensions/adk/test_owner_id_column.py.
    • Updated compiled detection in tests/conftest.py using importlib.machinery.EXTENSION_SUFFIXES for .so and .pyd.
    • Implemented interruptible synchronous event listener thread shutdown with bounded polling.
    • Verified BigQuery finite timeout configuration and offline Oracle mock separation.
  • Test Suite Consolidation & Parametrization:

    • Eliminated 9 meta-test and AST source scanner files (test_sqlglot_arg_contracts.py, test_mypyc_boundary.py, test_makefile_quality.py, test_conf.py, etc.).
    • Replaced tautological checks (assert stmt.parameters or True) with exact assertions; cleaned structural not hasattr assertions.
    • Consolidated 128 type guard functions to 62 parametrized tables and 97 value conversion functions to 32 parametrized tables with 100% variant coverage preserved.

Verification

  • make lint: clean exit 0 (Prek, Ruff check/format, Mypy, Pyright, slotscheck, Zizmor).
  • make docs: clean exit 0.
  • Unit tests: 898 passed, 1 skipped.

@codecov-commenter

codecov-commenter commented Sep 13, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 81.81818% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 78.90%. Comparing base (9c69704) to head (ddbb2a8).

Files with missing lines Patch % Lines
sqlspec/extensions/events/_queue.py 71.42% 1 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #783      +/-   ##
==========================================
- Coverage   78.91%   78.90%   -0.01%     
==========================================
  Files         491      491              
  Lines       72437    72443       +6     
  Branches    10181    10184       +3     
==========================================
- Hits        57163    57162       -1     
- Misses      11767    11772       +5     
- Partials     3507     3509       +2     
Flag Coverage Δ
integration 62.38% <27.27%> (-0.01%) ⬇️
py3.10 77.04% <27.27%> (-0.02%) ⬇️
py3.11 77.05% <27.27%> (-0.02%) ⬇️
py3.12 77.05% <27.27%> (-0.01%) ⬇️
py3.13 77.04% <27.27%> (-0.03%) ⬇️
py3.14 78.17% <81.81%> (-0.02%) ⬇️
unit 67.26% <81.81%> (+0.05%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
sqlspec/extensions/events/_channel.py 80.74% <100.00%> (+0.08%) ⬆️
sqlspec/extensions/events/_queue.py 86.11% <71.42%> (+0.13%) ⬆️

... and 3 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@cofin
cofin merged commit 6739420 into main Sep 14, 2026
27 checks passed
@cofin
cofin deleted the flow/ci-test-harness-stabilization branch September 14, 2026 02:57
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.

2 participants