Open WMRobin opened 5 hours ago
For more context, this issue is not unique to ff_starters()
.
The same issue occurs with espn_potentialpoints()
, so maybe this is a result of something affecting all data for weeks > 1.
To be clear, I get the following output using the same connection as the reprex above:
espn_potentialpoints(conn, week = 1)
# A tibble: 193 × 11
week franchise_id franchise_name franchise_score optimal_slot actual_slot
<int> <int> <chr> <dbl> <chr> <chr>
1 1 1 Pineapple Juice 102. QB QB
2 1 1 Pineapple Juice 102. RB RB
3 1 1 Pineapple Juice 102. RB BE
4 1 1 Pineapple Juice 102. WR BE
5 1 1 Pineapple Juice 102. WR WR
6 1 1 Pineapple Juice 102. TE TE
7 1 1 Pineapple Juice 102. RB/WR/TE RB
8 1 1 Pineapple Juice 102. DST DST
9 1 1 Pineapple Juice 102. K K
10 1 1 Pineapple Juice 102. NA BE
# ℹ 183 more rows
# ℹ 5 more variables: player_score <dbl>, player_name <chr>, player_pos <chr>,
# team <chr>, player_id <int>
# ℹ Use `print(n = ...)` to see more rows
espn_potentialpoints(conn, week = 2)
Error in `map2()`:
ℹ In index: 1.
ℹ With name: 2.
Caused by error in `dplyr::mutate()`:
ℹ In argument: `projected_score = purrr::map2_dbl(...)`.
Caused by error in `purrr::map2_dbl()`:
ℹ In index: 1.
Caused by error in `pluck_raw()`:
! Index 1 must have length 1, not 2.
Run `rlang::last_trace()` to see where the error occurred.
this issue is not unique to ff_starters()
not quite, potentialpoints calls ff_starters as its very first line https://github.com/ffverse/ffscrapr/blob/main/R/espn_potentialpoints.R#L22
There's been a bit of ESPN API wonkiness as of late. I encountered this: https://github.com/cwendt94/espn-api/discussions/575
Describe the bug
The
ff_rosters()
function is not working for my ESPN league, and at least one other individual has had this issue.Reprex Load library and open connection:
I'm using an R project with
current_season
,league_id
,my_espn_2
, andmy_swid
saved to the project's profile.The following code reads my league's rosters for week 1:
However, when doing the same for week 2, I get the following error:
Expected behavior I expected the function to return my league's starters for week 2, as it did for week 1.
Session information Please copy the output of
ffscrapr::ffverse_sitrep()
into the box below.