Skip to content

More strict types with Pydantic; updated CI#5

Merged
regularkevvv merged 2 commits intomainfrom
feat/coverage-cleanup
Feb 3, 2026
Merged

More strict types with Pydantic; updated CI#5
regularkevvv merged 2 commits intomainfrom
feat/coverage-cleanup

Conversation

@regularkevvv
Copy link
Copy Markdown
Collaborator

@regularkevvv regularkevvv commented Feb 3, 2026

This PR changes some of the typing in the coverage feature to be more string, using Pydantic and updating CI to have the ty check


Summary by cubic

Strengthened coverage type safety with Pydantic and validated report types, improving config handling and reducing runtime errors. CI now enforces type checks with “uv run ty check”.

  • Refactors
    • Added jinjatest.coverage.types with CoverageConfig, ReportType, BranchType, and validators.
    • _load_pyproject_config now returns CoverageConfig with defaults and ignores extra TOML fields; invalid or missing configs fall back safely.
    • Normalizes and validates CLI/config report types; defaults to "term" when none provided.
    • Switched branch_type to BranchType in discovery; exported new types via init; tightened reporter dict typing.
    • Updated CI and publish workflows to run “uv run ty check”.

Written for commit 782fa2d. Summary will update on new commits.

Copy link
Copy Markdown

@cubic-dev-ai cubic-dev-ai bot left a comment

Choose a reason for hiding this comment

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

No issues found across 9 files

@regularkevvv regularkevvv merged commit 73ccac0 into main Feb 3, 2026
7 checks passed
@regularkevvv regularkevvv deleted the feat/coverage-cleanup branch February 3, 2026 06:06
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.

1 participant