SDK: drop python3.8 bootstrap workarounds

- make_chroot: remove python-exec rewrite. The bootstrap SDK no longer
  has 3.8, so python-exec will already be python3.13.
- chroot_version_hooks: make 228 a nop. The purge is no longer needed,
  but SDKs record chroot version 228, so the file has to exist.

BUG=b/582685887
TEST=presubmit
RELEASE_NOTE=None

cos-patch: bug
Change-Id: Ibe86779bd24b4fefc737aaf6d99ff4b52eeb4ec5
Reviewed-on: https://cos-review.googlesource.com/c/third_party/platform/crosutils/+/239406
Reviewed-by: Robert Kolchmeyer <rkolchmeyer@google.com>
Tested-by: Cusky Presubmit Bot <presubmit@cos-infra-prod.iam.gserviceaccount.com>
diff --git a/chroot_version_hooks.d/228_purge_py38_sdk b/chroot_version_hooks.d/228_purge_py38_sdk
index 9a81dd2..9cc4770 100644
--- a/chroot_version_hooks.d/228_purge_py38_sdk
+++ b/chroot_version_hooks.d/228_purge_py38_sdk
@@ -10,23 +10,8 @@
 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
 # GNU General Public License for more details.
 
-# Clean up python packages dropped from the SDK as part of moving the SDK
-# from python3.8 to python3.13 (b/582685887). These do not work on
-# python3.13 and nothing in the SDK depends on them anymore. `gsutil` in the
-# chroot now resolves to chromite/bin/gsutil.
-pkgs=(
-  dev-python/future
-  dev-python/gcs-oauth2-boto-plugin
-  dev-python/google-apitools
-  dev-python/google-reauth-python
-  dev-python/keyring
-  dev-python/oauth2client
-  dev-python/pyshark
-  dev-python/python-evdev
-  dev-python/secretstorage
-  net-misc/gsutil
-)
-mapfile -t installed_pkgs < <(qlist -eICS "${pkgs[@]}" || :)
-if [[ ${#installed_pkgs[@]} -gt 0 ]]; then
-  sudo emerge --rage -q "${installed_pkgs[@]}"
-fi
+# This hook is used to unmerge python packages dropped from the
+# 3.8 to  3.13 python transition. Newer SDKs and bootstrap SDKs
+# only ship 3.13, so there is nothing left to remove. The file
+# has to stay since the SDKs record chroot version 228 and
+# chromite needs a hook for the newest recorded version.
diff --git a/sdk_lib/make_chroot.sh b/sdk_lib/make_chroot.sh
index 9725a55..5c8adcf 100755
--- a/sdk_lib/make_chroot.sh
+++ b/sdk_lib/make_chroot.sh
@@ -211,13 +211,6 @@
 if [[ "${FLAGS_skip_chroot_upgrade}" -eq "${FLAGS_FALSE}" ]]; then
   info "Updating portage"
   early_enter_chroot emerge -uNv --quiet --ignore-world portage
-
-  # The seed SDK's python-exec config prefers python3.8, but portage was
-  # just rebuilt for the SDK's PYTHON_TARGETS (python3.13 only). Point
-  # python-exec at python3.13 so scripts with a python3 shebang (chromite
-  # tools, install hooks) can import portage.
-  early_enter_chroot sed -i -e '$a python3.13' \
-    -e '/^-\{0,1\}python[0-9.]*$/d' /etc/python-exec/python-exec.conf
 fi
 # Add chromite into python path.
 for python_path in "${FLAGS_chroot}/usr/lib/"python*.*; do