lib.App: Pass None default to os.getenv()

The os.getenv() calls in __init__() that read the log and backtrace
defaults mostly pass None as the explicit default value, but the one
for the show-backtrace environment variable relies on the implicit
default.

Pass None explicitly there as well, so that all the calls read the
same way.

Assisted-by: unsloth/Qwen3.8-27B-GGUF:Q4_K_M with pi.dev v0.84.2
Signed-off-by: Jan Lindemann <jan@janware.com>
This commit is contained in:
Jan Lindemann 2026-08-15 00:02:17 +02:00
commit d9cc2f3012
Signed by: Jan Lindemann
GPG key ID: 3750640C9E25DD61

View file

@ -131,7 +131,7 @@ class App: # export
self.__default_log_file = env
self.__back_trace = self._default_show_backtrace(False)
if (env := os.getenv(self._default_show_backtrace_env())) is not None:
if (env := os.getenv(self._default_show_backtrace_env(), None)) is not None:
self.__back_trace = env.lower() in ['1', 'true']
set_log_flags(self.__default_log_flags)