mirror of
https://github.com/austinried/subtracks.git
synced 2026-11-10 15:11:58 +01:00
17c1ea40a4c50cfd3eb79cdf216821a7fbef8c57
Second review round on the bulk downloads: - The cancel-during-bulk fix had no test, so the invariant it exists for could regress silently. The fake engine can now delay an enqueue, which holds the race window open: the queue loop is kept busy, a cancel is fired mid-queue, and the test asserts the whole list ends up cancelled. Reverting to per-song locking fails it, which I checked. - The per-song catch around the queue loop swallowed CancellationException, so cancelling the caller did not stop the loop. It rethrows now. - The artwork pass skips songs whose row a cancel has already taken. - The lock-hold ceiling is recorded where the lock is taken: cancel latency and the poll tick both scale with the list length, and a per-list cancel generation would lift that if it ever bites. - Tests: an empty list says so, one song failing to enqueue leaves the rest of the list alone, the applyAction test covers Delete as well as Download and Cancel, and the two playlist fixtures share a helper.
Languages
Kotlin
99.1%
Nushell
0.7%
Nix
0.1%