Commit Graph

2 Commits (1a2d4893972e49372531b3fdd638f3010a6d29d6)

Author SHA1 Message Date
Gud Boi 1a2d489397 Add structured `QtractorSession` lifecycle
Factor nonblocking `start_qtractor()` from the blocking Qt-loop
adapter and expose guest readiness, completion, outcome, and owned
cancellation through `QtractorSession`.

Replace `MainWindow.closeEvent()` process-wide `SIGINT` with the
session shutdown callback. Publish readiness after `_async_main()`
enters all startup scopes, then restore shared Qt state and globals
after guest completion.

Add a headless regression which starts and closes two real Tractor
runtimes under one pytest-owned `QApplication`.

Prompt-IO: ai/prompt-io/opencode/20260903T205404Z_aadfd1cf_prompt_io.md

(this patch was generated in some part by `opencode` using `gpt-5.6-sol` (`openai`))
2026-09-08 11:21:28 -04:00
Gud Boi b1f372bad1 Isolate `Qt` tests from process state
Own XDG config roots before Piker or Qt imports and restore the
caller's process environment when pytest exits.

Also,
- force offscreen rendering through an explicit `--headless` flag
- restore QSettings, config globals and PyQtGraph registries per test
- prove one QApplication can serve repeated tests without state leaks
- document each teardown phase and a future public config-path API

(this patch was generated in some part by `opencode` using `gpt-5.6-sol` (`openai`))
2026-08-31 22:11:27 -04:00