PRAISONAI_DESKTOP_HOME="" no longer makes the Rust shell and the Python engine disagree about where data lives.
Quick Start
1
Set a variable before launch
Export the variable in the shell that starts the app. Most variables pass through to the engine unchanged — but three Python variables are stripped and two are always set for you (see How the engine gets its environment below).
2
Leave api_key blank to use the environment
If you already export
OPENAI_API_KEY, leave the in-app api_key blank and the engine uses the environment value.How the engine gets its environment
The Desktop shell rebuilds the engine’s environment from the resolved venv before spawning it — it does not hand the engine your shell untouched. Most variables pass through unchanged — provider keys (OPENAI_API_KEY, TAVILY_API_KEY), Desktop vars (PRAISONAI_DESKTOP_HOME, PRAISONAI_KEYCHAIN_SERVICE, PRAISONAI_AGENTS_SOURCE, PRAISONAI_TRAIN_CMD, PRAISONAI_MODEL), and platform vars (HOME, APPDATA, XDG_DATA_HOME).
Three variables are stripped by the shell before the engine spawns: PYTHONHOME, PYTHONPATH, PYTHONSTARTUP. Setting them in your shell does nothing for the engine. This is deliberate — they would otherwise redirect the engine’s stdlib or site-packages away from the venv the shell just resolved.
Two variables are always set by the shell: VIRTUAL_ENV (points at the resolved venv root) and PATH (the venv’s bin/Scripts prepended to whatever PATH you exported).
Reference
Data Directory Precedence
The data directory resolves per platform, and an empty variable is skipped rather than joined onto a partial path.Best Practices
Isolate test runs with the keychain service
Isolate test runs with the keychain service
PRAISONAI_DESKTOP_HOME isolates the data directory but not the system keyring, which is shared per user. Set PRAISONAI_KEYCHAIN_SERVICE too, or a test run overwrites the key you actually use.Don't override the UTF-8 exports
Don't override the UTF-8 exports
The shell already sets
PYTHONUTF8=1 and PYTHONIOENCODING=utf-8 so the engine starts on non-English locales. Overriding them reintroduces the startup-timeout bug they fix.Leave api_key blank to inherit provider keys
Leave api_key blank to inherit provider keys
A blank in-app
api_key means “use the environment”. The engine only exports its own key when one is set, and clears only what it exported — so your shell’s OPENAI_API_KEY survives.Point the engine at a local checkout with PRAISONAI_AGENTS_SOURCE, not PYTHONPATH
Point the engine at a local checkout with PRAISONAI_AGENTS_SOURCE, not PYTHONPATH
PYTHONPATH is stripped by design before the engine spawns, so it never reaches the engine. Set PRAISONAI_AGENTS_SOURCE to your praisonaiagents checkout instead — that variable passes through unchanged.Related
Data & Privacy
Where each variable sends your data and secrets
Models & API Keys
How provider keys and
base_url are applied
