Conversation
…g empty getAttestationData was catching all RPC errors and returning undefined, making it impossible for callers to distinguish a genuine empty attestation from a fetch failure. onChainContext then silently reset activeChainProviders to [] with no error state, leaving users with a blank on-chain score and no recovery path (~4k events/wk per Datadog, ~297 distinct sessions). Changes: - getAttestationData now re-throws after logging so callers see the error - onChainContext wraps per-chain fetches in individual try/catch; sets onChainFetchFailed=true when the connected chain fails - onChainFetchFailed is exposed on OnChainContextState - DashboardValidStampsPanel shows "Couldn't load on-chain data / Try again" when onChainFetchFailed is true Fixes holonym-foundation/internal-docs#2543. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Author
|
Closing — this PR targets the holonym-foundation fork which uses a removed onChainContext architecture. The correct target is passportxyz/passport. A new PR will be filed there against the useQueries implementation. See holonym-foundation/internal-docs#2543. |
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.
Summary
getAttestationDatawas swallowing all RPC errors and returningundefined, making it impossible to distinguish a genuine empty attestation from a fetch failureonChainContextthen silently resetactiveChainProvidersto[]— no error state, no retry affordanceChanges
app/utils/onChainStamps.tsgetAttestationDatare-throws after logging — return type narrows fromAttestationData | undefinedtoAttestationDataapp/context/onChainContext.tsxgetAttestationData; setsonChainFetchFailed=truewhen connected chain fails; exposed onOnChainContextStateapp/components/DashboardValidStampsPanel.tsxonChainFetchFailedis trueapp/__test-fixtures__/contextTestHelpers.tsxonChainFetchFailed: falseto test fixtureTest plan
onChainFetchFailedstays false, no error UI shownrpcUrlin chains config — confirm error banner appears with "Try again" buttonreadOnChainDatare-fires and clears the error on successonChainFetchFailedcc @calebtuttle
🤖 Generated with Claude Code