From a8b890c85a8d19b83e8786352e297671737aece5 Mon Sep 17 00:00:00 2001 From: Michael Cho Date: Wed, 13 Mar 2024 22:35:46 -0400 Subject: [PATCH] python-requests: deprecate Signed-off-by: Michael Cho --- Formula/p/python-requests.rb | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/Formula/p/python-requests.rb b/Formula/p/python-requests.rb index b23a04bd79153..b5e773111be73 100644 --- a/Formula/p/python-requests.rb +++ b/Formula/p/python-requests.rb @@ -15,7 +15,8 @@ class PythonRequests < Formula sha256 cellar: :any_skip_relocation, x86_64_linux: "38eb54a3c08da5790c7da2dbbe36992772214a7bf2ce87a73b5f58930ec7b0a8" end - depends_on "python-setuptools" => :build + deprecate! date: "2024-03-14", because: "does not meet homebrew/core's requirements for Python library formulae" + depends_on "python@3.11" => [:build, :test] depends_on "python@3.12" => [:build, :test] depends_on "certifi" @@ -30,10 +31,19 @@ def pythons def install pythons.each do |python| python_exe = python.opt_libexec/"bin/python" - system python_exe, "-m", "pip", "install", *std_pip_args, "." + system python_exe, "-m", "pip", "install", *std_pip_args(build_isolation: true), "." end end + def caveats + <<~EOS + Additional details on upcoming formula removal are available at: + * https://github.com/Homebrew/homebrew-core/issues/157500 + * https://docs.brew.sh/Python-for-Formula-Authors#libraries + * https://docs.brew.sh/Homebrew-and-Python#pep-668-python312-and-virtual-environments + EOS + end + test do pythons.each do |python| python_exe = python.opt_libexec/"bin/python"