testsAndMisc/docs/superpowers/evidence/phone-vd-state-dir-2026-11-22.json
Krzysztof kuhy Rudnicki 86cf02bbe7
Some checks are pending
md-naming / markdown naming convention (push) Waiting to run
Pre-commit checks / pre-commit (${{ matrix.group }}) (mypy, mypy) (push) Waiting to run
Pre-commit checks / pre-commit (${{ matrix.group }}) (pylint, pylint) (push) Waiting to run
Pre-commit checks / pre-commit (${{ matrix.group }}) (rest, ) (push) Waiting to run
Pre-commit checks / pre-commit (${{ matrix.group }}) (shellcheck, shellcheck) (push) Waiting to run
Python tests / test (push) Waiting to run
repo-contract / repo contract (push) Waiting to run
Shell tests / shell-tests (push) Waiting to run
Shell tests / lib-tests (push) Waiting to run
Shell tests / arch-tests (push) Waiting to run
Resolve phone_vd state dir without TMPDIR
Mirror phone_vd_dir.sh: PHONE_VD_STATE_DIR, else XDG runtime dir, else /tmp.
Prunes 39 oldest evidence files per check_repo_size.sh --prune.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-22 12:15:50 +01:00

29 lines
1.3 KiB
JSON

{
"intent": "phone_guard.vd_state resolves the virtual-display state directory exactly as phone_vd_dir.sh does, so TMPDIR no longer splits the two sides.",
"scope": [
"python_pkg/phone_guard/vd_state.py (state_root)",
"python_pkg/phone_guard/tests/test_vd_state.py"
],
"changes": [
"state_root: PHONE_VD_STATE_DIR if non-empty, else XDG_RUNTIME_DIR (or /run/user/<uid>) + phone_vd when that dir exists, else /tmp/phone_vd",
"tempfile.gettempdir() and TMPDIR are no longer read for this path",
"Tests: runtime-dir default, TMPDIR independence, override wins, missing runtime dir fallback, unset XDG uses /run/user/<uid>"
],
"verification": [
{
"command": "pytest python_pkg/phone_guard/tests/test_vd_state.py --no-cov",
"result": "pass",
"evidence": "red first: 4 failed, 5 passed against the old TMPDIR rule; green after the change"
},
{
"command": "pytest python_pkg/phone_guard python_pkg/android_ui --no-cov",
"result": "pass",
"evidence": "215 passed; vd_state.py 100% line and branch coverage"
}
],
"risks": [
"A direct caller that relied on TMPDIR for the state directory now reads the runtime dir; the shell side already did"
],
"rollback": ["git revert this commit", "Rerun pytest python_pkg/phone_guard"]
}