You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
pipelines: replace stderr prints with warnings.warn in library functions #31
PR #30 moved pipeline functions from scripts/build_v5_snapshot.py into leadforge/pipelines/build_v5.py. These functions (subsample() in particular) print warnings directly to sys.stderr.
Now that they live in the package, downstream callers can't easily suppress or redirect this output. Library code should use warnings.warn() or a logger instead.
What to do
Replace print(..., file=sys.stderr) calls in leadforge/pipelines/build_v5.py with warnings.warn(..., stacklevel=2)
Update tests in tests/scripts/test_build_v5_snapshot.py to use pytest.warns() instead of capsys.readouterr()
Optionally keep the print in the CLI wrapper (scripts/build_v5_snapshot.py) for user-facing progress messages
Activity
refactor: pipeline RNG convention + warnings.warn (#34)