Send leftover picks to the rest client during a live gallery #318

Merged
spark merged 1 commits from task/gitea-317-ud-leiria-rest into main 2026-12-02 19:56:14 +00:00
Owner

Summary

  • A live match no longer waits for every photo to finish analysis before a gallery window that has already closed can send.
  • With gallery sizes and a rest destination, leftover picks go to that destination: all of them until the configured minutes before kick-off, then only a pick of a home-team player. A frame whose faces are still open is tried again.
  • Saving a file-name template can use {frame}, because the sample photo now has a file name.

Closes #317.

Test plan

  • Unit tests for the ten-minute cutoff, a home player, an open face, and an away player
  • Unit tests for a window that is still being analysed
  • API typecheck
  • After deploy, set restHomeFromMin on tonight's event and confirm leftover picks queue to UD Leiria while Liga and ZeroZero keep their gallery sizes
## Summary - A live match no longer waits for every photo to finish analysis before a gallery window that has already closed can send. - With gallery sizes and a rest destination, leftover picks go to that destination: all of them until the configured minutes before kick-off, then only a pick of a home-team player. A frame whose faces are still open is tried again. - Saving a file-name template can use `{frame}`, because the sample photo now has a file name. Closes #317. ## Test plan - [ ] Unit tests for the ten-minute cutoff, a home player, an open face, and an away player - [ ] Unit tests for a window that is still being analysed - [ ] API typecheck - [ ] After deploy, set `restHomeFromMin` on tonight's event and confirm leftover picks queue to UD Leiria while Liga and ZeroZero keep their gallery sizes
spark added 1 commit 2026-12-02 19:40:00 +00:00
Send leftover picks to the rest client during a live gallery.
ci / rust (pull_request) Successful in 3m53s
ci / typescript (pull_request) Successful in 9m27s
6b03ae5d11
Closed windows can leave while later frames are still being analysed. Picks that miss the galleries go to the rest destination: all of them until ten minutes before kick-off, then only home-team players.

Co-authored-by: Cursor <[email protected]>
spark merged commit 5da37adf33 into main 2026-12-02 19:56:14 +00:00
Sign in to join this conversation.