mirror of
https://github.com/gosticks/brew.git
synced 2026-08-16 06:30:23 +00:00
language/python: raise if we can't detect the Python to use for venv
This commit is contained in:
@@ -182,6 +182,7 @@ module Language
|
||||
if python.nil?
|
||||
pythons = %w[python python3 python@3 python@3.7 python@3.8 pypy pypy3]
|
||||
wanted = pythons.select { |py| needs_python?(py) }
|
||||
raise FormulaUnknownPythonError, self if wanted.empty?
|
||||
raise FormulaAmbiguousPythonError, self if wanted.size > 1
|
||||
|
||||
python = wanted.first
|
||||
|
||||
Reference in New Issue
Block a user