nmelhado / league-page

Create a custom league page for your Sleeper fantasy football league!
legends-league.vercel.app
MIT License
196 stars 959 forks source link

[BUG] No league Standings, Trophy Room, Records, or Draft #271

Open wrightc214 opened 10 months ago

wrightc214 commented 10 months ago

Describe the bug The four categories under league info do not display info. Each has it's own error message. Standings: "Preseason, No Standings Yet" Trophy Room: "No seasons have been completed yet, so no awards have been earned..." Records: "No records yet..." Draft: "Hut, Hut, Blue 404!"

Your League ID 921151976868155392

To Reproduce No steps needed to reproduce. Just check my vercel deployment: https://ncaa-pac12.vercel.app/ I have a second deployment of another league that works fine: https://dynastyleagueplus.vercel.app/

Expected behavior I expected league history and standings to be available.

Screenshots If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

Smartphone (please complete the following information):

I don't think it's a browser issue since it occurs on multiple browsers and devices and for other users. Meanwhile, my other league is fine.

Additional context I had another league member look at the page and he sent me the following reply:

My comment assumes that you have some basic coding knowledge, as I'm uncertain about your coding background.

Please consider the following advice with the understanding that I'm a junior developer and not well-versed in JavaScript or this specific framework. Additionally, my IDE isn't set up for working with this framework. However, if you navigate to the following path in the repository: src > lib > Records > index.svelte, on line 123, you'll notice that the "no records yet" message, as seen for the PAC 12 league, is likely due to an empty array of leagueWeekHighs. I've done my best to follow the definitions, but I'm currently using my phone and don't have access to my development machine for a few days.

I suspect the issue arises because somewhere in the code, a combination of functions or objects relies on the presence of a ManagerId. When looking at previous league history, I noticed that there are some seasons where no team owners are present. It's possible that these team owners were removed, but replacements weren't assigned before the league transitioned.

Addressing this issue would require someone who's familiar with the framework to handle this edge case, which the original poster (OP) may not have considered. Alternatively, you could reach out to the OP and request they implement an error check for said edge case.

wrightc214 commented 9 months ago

This issue is likely the same root cause as indicated here: https://github.com/nmelhado/league-page/issues/283

nmelhado commented 3 months ago

This one's tough. If you remove the managers from the teams before transitioning the league, then Sleeper has no data about who did what. There's just no data to tie things back to. There's not much I can do unfortunately to solve this