piker/ai/prompt-io/opencode/20260903T205404Z_aadfd1cf_p...

60 lines
2.6 KiB
Markdown

---
model: openai/gpt-5.6-sol
service: opencode
session: ses_faae5c497ffeS0ofaTEfbRo2LP
timestamp: 2026-09-03T20:54:04Z
git_ref: aadfd1cf
scope: code
substantive: true
raw_file: 20260903T205404Z_aadfd1cf_prompt_io.raw.md
---
## Prompt
Continue from the completed replay handoff when next steps are clear.
Honor the prior decision to park replay and begin the live-backend-first
chart E2E roadmap with the Phase A Qt/Trio lifecycle seam. First perform
the approved exhaustive local scan, then create
`wkt/live_chart_qtractor` from exact Phase 1 commit `aadfd1cf` and
implement nonblocking startup, structured shutdown, observable readiness
and completion, and provider-independent lifecycle coverage without new
interlayer mocks.
## Response summary
Creates the isolated worktree after classifying two stale historical
lifecycle experiments as related but not reusable. Extracts
`start_qtractor()` and `QtractorSession`, replaces process-wide SIGINT on
window close with owned Trio cancellation, publishes application
readiness at the full `_async_main()` startup boundary, and preserves
`run_qtractor()` as the blocking Qt-loop owner which unwraps the guest
outcome. A headless regression proves two sequential real Tractor
runtimes start and stop cleanly under one pytest-owned Qt application.
## Files changed
- `piker/ui/_exec.py` - add nonblocking session startup, lifecycle
signals, owned cancellation, outcome capture, Qt cleanup, and the
blocking CLI adapter.
- `piker/ui/_window.py` - inject structured shutdown and remove normal
window-close SIGINT while cleaning the global zoom filter.
- `piker/ui/_app.py` - publish readiness after all application startup
scopes are live.
- `tests/ui/test_qtractor.py` - prove repeated real-Tractor lifecycle
startup and close under pytest-qt.
## Human edits
The human chose exhaustive local discovery specifically to catch prior
Qt/Trio experiments, confirmed the replay branch had been pushed to
Gitea for backup, and directed continuation without another planning
pause. The inherited human-approved roadmap parks replay, prioritizes a
real Kraken chart, forbids additional interlayer mocks without a concrete
regression, and fixes `aadfd1cf` as this worktree's base. The human also
explicitly authorized the focused headless test through `nix develop`;
no real-compositor run was authorized or performed. During final review,
the human corrected nonconforming boolean layout, requested local type
annotations wherever helper return types were not obvious at the binding,
and replaced silent Qt disconnect suppression with Piker-style exception
logging.