Fix bundle jobs cask deps#22838
Merged
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This pull request fixes brew bundle --jobs=auto parallel installation correctness by ensuring cask formula dependencies are resolved using fully-qualified cask names (including tapped casks), and by making parallel worker results accurately reflect install failures (e.g., lock conflicts).
Changes:
- Resolve cask formula dependencies using each entry’s
full_name(and load cask definitions when the cask isn’t installed yet). - Treat only explicit
trueworker return values as successful parallel installs, sofalseresults correctly fail the bundle run. - Add regression specs covering tapped cask dependency ordering and
falseparallel results.
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| Library/Homebrew/bundle/parallel_installer.rb | Uses cask full_name for dependency resolution and counts only true parallel results as success. |
| Library/Homebrew/bundle/cask.rb | Enhances formula dependency extraction to match installed casks by token/full name and fall back to loading the cask definition when not installed. |
| Library/Homebrew/test/bundle/installer_spec.rb | Adds parallel installer regressions for false results and tapped cask dependency ordering. |
| Library/Homebrew/test/bundle/cask_spec.rb | Adds coverage for resolving formula dependencies from cask definitions when the cask is not installed. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
3239c39 to
8ef717e
Compare
- `brew bundle --jobs=auto` skipped formula deps for casks that were not installed yet, so tapped casks could race formula installs. - Use each cask entry's `full_name` and load the cask definition when no installed cask matches, preserving the installed cask path first. - Prepare `gh` once before parallel workers when attestation checks may otherwise make formula and cask installs race to install the verifier. - Count only `true` worker results as parallel install success so lock failures return a failed bundle status. - Add regressions for tapped cask deps, attestation setup and false parallel results.
8ef717e to
689a69e
Compare
p-linnane
approved these changes
Jun 21, 2026
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.
Fixes #22837
brew bundle --jobs=autoskipped formula deps for casks that were not installed yet, so tapped casks could race formula installs.full_nameand load the cask definition when no installed cask matches, preserving the installed cask path first.trueworker results as parallel install success so lock failures return a failed bundle status.brewcommands to reproduce the bug?brew lgtm(style, typechecking and tests) locally?OpenAI Codex 5.5 xhigh with local review and testing.