Private
Public Access
0
0
Commit Graph

3441 Commits

Author SHA1 Message Date
ed b94dd85f14 conductor(plan): Mark phase 1 verification complete 2026-06-17 18:57:04 -04:00
ed 9cdb2edea6 conductor(plan): Mark task 1.3.3 complete 2026-06-17 18:56:30 -04:00
ed 3c13fd718f conductor(plan): Mark task 1.3.1-1.3.3 (truncation fix) complete 2026-06-17 18:56:22 -04:00
ed 6bf8b9119f fix(scripts): render_json no longer truncates per-file list to top 15
The per-file list was truncated to top 15 by default. Files below
the top-15 violation ranking (e.g., the 4 UNCLEAR sites in
outline_tool.py, summarize.py, conductor_tech_lead.py,
openai_compatible.py) were hidden from the per-file output.

The fix changes the default --top from 15 to 200, which exceeds
the current project file count (65 src/ files) and leaves room
for future growth. Users can still pass --top 15 if they want a
truncated view.
2026-06-17 18:56:10 -04:00
ed 373783dedc conductor(plan): Mark task 1.2.3 complete 2026-06-17 18:55:12 -04:00
ed 7c819017d2 conductor(plan): Mark task 1.2.1-1.2.3 (render_json filter fix) complete 2026-06-17 18:55:06 -04:00
ed 737bbee13b fix(scripts): render_json per-file list now includes all findings
The render_json filter excluded INTERNAL_COMPLIANT findings from the
per-file list in non-verbose mode:

    if f.category in VIOLATION_CATEGORIES or f.category in ("UNCLEAR", "INTERNAL_RETHROW")

This meant the 25 newly-classified compliant sites from the review
pass were not visible in the per-file output. Totals were correct
but the per-file list was incomplete.

The fix removes the filter so all findings appear in the per-file
list. The totals already match (they are computed from r.findings
before the per-file filter).
2026-06-17 18:54:52 -04:00
ed 241f5b46ff conductor(plan): Mark task 1.1.1-1.1.3 (visit_Try walker fix) complete 2026-06-17 18:53:44 -04:00
ed eb9b8aad2e fix(scripts): visit_Try walker now visits ALL except handlers
The audit script's visit_Try had a bug where the
\or child in handler.body\ loop was OUTSIDE the
\or handler in node.handlers\ loop. So \handler\ was bound
to the LAST handler, and only the last handler's body was walked.
Raises in non-last except handlers were missed (e.g.,
src/rag_engine.py:31 was not in the audit findings).

The fix moves the inner loop inside the outer loop so each
handler's body is walked. Both the FIRST and LAST handler raises
are now detected.

Adds tests/test_audit_exception_handling_bug_fixes.py with 2
tests for the walker behavior (first-handler raise, middle-handler
raise in a 3-handler try).
2026-06-17 18:53:25 -04:00
ed 92cea9c483 conductor: register result_migration_small_files_20260617 in tracks.md 2026-06-17 18:22:40 -04:00
ed cf3c20d7df docs(track): update result_migration_20260616 umbrella with sub-track 4 +1 site (src/gui_2.py:1349) 2026-06-17 18:22:25 -04:00
ed 5c4244077c conductor(track): metadata + state for result_migration_small_files_20260617 2026-06-17 18:20:24 -04:00
ed 9f9fcf93e1 conductor(track): plan for result_migration_small_files_20260617 2026-06-17 18:20:06 -04:00
ed 0aa00e394d conductor(track): spec for result_migration_small_files_20260617 (sub-track 2 of 5) 2026-06-17 18:19:42 -04:00
ed 87f273d044 Merge branch 'master' of C:\projects\manual_slop into tier2/result_migration_review_pass_20260617 2026-06-17 17:21:27 -04:00
ed dc5e581368 chore(track): archive throw-away scripts for result_migration_review_pass_20260617 (4 helper scripts + sites_to_classify.json) 2026-06-17 17:02:27 -04:00
ed 8be3d52ed1 docs(report): add TRACK_COMPLETION_result_migration_review_pass_20260617 (end-of-track report) 2026-06-17 17:01:19 -04:00
ed 3347926717 conductor(track): mark result_migration_review_pass_20260617 as completed (all 22 tasks done; all 11 test tiers PASS) 2026-06-17 16:58:19 -04:00
ed a6d00f0057 conductor(plan): mark t6_1 and t6_2 complete (audit verified, all 11 test tiers PASS) 2026-06-17 16:55:54 -04:00
ed f6c7a81595 docs(reports): TRACK_COMPLETION_tier2_sandbox_hardening_20260617
End-of-track report for the 4 sandbox bugs hit by the first Tier 2
run (send_result_to_send_20260616) and the audit infrastructure
added to prevent regression. 5 fixes (4 bugs + 1 audit) shipped as
6 atomic commits on master.

