Skip to content

refactor: remove unreferenced code across app, bonsplit and tests - #423

Merged
arzafran merged 1 commit into
mainfrom
chore/deslop-pass-2
Oct 12, 2026
Merged

arzafran merged 1 commit into
mainfrom
chore/deslop-pass-2

Conversation

@arzafran

Copy link
Copy Markdown
Member

What this does

Removes code that nothing calls, so the app, the tests and the vendored split library carry less weight and read faster. No behaviour changes: every removed symbol had zero references outside its own definition, and the only logic edit deletes a branch that could never run.

Summary

  • Removes unreferenced helpers, views and types in Sources/, vendor/bonsplit, the unit and UI test targets, tests_v2/programa_client.py and scripts/gen-v2-contract.py. About 1330 lines.
  • Sources/WindowSwizzles.swift: the first-responder bypass helper had no callers, so its depth counter was always zero. The helper, the counter and the always-false early return in programa_makeFirstResponder are gone. programa_sendEvent is untouched.
  • programaUITests/MultiWindowNotificationsUITests.swift: about 500 lines of unused CLI-driven helpers removed. The CLI strategy enum collapsed to the one case that was ever used.
  • Collapses double blank lines and removes three empty MARK: sections. Three history-narrating comments reworded to present tense.
  • No Swift file deleted, so project.pbxproj is unchanged.

Review order: start with Sources/WindowSwizzles.swift (the one logic deletion), then Sources/TerminalController+Debug.swift and Sources/SidebarVisuals.swift. The rest is unreferenced symbols and whitespace.

Test plan

  • CI workflow green, including unit-tests and the UI jobs, since both test targets lost helpers.
  • python3 scripts/check-structural-budgets.py prints structural budgets: PASS.
  • scripts/check-v2-contract.sh prints v2 contract check: OK.
  • python3 scripts/check-settings-docs.py prints ok:.
  • node --test scripts/*.test.js reports 0 failures.

Delete helpers, views and types that nothing references in Sources,
vendor/bonsplit, both test targets, tests_v2/programa_client.py and
scripts/gen-v2-contract.py. The first-responder bypass in
WindowSwizzles.swift had no callers, so its depth counter was always
zero; remove it with the early return it guarded. Collapse the UI-test
CLI strategy enum to the one case ever used, drop empty MARK sections
and double blank lines, and reword three history-narrating comments.
@arzafran
arzafran merged commit e63181f into main Oct 12, 2026
13 checks passed
@arzafran
arzafran deleted the chore/deslop-pass-2 branch October 12, 2026 17:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant