diff --git a/install.ps1 b/install.ps1 index 98a97b42..b1ee9018 100644 --- a/install.ps1 +++ b/install.ps1 @@ -38,7 +38,7 @@ try { } $actual = (Get-FileHash -LiteralPath $temporary -Algorithm SHA256).Hash.ToLowerInvariant() if ($actual -ne $expected.ToLowerInvariant()) { - throw "install.py SHA-256 mismatch." + throw "The downloaded installer does not match its expected fingerprint. Nothing was run and nothing was written. The download was most likely cut short; try again, on another network if possible." } $installer = $temporary } diff --git a/install.sh b/install.sh index fbce14a7..8a26dd5d 100755 --- a/install.sh +++ b/install.sh @@ -56,7 +56,8 @@ if [ -z "$INSTALLER" ] || [ ! -f "$INSTALLER" ]; then elif command -v wget >/dev/null 2>&1; then wget --https-only --output-document="$TEMP_INSTALLER" "$install_url" else - echo "Error: curl or wget is required." >&2 + echo "Error: curl or wget is required to download the installer." >&2 + echo " On Debian or Ubuntu: sudo apt install curl" >&2 exit 1 fi actual_size=$(wc -c < "$TEMP_INSTALLER" | tr -d ' ') @@ -74,7 +75,9 @@ if [ -z "$INSTALLER" ] || [ ! -f "$INSTALLER" ]; then fi expected=$(printf '%s' "$expected" | tr '[:upper:]' '[:lower:]') if [ "$actual" != "$expected" ]; then - echo "Error: install.py SHA-256 mismatch." >&2 + echo "Error: the downloaded installer does not match its expected fingerprint." >&2 + echo " Nothing was run and nothing was written." >&2 + echo " The download was most likely cut short. Try again, on another network if possible." >&2 exit 1 fi INSTALLER="$TEMP_INSTALLER" @@ -89,7 +92,8 @@ for command_name in python3 python; do fi done if [ -z "$PYTHON" ]; then - echo "Error: Python 3 is required." >&2 + echo "Error: Python 3.8 or newer is required." >&2 + echo " Install it, then run this command again. On Debian or Ubuntu: sudo apt install python3" >&2 exit 1 fi diff --git a/wiki/first-install.md b/wiki/first-install.md index b278ac9a..2c3a6199 100644 --- a/wiki/first-install.md +++ b/wiki/first-install.md @@ -148,16 +148,16 @@ its BIOS folder, see [Getting started](getting-started.md). ### Error: Python 3.8 or newer is required. -Python is missing from the machine. On Debian and Ubuntu, `sudo apt install -python3`; on a handheld running Batocera or Recalbox it is already there, so +Python is missing from the machine. The message names the command that installs +it, `sudo apt install python3` on Debian and Ubuntu; on a handheld running Batocera or Recalbox it is already there, so this message usually means the command ran on the computer rather than on the console. -### Error: install.py SHA-256 mismatch. +### Error: the downloaded installer does not match its expected fingerprint. -Nothing was run. The download did not match the fingerprint the script expects, -which is almost always a truncated or intercepted transfer. Running the command -again, on another network if possible, is the answer. +Nothing was run and nothing was written. The download did not match the +fingerprint the script carries, which is almost always a transfer cut short. +Running the command again, on another network if possible, is the answer. ### Cannot create ...