cp.nvim/lua/cp/ui
Barrett Ruth 9f23076420 fix: cancel active process on contest switch
Problem: switching contests while a run, interactive session, or stress
test was in progress left orphaned callbacks and terminal jobs alive.
Running `:CP run` twice also allowed the first run's stale output to
overwrite the buffer after the second run completed.

Solution: replace the `io_view_running` bool in `views.lua` with a
generation counter (`_run_gen`); each `run_io_view` call increments it
and captures a local `gen`, and async callbacks bail out early when `gen
~= _run_gen`. Add `cancel_io_view`, `cancel_interactive` to `views.lua`
and `cancel` to `stress.lua` for forceful teardown without layout
restore. Call these in `setup_contest` whenever `is_new_contest` is true.
2026-03-05 17:37:13 -05:00
..
ansi.lua fix: highlighting 2025-10-23 18:16:36 -04:00
diff.lua fix(scrapers): fix 2025-10-04 15:00:37 -04:00
edit.lua fix(submit): use file path over stdin; fix CF CodeMirror textarea (#305) 2026-03-05 14:34:14 -05:00
highlight.lua feat(highlight): use default highlights 2026-01-27 14:27:41 -05:00
layouts.lua feat: update git formatting 2026-01-27 17:18:52 -05:00
views.lua fix: cancel active process on contest switch 2026-03-05 17:37:13 -05:00