| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Deprecate the `cleanup: bool` parameter across all map functions and replace it with `reuse: bool` for clearer semantics: - `cleanup=True` (old) ≡ `reuse=False` (new): clean up before running - `cleanup=False` (old) ≡ `reuse=True` (new): reuse previous run data Changes: - Update all 8 function signatures (Pipeline.map, run_map, etc.) - Add deprecation warnings when cleanup is used - Update RunInfo.create() and internal validation logic - Update adaptive learner functions (create_learners, etc.) - Update CLI to support both --map-cleanup and --map-reuse flags - Update all error messages from "cleanup=False" to "reuse=True" - Maintain backward compatibility: cleanup takes priority when set The cleanup parameter will be removed in a future version.
Complete the cleanup parameter deprecation by: - Migrate all test files from cleanup= to reuse= parameter - Update CLI documentation to reference --map-reuse instead of --map-cleanup - Update all mapping option descriptions to mention "reuse behavior" All tests now use the new reuse parameter exclusively while maintaining backward compatibility through the deprecated cleanup parameter.
- Add stacklevel parameter to _handle_cleanup_deprecation() for proper warning location - Replace duplicated deprecation logic in all user-facing functions with helper - Functions updated: Pipeline.map(), Pipeline.map_async(), run_map(), run_map_async(), run_map_eager(), run_map_eager_async() - Remove deprecation warning from RunInfo.create() (now handled at user-facing layer) - Maintains same behavior while eliminating code duplication
Codecov Report✅ All modified and coverable lines are covered by tests.
|
Sorry, something went wrong.
CodSpeed Performance ReportMerging #921 will not alter performanceComparing reuse (2877a61) with main (cd662ab) Summary✅ 6 untouched |
Sorry, something went wrong.
- Set cleanup=None after handling deprecation in Pipeline.map() and Pipeline.map_async() - This prevents lower-level functions from issuing duplicate warnings - User-facing functions now emit exactly one warning per invocation Fixes issue where pipeline.map(..., cleanup=False) would emit two identical DeprecationWarnings (once in Pipeline.map, once in run_map/run_map_eager).
Renamed parameter 'reuse' to 'resume' for better semantic clarity: - 'resume' better conveys the ability to continue incomplete runs - Aligns with checkpoint/restart terminology in scientific computing - More intuitive user mental model: 'resume from previous run' Changes: - Parameter rename: reuse → resume - Parameter rename: reuse_validation → resume_validation - CLI flag rename: --map-reuse → --map-resume - File rename: test_reuse_validation.py → test_resume_validation.py - Updated all docstrings, error messages, and documentation - Deprecation warning now references 'resume' instead of 'reuse' Affected files: - 8 source files in pipefunc/ - 5 test files - 1 documentation file - Total: 210+ occurrences updated
✅ PR Title Formatted CorrectlyThe title of this PR has been updated to match the correct format. Thank you! |
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
No description provided.