- This also required auto-fixes for Layout/EmptyLinesAroundBlockBody and
Layout/InconsistentIndentation once the auto-fixer had got rid of the
"redundant begin"s.
This has been a nightmare in terms of the complexity to our dependency
system and the whack-a-mole required on bugs. If a Requirement resolves
to a Formula it should just use `depends_on "formula"` instead. This
matches the effective behaviour all users of bottles (the vast majority
of users and installs) and what we're doing in Homebrew/homebrew-core.
This is useful for seeing when formulae are deleted if they are going to
leave behind any formulae that depend on them.
As a result, if there are any formulae returned return a non-zero/failed
exit status.
This is a temporary measure until:
- #1862 is merged
- I can a test on `brew uses` against every formula in the official
taps to verify that exceptions are no longer raised.
Fixes#1848 by sharing recursive dependency resolution between
dependencies and requirements.
Coincidentally, this also fixes the errors introduced by #1784 that
necessitated it being reverted in #1797.
Fixes#1776.
If any known formula had a dependency on an untapped tap,
Formula#recursive_dependencies would throw an exception, which would be
caught by the outer exception handler, causing the rest of the
dependencies for that formula to be skipped and incomplete output to be
generated.
To fix this, I added a check to avoid analysing the dependencies of
formulae from uninstalled taps.
Additionally, I removed the aforementioned outer exception handler added
in 5fdb89aed90f03413cdb21af430411c4a722876e, because the only other
place that should be capable of throwing such an exception is the
statement that was surrounded by another wider exception handler in
Homebrew/legacy-homebrew#40682.