1.5 KiB
1.5 KiB
| id | type | title | tags | importance | confidence | created | updated | relations | ||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 1fca0ae0-681e-4755-b16c-e5661639c6ef | fix | Fix: get_one_player CSV missing data row — to_csv() called before append() |
|
0.6 | 0.8 | 2026-03-04T02:32:17.214021+00:00 | 2026-03-04T02:32:18.788103+00:00 |
|
Problem
get_one_player in app/routers_v2/players.py returned a CSV response containing only the header row — player data was never included.
Root Cause
return_val = DataFrame(data_list).to_csv(header=False, index=False) was called on line 625 when data_list contained only the header list. The player data row was appended to data_list on line 626 — after the CSV was already computed.
Solution
Moved the to_csv() call to after data_list.append(player_row). Single-line swap, no logic changes.
Files Changed
app/routers_v2/players.py(~line 625-651)
PR
cal/paper-dynasty-database#51 (issue #12)