See the report for:
- Per-fix description, root cause, and file:line refs
- Live clone state after the fixes
- 38 default-on + 3 opt-in test inventory
- 4 conventions established
- Next steps for the user (re-run, merge review branch, etc.)
- Known follow-ups NOT in this track
2026-06-17 16:35:44 -04:00
ed 7baef97d2c feat(audit): add no-temp-writes audit + regression test
Tier 2 sandbox invariant: no production script under ./scripts/ may
write to the global %TEMP% directory (C:\\Users\\Ed\\AppData\\Local\\
Temp\\). All scratch / intermediate files must live in:
- ./tests/artifacts/  (for test artifacts)
- C:\\Users\\Ed\\AppData\\Local\\manual_slop\\tier2\\  (for app data)

Writing to %TEMP% breaks the sandbox boundary: the OpenCode session
fires the 'ask' prompt for paths outside the project root, halting
autonomous ops (the 2026-06-17 bug with audit_exception_handling.py
output being written to %TEMP% by the agent's shell redirection).

Convention enforcement (per conductor/workflow.md Audit Script Policy):

- scripts/audit_no_temp_writes.py: the canonical audit. Same shape
  as scripts/audit_exception_handling.py: --json for machine output,
  --strict for the CI gate (exits 1 on any violation). Patterns
  cover tempfile module, os.environ['TEMP'], C:\Users\Ed\AppData\Local\Temp, %TEMP%,
  /tmp/, etc. Excludes the throw-away archive at scripts/tier2/
  artifacts/ and itself (so it can find its own pattern defs).

- tests/test_no_temp_writes.py: default-on regression test. Calls
  the audit with --strict and asserts exit 0. If a new script
  under ./scripts/ ever uses %TEMP%, the test fails and CI breaks.

Current state: CLEAN. All 36 tier2 tests pass (1 new + 16 slash
command spec + 13 failcount + 6 opt-in). Sanity-checked: dropping
a fake 'import tempfile' script into ./scripts/ triggered exit 1
with 'FOUND 1 matches: scripts/_test_temp_check/test_uses_temp.py:1:
import tempfile'.

Future: also add a corresponding deny rule to the sandbox bash
permission in a follow-up if needed (already added in 03c9df84 for
the agent's own bash). The audit + test is the structural guard.
2026-06-17 16:30:50 -04:00
ed 428ff64de9 conductor(plan): mark Phase 5 complete (report written + umbrella spec updated) 2026-06-17 16:21:27 -04:00
ed a152903871 docs(track): update result_migration_20260616 with post-review scope (sub-track 4 gains 1 site; all others unchanged) 2026-06-17 16:20:04 -04:00
ed 08faeee7f6 docs(report): add result_migration_review_pass report (43 sites classified, 10 heuristics added, 21 UNCLEAR reclassified) 2026-06-17 16:18:14 -04:00
ed 662b6e8aba conductor(plan): mark Phase 4 complete (10 heuristics added; UNCLEAR 24->3 in review scope) 2026-06-17 16:17:02 -04:00
ed f26091941c feat(scripts): add heuristics to audit_exception_handling for review pass patterns (10 new heuristics + tests) 2026-06-17 16:15:16 -04:00
ed 03c9df8450 fix(tier2): deny %TEMP% writes - use app-data dir for temp files
The Tier 2 agent wrote audit_exception_handling.py output to
C:\\Users\\Ed\\AppData\\Local\\Temp\\audit_initial.json via shell
redirection. This is OUTSIDE the sandbox allowlist (which is
C:\\projects\\manual_slop_tier2 + C:\\Users\\Ed\\AppData\\Local\\
manual_slop\\tier2 + C:\\Users\\Ed\\AppData\\Local\\manual_slop\\
tier2_failures). The OpenCode session-level guard fires the 'ask'
prompt for paths outside the project root, which has no answer in an
autonomous session, so ops halted mid-track.

Fix (3 layers):

1. opencode.json.fragment: add bash deny rule
   '*AppData\\Local\\Temp\\*': 'deny' to BOTH the top-level
   permission.bash (for default agents) and the tier2-autonomous
   agent's permission.bash. The agent physically cannot run shell
   commands that target the global Temp dir.

2. conductor/tier2/agents/tier2-autonomous.md: add 'Temp files'
   convention telling the agent to use
   C:\\Users\\Ed\\AppData\\Local\\manual_slop\\tier2\\ for scratch
   / audit-output / intermediate files, NOT %TEMP%.

3. conductor/tier2/commands/tier-2-auto-execute.md: same convention
   in the slash command so the agent sees it at slash-command time.

Tests (default-on):
- test_agent_denies_temp_writes: agent prompt has the Temp deny in
  frontmatter bash + the app-data dir note
- test_config_fragment_denies_temp_writes: both top-level and agent
  bash have the deny rule

All 16 tier 2 slash command tests pass.

Also: cleaned up the leaked audit_initial.json + audit.json +
audit_after*.json from %TEMP% (they were leftovers from a prior
run). Re-ran setup against the live clone; opencode.json's agent
bash and top-level bash both have the deny rule.
2026-06-17 16:13:19 -04:00
ed 8b954ee180 conductor(plan): mark Phase 3 complete (19 INTERNAL_RETHROW sites classified: 7 PATTERN_1 + 2 PATTERN_2 + 9 compliant + 0 migration-target) 2026-06-17 15:57:33 -04:00
ed 27153d89ea docs(track): result_migration_review_pass decisions for src/warmup.py INTERNAL_RETHROW (1 compliant + 0 migration-target) 2026-06-17 15:56:16 -04:00
ed af47b3eaa2 conductor(plan): mark t3_6 complete (src/models.py INTERNAL_RETHROW review) 2026-06-17 15:55:44 -04:00
ed 9d8be94edf docs(track): result_migration_review_pass decisions for src/models.py INTERNAL_RETHROW (1 compliant + 0 migration-target) 2026-06-17 15:55:10 -04:00
ed 306895f667 conductor(plan): mark t3_5 complete (src/api_hooks.py INTERNAL_RETHROW review) 2026-06-17 15:54:44 -04:00
ed d98f8f92c6 docs(track): result_migration_review_pass decisions for src/api_hooks.py INTERNAL_RETHROW (2 PATTERN_2, same site) 2026-06-17 15:54:13 -04:00
ed e3600545bf conductor(plan): mark t3_4 complete (src/gui_2.py INTERNAL_RETHROW review) 2026-06-17 15:53:37 -04:00
ed 5aef87df28 docs(track): result_migration_review_pass decisions for src/gui_2.py INTERNAL_RETHROW (2 compliant + 0 migration-target) 2026-06-17 15:53:07 -04:00
ed 443946f8b3 conductor(plan): mark t3_3 complete (src/app_controller.py INTERNAL_RETHROW review); add rethrow_sites_compliant metric 2026-06-17 15:52:36 -04:00
ed 98b22b7298 docs(track): result_migration_review_pass decisions for src/app_controller.py INTERNAL_RETHROW (3 compliant + 0 migration-target) 2026-06-17 15:51:56 -04:00
ed 51a45099ef conductor(plan): mark t3_2 complete (src/rag_engine.py INTERNAL_RETHROW review) 2026-06-17 15:51:19 -04:00
ed 7569cc970d docs(track): result_migration_review_pass decisions for src/rag_engine.py INTERNAL_RETHROW (2 PATTERN_1/2 + 2 compliant + 0 migration-target; noted audit script bug) 2026-06-17 15:50:45 -04:00
ed 7804ebd015 conductor(plan): mark t3_1 complete (src/ai_client.py INTERNAL_RETHROW review) 2026-06-17 15:15:10 -04:00
ed 19bc5fb9de docs(track): result_migration_review_pass decisions for src/ai_client.py INTERNAL_RETHROW (6 PATTERN_1, 0 migration-target) 2026-06-17 15:14:39 -04:00
ed 2b34b8fc11 conductor(plan): mark Phase 2 complete (24 UNCLEAR sites reviewed: 23 compliant + 1 migration-target) 2026-06-17 15:12:29 -04:00
ed 4ac5b8ae2d docs(track): result_migration_review_pass decisions for src/multi_agent_conductor.py UNCLEAR (1 compliant + 0 migration-target) 2026-06-17 15:11:43 -04:00
ed 31a40dd9c6 conductor(plan): mark t2_5 complete (src/models.py UNCLEAR review) 2026-06-17 15:10:57 -04:00
ed c9e84c0515 docs(track): result_migration_review_pass decisions for src/models.py UNCLEAR (2 compliant + 0 migration-target) 2026-06-17 15:10:24 -04:00
ed 3119d90170 conductor(plan): mark t2_4 complete (src/app_controller.py UNCLEAR review) 2026-06-17 15:09:57 -04:00
ed 9003cce36f docs(track): result_migration_review_pass decisions for src/app_controller.py UNCLEAR (2 compliant + 0 migration-target) 2026-06-17 15:09:26 -04:00
ed f71af2febe conductor(plan): mark t2_3 complete (src/ai_client.py UNCLEAR review) 2026-06-17 15:08:55 -04:00
ed cf3d88bf65 docs(track): result_migration_review_pass decisions for src/ai_client.py UNCLEAR (2 compliant + 0 migration-target) 2026-06-17 15:08:25 -04:00
ed 91b3337a18 conductor(plan): mark t2_2 complete (src/mcp_client.py UNCLEAR review) 2026-06-17 15:07:32 -04:00