Skip to content

Perform static type checking with ty instead of mypy#3240

Draft
namurphy wants to merge 46 commits intoPlasmaPy:mainfrom
namurphy:ty
Draft

Perform static type checking with ty instead of mypy#3240
namurphy wants to merge 46 commits intoPlasmaPy:mainfrom
namurphy:ty

Conversation

@namurphy
Copy link
Member

@namurphy namurphy commented Mar 20, 2026

Description

This pull request switches PlasmaPy's static type checker from mypy to ty.

Remaining tasks

  • Update the parts of the contributor guide that discuss mypy.

Related issues and pull requests

Closes #2971. Cross-references: #2214, #2424, #2432, #2451, #268

@review-notebook-app
Copy link

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

@github-actions github-actions bot added plasmapy.particles Related to the plasmapy.particles subpackage docs PlasmaPy Docs at http://docs.plasmapy.org plasmapy.plasma Related to the plasmapy.plasma subpackage plasmapy.formulary Related to the plasmapy.formulary subpackage testing plasmapy.diagnostics Related to the plasmapy.diagnostics subpackage plasmapy.formulary.quantum Related to the plasmapy.formulary.quantum module plasmapy.utils Related to the plasmapy.utils subpackage plasmapy.dispersion Related to the plasmapy.dispersion subpackage CI Related to continuous integration notebooks Related to example Jupyter notebooks in docs/examples/ requirements Related to updating requirements GitHub Actions A continuous integration platform for automating tests and other tasks (see .github/ directory) plasmapy.analysis Related to the plasmapy.analysis subpackage packaging Related to packaging or distribution plasmapy.simulation Related to the plasmapy.simulation subpackage documentation infrastructure static type checking python Pull requests that update Python code nox Related to the nox automation software run comprehensive tests Add this label to run comprehensive tests in CI labels Mar 20, 2026
@codecov
Copy link

codecov bot commented Mar 20, 2026

Codecov Report

❌ Patch coverage is 94.85714% with 9 lines in your changes missing coverage. Please review.
✅ Project coverage is 95.36%. Comparing base (85f5d1e) to head (31cb557).

Files with missing lines Patch % Lines
src/plasmapy/particles/atomic.py 77.77% 4 Missing ⚠️
src/plasmapy/analysis/nullpoint.py 50.00% 0 Missing and 1 partial ⚠️
...formulary/collisions/helio/collisional_analysis.py 66.66% 1 Missing ⚠️
src/plasmapy/particles/symbols.py 66.66% 1 Missing ⚠️
src/plasmapy/plasma/grids.py 94.44% 1 Missing ⚠️
src/plasmapy/plasma/sources/openpmd_hdf5.py 0.00% 1 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##             main    #3240   +/-   ##
=======================================
  Coverage   95.36%   95.36%           
=======================================
  Files         108      108           
  Lines        9872     9872           
  Branches     1501     1501           
=======================================
  Hits         9414     9414           
  Misses        262      262           
  Partials      196      196           

☔ 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.

@github-actions github-actions bot added the maintenance General updates to package infrastructure label Mar 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CI Related to continuous integration docs PlasmaPy Docs at http://docs.plasmapy.org documentation infrastructure GitHub Actions A continuous integration platform for automating tests and other tasks (see .github/ directory) maintenance General updates to package infrastructure notebooks Related to example Jupyter notebooks in docs/examples/ nox Related to the nox automation software packaging Related to packaging or distribution plasmapy.analysis Related to the plasmapy.analysis subpackage plasmapy.diagnostics Related to the plasmapy.diagnostics subpackage plasmapy.dispersion Related to the plasmapy.dispersion subpackage plasmapy.formulary.quantum Related to the plasmapy.formulary.quantum module plasmapy.formulary Related to the plasmapy.formulary subpackage plasmapy.particles Related to the plasmapy.particles subpackage plasmapy.plasma Related to the plasmapy.plasma subpackage plasmapy.simulation Related to the plasmapy.simulation subpackage plasmapy.utils Related to the plasmapy.utils subpackage python Pull requests that update Python code requirements Related to updating requirements run comprehensive tests Add this label to run comprehensive tests in CI static type checking testing

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Switch to alternative type checker for static type checking

1 participant