Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

audit: do not allow to use the python@2 formula #6894

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Library/Homebrew/dev-cmd/audit.rb
Original file line number Diff line number Diff line change
Expand Up @@ -386,7 +386,7 @@ def audit_deps
if @new_formula &&
dep_f.keg_only_reason&.reason == :provided_by_macos &&
dep_f.keg_only_reason.valid? &&
!%w[apr apr-util openblas openssl openssl@1.1].include?(dep.name)
!%w[apr apr-util openblas openssl openssl@1.1 python@2].include?(dep.name)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a whitelist, not a blacklist.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah, this section is about whitelisting keg-only dependencies, and I don't think python@2 is keg-only

perhaps it would be better to copy what is done to blacklist depending on git?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Might be also worth porting that to reference uses_from_macos and providing an opt-out for relevant formulae depending on Git

new_formula_problem(
"Dependency '#{dep.name}' is provided by macOS; " \
"please replace 'depends_on' with 'uses_from_macos'.",
Expand Down