Repository: pypa/pipx (language: python)

Issue:
Support Python 3.8 in Standalone Python Builds.
<!--
Thank you for filing a bug! Please feel free to answer as much or as little of this template as you can.

Please check pipx's Troubleshooting page to see if any of those solutions help solve your issue:
https://pipx.pypa.io/stable/troubleshooting/
-->

**Describe the bug**

<!-- Please be as detailed as possible! -->

Currently, we do not support Python 3.8 for the standalone python build because we specified the `x86_64_v3` for download links, but according to the official documentation [1]:

> The x86_64_v2, x86_64_v3, and x86_64_v4 binaries usually crash on startup when run on an incompatible CPU. We don’t recommend running the x86_64_v4 builds in production because they likely don’t yield a reliable performance benefit. Unless you are executing these binaries on a CPU older than ~2008 or ~2013, we recommend running the x86_64_v2 or x86_64_v3 binaries, as these should be slightly faster since they take advantage of more modern CPU instructions which are more efficient. But if you want maximum portability, stick with the baseline x86_64 builds.

As mentioned in the last scentence, I think we should stick to the `x86_64` builds.

[1] https://gregoryszorc.com/docs/python-build-standalone/main/running.html?highlight=x86_64_v3#obtaining-distributions

**How to reproduce**

<!-- If possible, include output of `pipx --verbose ...` -->

```shell
$ pipx install --verbose --python 3.8 --fetch-missing-python black
pipx >(setup:924): pipx version is 1.5.0
pipx >(setup:925): Default python interpreter is '/usr/local/pipx/venvs/pipx/bin/python'
⚠ No executable for the provided Python version '3.8' found in the python-build-standalone project. Please make sure the provided version is listed in
    https://github.com/indygreg/python-build-standalone/releases/latest.
```

**Expected behavior**

<!-- What should have happened? -->

Be able to install Python 3.8 with standalone python builds.



Discussion / hints:

Fix patch:
diff --git a/changelog.d/1375.bugfix.md b/changelog.d/1375.bugfix.md
new file mode 100644
index 0000000000..1c37bf7e8f
--- /dev/null
+++ b/changelog.d/1375.bugfix.md
@@ -0,0 +1,1 @@
+Support python3.8 for standalone python builds
diff --git a/src/pipx/standalone_python.py b/src/pipx/standalone_python.py
index 6aa6b5b538..44adc8bd6f 100644
--- a/src/pipx/standalone_python.py
+++ b/src/pipx/standalone_python.py
@@ -33,8 +33,8 @@
             # musl doesn't exist
         },
         "x86_64": {
-            "glibc": "x86_64_v3-unknown-linux-gnu-install_only.tar.gz",
-            "musl": "x86_64_v3-unknown-linux-musl-install_only.tar.gz",
+            "glibc": "x86_64-unknown-linux-gnu-install_only.tar.gz",
+            "musl": "x86_64-unknown-linux-musl-install_only.tar.gz",
         },
     },
     "Windows": {"AMD64": "x86_64-pc-windows-msvc-shared-install_only.tar.gz"},


Test patch:
diff --git a/tests/test_interpreter.py b/tests/test_interpreter.py
index 6201646d89..70d9f557f2 100644
--- a/tests/test_interpreter.py
+++ b/tests/test_interpreter.py
@@ -190,18 +190,12 @@ def which(name):
     minor = sys.version_info.minor
     target_python = f"{major}.{minor}"
 
-    if target_python == "3.8":
-        # 3.8 is not available in the standalone python project
-        with pytest.raises(InterpreterResolutionError) as e:
-            find_python_interpreter(target_python, fetch_missing_python=True)
-            assert "not found" in str(e)
+    python_path = find_python_interpreter(target_python, fetch_missing_python=True)
+    assert python_path is not None
+    assert target_python in python_path
+    assert str(pipx.paths.ctx.standalone_python_cachedir) in python_path
+    if WINDOWS:
+        assert python_path.endswith("python.exe")
     else:
-        python_path = find_python_interpreter(target_python, fetch_missing_python=True)
-        assert python_path is not None
-        assert target_python in python_path
-        assert str(pipx.paths.ctx.standalone_python_cachedir) in python_path
-        if WINDOWS:
-            assert python_path.endswith("python.exe")
-        else:
-            assert python_path.endswith("python3")
-        subprocess.run([python_path, "-c", "import sys; print(sys.executable)"], check=True)
+        assert python_path.endswith("python3")
+    subprocess.run([python_path, "-c", "import sys; print(sys.executable)"], check=True)
diff --git a/tests/test_list.py b/tests/test_list.py
index ecf2940cb3..7b65e898bf 100644
--- a/tests/test_list.py
+++ b/tests/test_list.py
@@ -164,8 +164,7 @@ def which(name):
     monkeypatch.setattr(shutil, "which", which)
 
     major = sys.version_info.major
-    # Minor version 3.8 is not supported for fetching standalone versions
-    minor = sys.version_info.minor if sys.version_info.minor != 8 else 9
+    minor = sys.version_info.minor
     target_python = f"{major}.{minor}"
 
     assert not run_pipx_cli(
diff --git a/tests/test_standalone_interpreter.py b/tests/test_standalone_interpreter.py
index b557ee41a1..36f3ff2ec0 100644
--- a/tests/test_standalone_interpreter.py
+++ b/tests/test_standalone_interpreter.py
@@ -9,8 +9,7 @@
 from pipx import standalone_python
 
 MAJOR_PYTHON_VERSION = sys.version_info.major
-# Minor version 3.8 is not supported for fetching standalone versions
-MINOR_PYTHON_VERSION = sys.version_info.minor if sys.version_info.minor != 8 else 9
+MINOR_PYTHON_VERSION = sys.version_info.minor
 TARGET_PYTHON_VERSION = f"{MAJOR_PYTHON_VERSION}.{MINOR_PYTHON_VERSION}"
 
 original_which = shutil.which