-
Notifications
You must be signed in to change notification settings - Fork 38
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
feat!: extract BatchReturn to batch package, add methods & tests #286
Conversation
For now, I added a note to filecoin-project/lotus#12109 as this being an item for the "Mainnet Upgrade Release" |
2024-07-11 maintainer conversation: this will get merged after the |
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.
I had no idea how bad this had gotten. Thanks for cleaning up
@rvagg @ZenGround0 what's the state of this one? |
I just need to get back to this and get it landed in the next major release .. so 🔜 |
5025381
to
1e30a73
Compare
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #286 +/- ##
==========================================
+ Coverage 3.42% 3.53% +0.10%
==========================================
Files 589 592 +3
Lines 112037 110759 -1278
==========================================
+ Hits 3837 3915 +78
+ Misses 106695 105311 -1384
- Partials 1505 1533 +28
|
1e30a73
to
494117a
Compare
I started off by wanting methods on
BatchReturn
to roughly match what's available in Rust, then I remembered that I was going to add serialization tests for this too because it's in the NI-PoRep path, then I realised that this struct is used in multiple actors and hasn't changed form since it was introduced. In builtin-actors it's in the shared "fil_actors_runtime" package for this very reason. So this PR introduces the same thing here:BatchReturn
andFailCode
into a new "batch" packageBatchReturn
:Size()
,AllOk()
,Codes() []exitcode.ExitCode
,CodeAt(n uint64) exitcode.ExitCode
This is a breaking change because it removes types that were previously there. There are no current direct uses of this type within Lotus today (I'm in the process of introducing one though). This would be a good candidate to ship in a v0.14.0 final I think.