Commit df7a470
chore: dead code cleanup - remove ~2,450 lines of commented code (#419)
* feat(tests): add debug_print fixture for toggleable test output
Add pytest --debug-prints flag and debug_print fixture for controllable
debug output in tests. This enables preserving valuable debug prints
while keeping normal test output clean.
Usage:
pytest tests/ # Silent
pytest tests/ --debug-prints -s # With debug output
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* chore: remove unused import pdb statements from 35 files
Phase 2 of dead code cleanup. These pdb imports were added for debugging
but never used (all had `# noqa: F401` to silence flake8 warnings).
Files modified across: plotting/, fitfunctions/, core/, solar_activity/,
instabilities/, tools/, and root __init__.py
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* chore(plotting): remove 1,830 lines of dead code from histograms.py
Phase 3 of dead code cleanup. This file contained legacy implementations
of AggPlot, Hist1D, Hist2D, and GridHist2D classes that were fully
commented out. The actual implementations now live in their own modules
(agg_plot.py, hist1d.py, hist2d.py).
File reduced from 1,845 lines to 15 lines (99% reduction).
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* chore: remove 584 lines of dead code from 5 source files
Phase 4 of dead code cleanup. Removed commented-out implementations,
debug prints, and memory profiling code.
Files cleaned:
- plasma.py: -235 lines (commented algorithms, debug prints)
- base.py: -153 lines (old clip_data, Plot2D class)
- spiral.py: -90 lines (timing/debug code)
- hist2d.py: -92 lines (old implementations)
- orbits.py: -14 lines (memory profiling)
Preserved all TODO comments as active work items.
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* chore: remove additional dead code from orbits.py and test prints
Phase 5 of dead code cleanup:
- orbits.py: Remove 59 lines of commented logging/debug code
- test_performance.py: Remove 15 lines of timing benchmark prints
Total additional cleanup: 74 lines removed
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* style: fix black formatting in __init__.py
Removed extra blank line after docstring that black flagged.
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* style: fix black formatting in data/reference/__init__.py
Fixed blank line formatting from merge with master.
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>1 parent 487fbcc commit df7a470
39 files changed
Lines changed: 44 additions & 2527 deletions
File tree
- solarwindpy
- core
- data/reference
- fitfunctions
- instabilities
- plotting
- labels
- solar_activity
- lisird
- sunspot_number
- tools
- tests
- plotting
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
7 | | - | |
8 | | - | |
9 | 7 | | |
10 | 8 | | |
11 | 9 | | |
| |||
0 commit comments