Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix team event navigation sometimes loading the wrong event data #982

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

bherbst
Copy link
Contributor

@bherbst bherbst commented Nov 20, 2024

Summary:
Navigating to a Team at Event page from the team event list would sometimes load data from the incorrect event.

This occured due to a combinatino of two things:

  • Something wonky is happening between the API response, HTTP cache, and DB cache resulting in updateEventsParticipated() getting called multiple times with different event lists.
  • When searching for our currently selected event in that event list, we default to an index of 0, and if the event is not in the list we merrily proceed with that default 0 index, resulting in us showing the incorrect data.

Issues Reference:
Fixes #973
Fixes #964

Test Plan:
Repro steps in #973 mostly worked for me; note that there's some odd cache behavior happening here that needs to happen. When I observed this occurring we had database-cached responses that had a different set of events for the team than the API provided. The reproduction steps weren't 100% consistent, but consistent enough.

In theory this should self-resolve, but the API responses were coming from our HTTP cache and we explicitly don't write to the DB cache if the API response is coming from the HTTP cache. There's a lot to unpack there still.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[BUG] Event selection not going to the correct event Team@Event Clicks Are Wonky
1 participant