From cf544d40d063752de0b02559efa190e24db3607a Mon Sep 17 00:00:00 2001 From: Cal Corum Date: Sat, 28 Feb 2026 12:09:23 -0600 Subject: [PATCH] store: Fix: Rust sync excluded IL/MiL teams due to active_only=true --- ...mil-teams-due-to-active-onlytrue-5c1148.md | 35 +++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 graph/fixes/fix-rust-sync-excluded-ilmil-teams-due-to-active-onlytrue-5c1148.md diff --git a/graph/fixes/fix-rust-sync-excluded-ilmil-teams-due-to-active-onlytrue-5c1148.md b/graph/fixes/fix-rust-sync-excluded-ilmil-teams-due-to-active-onlytrue-5c1148.md new file mode 100644 index 00000000000..5ae4b91cff7 --- /dev/null +++ b/graph/fixes/fix-rust-sync-excluded-ilmil-teams-due-to-active-onlytrue-5c1148.md @@ -0,0 +1,35 @@ +--- +id: 5c11485a-c808-41b6-8576-a8a388b5be1e +type: fix +title: "Fix: Rust sync excluded IL/MiL teams due to active_only=true" +tags: [sba-scout, rust, sync, bug-fix, api, teams] +importance: 0.7 +confidence: 0.8 +created: "2026-02-28T18:09:23.796074+00:00" +updated: "2026-02-28T18:09:23.796074+00:00" +--- + +# Fix: Rust sync excluded IL/MiL teams due to active_only=true + +## Problem + +The Rust `sync_teams()` function in `api/sync.rs` was calling: + +```rust +client.get_teams(Some(season), None, true, false) +``` + +The `active_only=true` parameter caused the API to exclude IL (e.g. WVIL id=549) and MiL (e.g. WVMiL id=550) teams from the response. The Python sync did not pass `active_only` (defaults to `false`), so it correctly synced all teams. + +## Root Cause + +Mismatch between Rust and Python API call defaults for the `active_only` parameter. + +## Fix + +Changed `active_only` from `true` to `false` in `api/sync.rs`. + +## Notes + +- The `get_all_teams()` DB query in `queries.rs` already filters IL/MiL from the Gameday opponent selector using `WHERE abbrev NOT LIKE '%IL' AND abbrev NOT LIKE '%MiL'`, so syncing them does not pollute the UI. +- Committed as part of `3e73644`.