From 0528c3e3f2c2c56db1420d8963b8f8d9db7716f7 Mon Sep 17 00:00:00 2001 From: Ed_ Date: Thu, 18 Jun 2026 14:40:04 -0400 Subject: [PATCH] test(tier2): no_temp_writes - replace AppData refs in docstring + fix Updated tests/test_no_temp_writes.py to match the 2026-06-18 reversal: - Docstring no longer mentions C:\\Users\\Ed\\AppData\\Local\\manual_slop\\tier2 or \\...\\tier2_failures as the allowed scratch dirs; the new allowed dirs are scripts/tier2/state/ and scripts/tier2/failures/ (inside the clone). - Failure-message fix string no longer suggests C:\\Users\\Ed\\AppData\\Local\\manual_slop\\tier2\\ as a target. Per the user's 2026-06-18 'NEVER USE APPDATA' directive. Refs: conductor/tracks/tier2_no_appdata_20260618 --- tests/test_no_temp_writes.py | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/tests/test_no_temp_writes.py b/tests/test_no_temp_writes.py index 5b62001d..8121338f 100644 --- a/tests/test_no_temp_writes.py +++ b/tests/test_no_temp_writes.py @@ -2,13 +2,19 @@ the global %TEMP% directory (C:\\Users\\Ed\\AppData\\Local\\Temp\\). The Tier 2 sandbox is supposed to keep all scratch / intermediate -files inside its allowlist (C:\\projects\\manual_slop_tier2 + -C:\\Users\\Ed\\AppData\\Local\\manual_slop\\tier2 + -C:\\Users\\Ed\\AppData\\Local\\manual_slop\\tier2_failures). Writing -to the global Temp dir breaks that boundary: the OpenCode session -fires the 'ask' prompt for paths outside the project root, halting +files inside the Tier 2 clone (C:\\projects\\manual_slop_tier2 + +scripts/tier2/state/ + scripts/tier2/failures/). Writing to the +global Temp dir breaks that boundary: the OpenCode session fires +the 'ask' prompt for paths outside the project root, halting autonomous ops. +Per the user's 2026-06-18 'NEVER USE APPDATA' directive, Tier 2 +state and failure reports no longer live under +C:\\Users\\Ed\\AppData\\Local\\manual_slop\\tier2\\ or +C:\\Users\\Ed\\AppData\\Local\\manual_slop\\tier2_failures\\; they +live inside the clone under scripts/tier2/state/ and +scripts/tier2/failures/. + The test delegates to scripts/audit_no_temp_writes.py --strict which exits 1 on any violation. If this test fails, a new script under ./scripts/ is using %TEMP% and the Tier 2 sandbox boundary @@ -30,6 +36,6 @@ def test_no_script_emits_to_temp() -> None: assert result.returncode == 0, ( f"audit found %TEMP% usage in scripts:\n{result.stdout}\n{result.stderr}\n\n" f"Fix: move scratch files to tests/artifacts/ or " - f"C:\\Users\\Ed\\AppData\\Local\\manual_slop\\tier2\\ instead of %TEMP%." + f"scripts/tier2/state/ or scripts/tier2/failures/ instead of %TEMP%." ) assert "CLEAN" in result.stdout, f"unexpected audit output: {result.stdout}"