From faf57741a124444d79e03d318c8f32c90457930c Mon Sep 17 00:00:00 2001 From: Smittix Date: Sat, 14 Mar 2026 15:44:48 +0000 Subject: [PATCH] v2.26.4: fix Environment Configurator crash when .env variable missing (#191) read_env_var() grep pipeline failed under set -euo pipefail when .env existed but didn't contain the requested key. grep returned 1 (no match), pipefail propagated it, and set -e killed the script. Co-Authored-By: Claude Opus 4.6 --- CHANGELOG.md | 7 +++++++ config.py | 9 ++++++++- pyproject.toml | 2 +- setup.sh | 2 +- 4 files changed, 17 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 8328ed2..91f9658 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,13 @@ All notable changes to iNTERCEPT will be documented in this file. +## [2.26.4] - 2026-03-14 + +### Fixed +- **Environment Configurator crash** — `read_env_var()` crashed with "Setup failed at line 2333" when `.env` existed but didn't contain the variable being looked up. `grep` returned exit code 1 (no match), which `pipefail` propagated and `set -e` turned into a fatal error. Fixed by appending `|| true` to the pipeline. (#191) + +--- + ## [2.26.3] - 2026-03-13 ### Fixed diff --git a/config.py b/config.py index 3de94c3..7d1cf6d 100644 --- a/config.py +++ b/config.py @@ -7,10 +7,17 @@ import os import sys # Application version -VERSION = "2.26.3" +VERSION = "2.26.4" # Changelog - latest release notes (shown on welcome screen) CHANGELOG = [ + { + "version": "2.26.4", + "date": "March 2026", + "highlights": [ + "Fix Environment Configurator crash when .env exists but variable is missing", + ] + }, { "version": "2.26.3", "date": "March 2026", diff --git a/pyproject.toml b/pyproject.toml index 9e23c61..60029ad 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "intercept" -version = "2.26.3" +version = "2.26.4" description = "Signal Intelligence Platform - Pager/433MHz/ADS-B/Satellite/WiFi/Bluetooth" readme = "README.md" requires-python = ">=3.9" diff --git a/setup.sh b/setup.sh index 16c1153..31f8a65 100755 --- a/setup.sh +++ b/setup.sh @@ -174,7 +174,7 @@ read_env_var() { local fallback="${2:-}" if [[ -f "$SCRIPT_DIR/.env" ]]; then local val - val=$(grep -E "^${key}=" "$SCRIPT_DIR/.env" 2>/dev/null | tail -1 | cut -d'=' -f2-) + val=$(grep -E "^${key}=" "$SCRIPT_DIR/.env" 2>/dev/null | tail -1 | cut -d'=' -f2- || true) if [[ -n "$val" ]]; then # Strip surrounding quotes val="${val#\"}"