fix: use sys.executable for radiosonde subprocess to find venv packages

The subprocess was launched with bare 'python' which on Debian doesn't
exist (python3 only) and wouldn't have access to the venv-installed
radiosonde dependencies anyway. Using sys.executable ensures the same
interpreter (with all installed packages) is used.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Smittix
2026-02-27 11:17:19 +00:00
parent 952736c127
commit db2f3fc8e5

View File

@@ -12,6 +12,7 @@ import os
import queue import queue
import shutil import shutil
import socket import socket
import sys
import subprocess import subprocess
import threading import threading
import time import time
@@ -416,7 +417,7 @@ def start_radiosonde():
# Build command # Build command
cfg_dir = os.path.dirname(os.path.abspath(cfg_path)) cfg_dir = os.path.dirname(os.path.abspath(cfg_path))
if auto_rx_path.endswith('.py'): if auto_rx_path.endswith('.py'):
cmd = ['python', auto_rx_path, '-c', cfg_dir] cmd = [sys.executable, auto_rx_path, '-c', cfg_dir]
else: else:
cmd = [auto_rx_path, '-c', cfg_dir] cmd = [auto_rx_path, '-c', cfg_dir]