Require Python 3.12 for workflow automation

This commit is contained in:
2026-07-13 14:07:14 +02:00
parent eabf2273a7
commit e35e5040a3
5 changed files with 16 additions and 7 deletions

View File

@@ -1,11 +1,18 @@
#!/bin/sh
set -eu
for python in python3.13 python3.12 python3.11; do
if command -v conda >/dev/null 2>&1; then
conda_version=$(conda run -n base python -c 'import sys; print(f"{sys.version_info.major}.{sys.version_info.minor}")' 2>/dev/null || true)
case "$conda_version" in
3.1[2-9]|3.[2-9][0-9]) exec conda run --no-capture-output -n base python "$@" ;;
esac
fi
for python in python3.13 python3.12; do
if command -v "$python" >/dev/null 2>&1; then
exec "$python" "$@"
fi
done
echo "photoanalyzer: Python 3.11 or newer is required" >&2
echo "photoanalyzer: Python 3.12 or newer is required" >&2
exit 2