DAO-1983 (C3/6): Migrate hooks — collective rewards & fund (batch 1)#2094
Open
TravellerOnTheRun wants to merge 1 commit into
Open
DAO-1983 (C3/6): Migrate hooks — collective rewards & fund (batch 1)#2094TravellerOnTheRun wants to merge 1 commit into
TravellerOnTheRun wants to merge 1 commit into
Conversation
… (DAO-1983 C3/6) Stop passing AVERAGE_BLOCKTIME; inherit QueryClient default. Explicit refetchInterval: false where queries are API-backed or should not poll.
Dependency Review✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.Snapshot WarningsEnsure that dependencies are being submitted on PR branches and consider enabling retry-on-snapshot-warnings. See the documentation for more information and troubleshooting advice. Scanned FilesNone |
cybervoid0
reviewed
Apr 14, 2026
| import { useEffect, useState } from 'react' | ||
|
|
||
| import { AVERAGE_BLOCKTIME } from '@/lib/constants' | ||
| import { useBlockTime } from '@/shared/context/BlockTimeContext' |
Contributor
There was a problem hiding this comment.
are you sure you wrapped this into a provider necessary for t his hook
cybervoid0
reviewed
Apr 14, 2026
| args: [address!], | ||
| query: { | ||
| refetchInterval: AVERAGE_BLOCKTIME, | ||
| }, |
Contributor
There was a problem hiding this comment.
Removing refetchInterval assumes the global QueryClient default is applied here. Can you confirm this hook picks up that default? Otherwise polling stops entirely.
cybervoid0
approved these changes
Apr 14, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
Once defaults come from real block time, hooks should stop repeating the old
AVERAGE_BLOCKTIMEimport. This batch migrates the first set of collective-rewards and related hooks to inherit the QueryClient default, and usesrefetchInterval: falsewhere a query is backed by our HTTP APIs or should not poll on a timer.What to check
Stack
C3 builds on C2 (provider + defaults). Merge after C2 is on your target branch.