refactor(archive) tab split (phase 4 pt 3) : delete + maintenance helpers#2526
refactor(archive) tab split (phase 4 pt 3) : delete + maintenance helpers#2526ebuzerdrmz44 wants to merge 1 commit into
Conversation
ae304ba to
93a4c93
Compare
m3nu
left a comment
There was a problem hiding this comment.
Reviewed the pt-3 commit (93a4c93) in depth — it's a faithful, line-by-line move of delete/check/compact/prune into ArchiveDelete/ArchiveMaintenance, matching the extract/mount collaborator pattern. Selection goes through selected_archives() / ArchiveRole, so it's proxy-safe; helpers are strongly referenced on the tab, so the signal lifecycle is sound; all test call sites are updated with no stale patches.
Two nits before merge:
- The description says
toggle_compact_button_visibilitymoved intoArchiveMaintenance— it actually stays on the tab, which is correct (application.pycallsarchiveTab.toggle_compact_button_visibility()), but please fix the description. - The
application.pystring-literal cleanup hunk is unrelated to this PR. Harmless, but out of scope.
Once #2525 is squash-merged, rebase onto master (the diff collapses to the pt-3 commit) and un-draft — then this is good to go. Optional but cheap: a smoke test each for check_action/compact_action/prune_action, which currently have no direct coverage (pre-existing gap, not something this PR introduced).
The merge-base changed after approval.
93a4c93 to
633de65
Compare
Description
Continues the
ArchiveTabbreakup started in #2519 (pt 1) and #2525 (pt 2, diff + rename). This peels the remaining destructive/maintenance actions out of the god-object into the same collaborator-class pattern underviews/archive/:archive/archive_delete.pyArchiveDelete(delete_action/delete_result)archive/archive_maintenance.pyArchiveMaintenance(check,compact,pruneactions + results,save_prune_setting,toggle_compact_button_visibility)archive_tab.pyshrinks by 130 lines and now just wires these helpers alongside the pt 2ArchiveDiff/ArchiveRename.No behavior change .
Notes
_set_status/_toggle_all_buttons. De-underscoring that tab/helper boundary is a deliberate later cleanup, kept consistent with pt 2 rather than widened here.tests/unit/test_archives.py,tests/integration/test_archives.py).