cask: show accurate log messages for in-place upgrades#21568
Open
sensebat wants to merge 2 commits intoHomebrew:mainfrom
Open
cask: show accurate log messages for in-place upgrades#21568sensebat wants to merge 2 commits intoHomebrew:mainfrom
sensebat wants to merge 2 commits intoHomebrew:mainfrom
Conversation
When a terminal has App Management or Full Disk Access permissions, Homebrew upgrades cask apps in-place by replacing only the contents of the .app directory, preserving its inode and macOS metadata (Dock position, notification settings, granted permissions). However, the log output still printed "Removing App" and "Moving App" as if the entire bundle were being deleted and reinstalled. With this change: - In-place upgrades print a single "Upgrading App in-place" message - Full replacement upgrades continue to print "Removing App" and "Moving App" as before
MikeMcQuaid
reviewed
Feb 13, 2026
Member
MikeMcQuaid
left a comment
There was a problem hiding this comment.
Thanks! Few tweaks needed.
73906c3 to
db32c04
Compare
db32c04 to
a5b26ce
Compare
MikeMcQuaid
reviewed
Feb 13, 2026
Member
MikeMcQuaid
left a comment
There was a problem hiding this comment.
Looks good thanks! Some legit test failures need addressed and this should be good to go.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
brew lgtm(style, typechecking and tests) with your changes locally?cask/artifact/moved.rband identify the misleading log messages. The actual fix was authored and reviewed by the submitter. Style and type checks were run locally.What
When Homebrew has App Management or Full Disk Access permissions, cask upgrades use an in-place content replacement strategy (PR #15138, #15483) that preserves the
.appdirectory inode. macOS then retains Dock position, notification settings, and granted permissions.However, the
ohailog messages inCask::Artifact::Moved#deleteand#movewere printed unconditionally before the strategy branch, so the output always showed:even when the app was never actually removed.
Fix
Move the
ohaicalls into the respective branches:Upgrading App '/Applications/Signal.app' in-placeRemoving AppandMoving Appas before — no change in behaviorNo tests added — this is a log-message-only change with no logic change. No existing tests cover these messages.