Skip to content

Conversation

@the-mr-dave
Copy link

Description

This PR adds mypy type checking to libEnsemble using an intentionally permissive initial configuration.
It establishes a baseline that can be tightened incrementally without impacting CI stability.

Related issue: #1633

Changes

  • Add an initial mypy configuration to pyproject.toml
  • Add mypy as a CI check
  • Restrict type checking scope to libensemble/utils
  • Exclude utility modules that are not yet mypy-compliant
  • Refactor libensemble/utils/misc.py to satisfy mypy

CI Impact

  • mypy is executed with a restricted scope and permissive settings
  • No existing CI checks are modified, relaxed, or made less strict

the-mr-dave and others added 4 commits January 14, 2026 22:16
Introduce mypy with a permissive, incremental configuration.
Type checking is limited to libensemble/utils and excludes files not yet migrated.
Make libensemble/utils/misc.py compliant with mypy.
Introduce mypy with a permissive, incremental configuration.
Type checking is limited to libensemble/utils and excludes files not yet migrated.
Make libensemble/utils/misc.py compliant with mypy.
… testing/mypy-initial-setup

# Conflicts:
#	pyproject.toml
@codecov
Copy link

codecov bot commented Jan 14, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 78.30%. Comparing base (0f2ee07) to head (b4d2bca).

Additional details and impacted files
@@           Coverage Diff            @@
##           develop    #1655   +/-   ##
========================================
  Coverage    78.29%   78.30%           
========================================
  Files           76       76           
  Lines         7580     7581    +1     
  Branches      1119     1119           
========================================
+ Hits          5935     5936    +1     
  Misses        1460     1460           
  Partials       185      185           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

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

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