-
Notifications
You must be signed in to change notification settings - Fork 405
Doc and build warning fixes #2068
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
Conversation
Codecov ReportPatch coverage:
📣 This organization is not using Codecov’s GitHub App Integration. We recommend you install it so Codecov can continue to function properly for your repositories. Learn more Additional details and impacted files@@ Coverage Diff @@
## main #2068 +/- ##
==========================================
+ Coverage 87.15% 87.77% +0.61%
==========================================
Files 100 100
Lines 44519 49520 +5001
Branches 44519 49520 +5001
==========================================
+ Hits 38799 43464 +4665
- Misses 5720 6056 +336
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
@@ -132,6 +132,9 @@ impl BlockSourceError { | |||
} | |||
|
|||
/// Converts the error into the underlying error. | |||
/// | |||
/// May contain an [`std::io::Error`] from the [`BlockSource`]. See implementations for further |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This doesnt seem super helpful, it doesn't mention that the block source may well be returning an RpcError
, which I think is the intent behind it. More generally why "may", isn't it does? Maybe we just leave this out and fix the error handling in a followup to just have enums and return proper errors rather than making users downcast several times.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
RpcError
is specific to RpcClient
. Other BlockSource
s don't use it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Right, but that isn't documented anywhere in RpcClient
, which seemed like part of the reason for this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's on RpcClient::call_method
. Let me put it up on the struct docs, too, and explicitly tie it to BlockSource
.
Thanks for fixing the warnings, would be nice to land for 114. |
There are a few warnings left on the |
Ideally we'd fix them, yea, but none of its a huge deal. |
Ah, will do. I just missed |
Many of these are because |
The whole "you must set either no-std or std" thing is really bad rust, its just that cargo's feature flags suck. If we can avoid it, we absolutely should - the "base crate" supports nothing, and then you can optionally turn on std or futures support, but they're separate concepts. There's nothing to "turn on" for no-std, so it shouldn't have a feature flag. |
38d6567
to
345728e
Compare
Makes sense. We probably want separate files for |
LGTM, feel free to squash. |
Some BlockSource implementations provide more error details. Document this in case users want to examine it further.
345728e
to
1d1323a
Compare
LGTM, but we should wait until we're done merging everything so we can rebase and make sure no more warnings slip through. |
No description provided.