PlasmaPy v2024.2.0 (2024-02-06)ο
Backwards Incompatible Changesο
Created new
plasmapy.simulation.particle_tracker.ParticleTrackerobject for general particle pushing simulations involving electromagnetic fields. The tracker replaces the oldplasmapy.simulation.particletracker.ParticleTracker. (#2245)Imports of classes and functions from
plasmapy.utilsmust now be made directly from the subpackages and modules, rather than fromplasmapy.utilsitself. (#2403)Moved
mass_densityand its aliasrho_fromplasmapy.formulary.misctoplasmapy.formulary.densities. (#2410)
Featuresο
Added a
notchargument tospectral_density, which allows users to output spectrum over one or multiple wavelength ranges to correspond to a notch filter commonly applied to experimentally measured Thomson scattering spectra. Changed thespectral_density_modelfunction to allownotchto be applied during fitting. (#2058)Changed unit annotations to
Quantitytype hint annotations. (#2421)Enabled
particle_input()to decorate functions which have variadic positional arguments followed by keyword arguments. (#2428; see also #2150)Added a
random_seedkeyword in thecreate_particlesmethod of theTrackerclass to make the function deterministic to resolve intermittent test failures. (#2487)
Bug Fixesο
Enabled
particle_input()to be compatible with postponed evaluation of annotations (see PEP 563). (#2479)
Improved Documentationο
Switched from
sphinx_toolbox.collapsetosphinx_collapsefor including collapsible content in our documentation. (#2387)Added a discussion of type hint annotations in the Testing Guide within the Contributor Guide. (#2440)
Trivial/Internal Changesο
Added Python 3.12 to the suite of continuous integration tests. (#2368)
Added a GitHub Action that will create an issue containing a release checklist, which will largely supersede the release process outlined in the Contributor Guide. (#2376)
Separated the GitHub Action for checking hyperlinks in the documentation into its own GitHub Action. (#2392)
Replaced
blackwith ruff in the pre-commit configuration. (#2394)Modified the
__exit__method ofHDF5Readerfor context management. (#2402)Added an initial configuration for mypy that temporarily ignores existing errors. (#2424)
Added mypy to the suite of continuous integration checks. (#2432)
Used
autotypingto implement type hint annotations for special methods like__init__and__str__, and changed-> typing.NoReturnannotations to-> None. (#2437)Used
autotypingto add-> Nonereturn annotations to functions and methods with noreturnstatement. (#2439)Added a stub file containing type hint annotations for
@wrapt.decorator. (#2442)Improved type hint annotations for
plasmapy.particles.decorators, which includesparticle_input(), and the corresponding tests. (#2443)Dropped the pre-commit hook for
isortand enabled allisortrules in ruff. (#2453)Added a
py.typedmarker file to indicate that PlasmaPy contains type hint annotations as per PEP 561. (#2473)Changed
_nearest_neighbor_interpolatormethod ingridsto interpolate quantities array instead of producing an intermediate index. (#2475)Enabled the
sphinxlinkchecker in quiet mode to make it easier to find problem links from the console output. (#2476)Bumped the minimum versions of dependencies to drop support for minor releases older than two years old. In particular, the minimum version of NumPy was bumped to
1.23.0. (#2488)