Skip to content

Uses rpc's client_error::Error::kind() in more places#6292

Merged
brooksprumo merged 1 commit intoanza-xyz:masterfrom
brooksprumo:rpc/kind
May 23, 2025
Merged

Uses rpc's client_error::Error::kind() in more places#6292
brooksprumo merged 1 commit intoanza-xyz:masterfrom
brooksprumo:rpc/kind

Conversation

@brooksprumo
Copy link
Copy Markdown

Problem

If/when we change rpc's client_error::Error::kind field from ErrorKind to Box<ErrorKind>, there are miscellaneous uses of kind that need to be updated (as expected). It turns out that many uses of kind actually want a reference, i.e. &ErrorKind. There's also already a function on client_error::Error that does just this: Error::kind(). So we can/should use that function instead, which means fewer changes later when modifying the underlying kind type.

Please see #6290 (comment) for the full context.

Summary of Changes

Use kind() in more places.

@brooksprumo brooksprumo self-assigned this May 22, 2025
@brooksprumo brooksprumo marked this pull request as ready for review May 22, 2025 19:55
@brooksprumo brooksprumo requested a review from yihau May 22, 2025 19:55
@codecov-commenter
Copy link
Copy Markdown

Codecov Report

Attention: Patch coverage is 25.00000% with 3 lines in your changes missing coverage. Please review.

Project coverage is 82.7%. Comparing base (640a749) to head (f481ef5).

Additional details and impacted files
@@           Coverage Diff            @@
##           master    #6292    +/-   ##
========================================
  Coverage    82.7%    82.7%            
========================================
  Files         845      845            
  Lines      377813   377813            
========================================
+ Hits       312659   312814   +155     
+ Misses      65154    64999   -155     
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@brooksprumo brooksprumo merged commit 5369147 into anza-xyz:master May 23, 2025
56 checks passed
@brooksprumo brooksprumo deleted the rpc/kind branch May 23, 2025 14:03
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.

3 participants