Closed mcarman8 closed 2 years ago
This is related/duplicate to ffverse/ffscrapr#364 and involves a recent nflreadr problem with rosters
Resolved in nflverse/nflfastR-roster#47
R> library(ffscrapr)
R> season=2022 #NFL Season
R> league_id=793392140196614144 #Your sleeper league_id
R> conn <- sleeper_connect(season,league_id);
R> league_info <- ffscrapr::ff_league(conn)
R> print("madeit")
[1] "madeit"
R> scoring_history <- ffscrapr::ff_scoringhistory(conn, seasons=2012:(season-1))
R> print("didnt make it")
[1] "didnt make it"
R> scoring_history
# A tibble: 115,540 × 38
season week gsis_id sportradar_id sleeper_id player_name pos team points
<int> <int> <chr> <chr> <chr> <chr> <chr> <chr> <dbl>
1 1999 11 00-0016479 NA NA Pat Tillman DB ARI 0
2 1999 4 00-0001907 NA NA Dave Brown QB ARI 1.2
3 1999 5 00-0001907 NA NA Dave Brown QB ARI 1.64
4 1999 6 00-0001907 NA NA Dave Brown QB ARI 7.28
5 1999 8 00-0001907 NA NA Dave Brown QB ARI 0.28
6 1999 9 00-0001907 NA NA Dave Brown QB ARI 8.26
7 1999 10 00-0001907 NA NA Dave Brown QB ARI 10.3
8 1999 11 00-0001907 NA NA Dave Brown QB ARI 6.3
9 1999 12 00-0001907 NA NA Dave Brown QB ARI 4.44
10 1999 8 00-0006410 NA NA Chris Greisen QB ARI 0.16
# … with 115,530 more rows, and 29 more variables: receiving_fumbles_lost <dbl>,
# rushing_fumbles_lost <dbl>, sack_fumbles_lost <dbl>, interceptions <dbl>,
# passing_2pt_conversions <dbl>, passing_tds <dbl>, passing_yards <dbl>,
# receiving_2pt_conversions <dbl>, receiving_tds <dbl>, receiving_yards <dbl>,
# receptions <dbl>, rushing_2pt_conversions <dbl>, rushing_tds <dbl>,
# rushing_yards <dbl>, fg_made_0_19 <dbl>, fg_made_20_29 <dbl>, fg_made_30_39 <dbl>,
# fg_made_40_49 <dbl>, fg_made_50_59 <dbl>, fg_made_60_ <dbl>, fg_missed <dbl>, …
Describe the bug Yesterday everything was working fine, but today ff_scoringhistory throws one of two errors, screenshots attached. Maybe an api or weekly data update changed/failed? It fails with multiple leagues. It throws the "warning" error if the seasons parameter is not explicitly defined, and throws the "error" error when seasons is explicitly defined.
Reprex To get "warning" error:
To get "error" error:
Expected behavior No errors and a scoring_history object is properly created
Session information
Screenshots "Warning" error: "Error" error: