Skip to content

fix: switch to network-only with getTotalStake#506

Merged
ECWireless merged 1 commit intomainfrom
504-poll-total-participation-is-incorrect-before-refresh
Jan 21, 2026
Merged

fix: switch to network-only with getTotalStake#506
ECWireless merged 1 commit intomainfrom
504-poll-total-participation-is-incorrect-before-refresh

Conversation

@ECWireless
Copy link
Copy Markdown
Collaborator

When the user selects the voting/governance page, the last poll in the array's stake is cached and used as in calculations for the next individual poll page that is selected. This obviously causes inaccurate data to display. The fix switches the Apollo fetchPolicy to network-only.

Copilot AI review requested due to automatic review settings January 21, 2026 06:05
@ECWireless ECWireless linked an issue Jan 21, 2026 that may be closed by this pull request
@vercel
Copy link
Copy Markdown
Contributor

vercel bot commented Jan 21, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Review Updated (UTC)
explorer-arbitrum-one Ready Ready Preview, Comment Jan 21, 2026 6:05am

Request Review

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR fixes a caching bug in the voting/governance page where Apollo Client's cache was incorrectly serving stale stake data from the last poll when navigating to a different individual poll page. The fix forces fresh data to be fetched from the network.

Changes:

  • Added fetchPolicy: "network-only" to the Apollo query in getTotalStake function to bypass cache

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@ECWireless ECWireless requested a review from Jipperism January 21, 2026 06:19
@ECWireless ECWireless moved this from Backlog to In Review in Explorer Revamp Jan 21, 2026
@github-project-automation github-project-automation bot moved this from In Review to Todo in Explorer Revamp Jan 21, 2026
@Jipperism Jipperism moved this from Todo to In Review in Explorer Revamp Jan 21, 2026
@ECWireless ECWireless merged commit 42cfbf4 into main Jan 21, 2026
13 checks passed
@ECWireless ECWireless deleted the 504-poll-total-participation-is-incorrect-before-refresh branch January 21, 2026 14:50
@github-project-automation github-project-automation bot moved this from In Review to Done in Explorer Revamp Jan 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

No open projects
Status: Done

Development

Successfully merging this pull request may close these issues.

Poll Total Participation is incorrect before refresh

3 participants