fix: spawn_test never raises — str-coerce env/command, wrap unexpected errors (#34) #41

Merged
the_og merged 1 commits from fix/34-spawn-test-env into main 2026-07-12 13:00:14 -04:00
Owner

Closes #34.

  • command and env keys/values are str()-coerced before Popen (pasted JSON can legally carry numbers that never round-trip through the editor).
  • spawn_test is now a fail-safe wrapper around _spawn_test_impl: any unexpected exception returns {"outcome": "error", ...} instead of escaping the tester thread — previously the GUI's Test launch / Test all buttons were left permanently disabled because done never fired.
  • New outcome "error" maps to FAILED in health_from_spawn_result and to the generic failure styling in _on_spawn_done (no GUI change needed).
  • 3 new tests: numeric env value round-trip, non-string command, engineered internal error.

166→169 tests pass; ruff check/format clean.

🤖 Generated with Claude Code

Closes #34. - `command` and `env` keys/values are `str()`-coerced before `Popen` (pasted JSON can legally carry numbers that never round-trip through the editor). - `spawn_test` is now a fail-safe wrapper around `_spawn_test_impl`: any unexpected exception returns `{"outcome": "error", ...}` instead of escaping the tester thread — previously the GUI's **Test launch** / **Test all** buttons were left permanently disabled because `done` never fired. - New outcome `"error"` maps to FAILED in `health_from_spawn_result` and to the generic failure styling in `_on_spawn_done` (no GUI change needed). - 3 new tests: numeric env value round-trip, non-string command, engineered internal error. 166→169 tests pass; ruff check/format clean. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
the_og added 1 commit 2026-07-12 12:59:21 -04:00
fix: spawn_test never raises — coerce env/command to str, wrap unexpected errors (#34)
CI / Lint (ruff) (pull_request) Successful in 7s
CI / Tests (py3.10) (pull_request) Successful in 8s
CI / Tests (py3.12) (pull_request) Successful in 8s
c7b2c90518
Closes #34

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
the_og force-pushed fix/34-spawn-test-env from 8309e42dd8 to c7b2c90518 2026-07-12 12:59:21 -04:00 Compare
the_og merged commit 5df364fb2e into main 2026-07-12 13:00:14 -04:00
the_og deleted branch fix/34-spawn-test-env 2026-07-12 13:00:14 -04:00
Sign in to join this conversation.