Merge pull request #6830 from MikeMcQuaid/formula-runtime-dependencies-path

formula: handle missing runtime dependency formulae.
This commit is contained in:
Mike McQuaid 2019-12-10 17:16:36 +00:00 committed by GitHub
commit bacb3d0e7e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1546,8 +1546,13 @@ class Formula
Dependency.new full_name
end.compact
end
deps ||= declared_runtime_dependencies unless undeclared
deps ||= (declared_runtime_dependencies | undeclared_runtime_dependencies)
begin
deps ||= declared_runtime_dependencies unless undeclared
deps ||= (declared_runtime_dependencies | undeclared_runtime_dependencies)
rescue FormulaUnavailableError
onoe "could not get runtime dependencies from #{path}!"
deps ||= []
end
deps
end