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
add TipSet identity-producing method to various Node interfaces #149
Conversation
Codecov Report
@@ Coverage Diff @@
## master #149 +/- ##
=======================================
Coverage 82.07% 82.07%
=======================================
Files 33 33
Lines 1561 1561
=======================================
Hits 1281 1281
Misses 200 200
Partials 80 80
Continue to review full report at Codecov.
|
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.
LGTM with one question:
is TipsetKey also a type that lives in StorageMiner? Does that mean rather than live in a shared folder here, it should be elevated to specs-actors (the closed thing to a common type repo) so as not to be duplicated? Similarly, should we consider a "common" node adapter for shared functionality? (probably nothing more than this method ATM)
storagemarket/testnodes/testnodes.go
Outdated
} | ||
return &TestStateKey{}, n.MostRecentStateIDError | ||
|
||
return []byte{}, 0, n.MostRecentStateIDError |
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.
we might as well rename this symbol to GetChainHeadError
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.
LGTM, I have no complaints
fc73932
to
adb9a04
Compare
This PR makes incremental progress towards completing this ZenHub issue.
Why does this PR exist?
When a provider or client needs information from the chain, they need to provide a chain state identifier to which their query is scoped. Due to potential reorgs, chain height does not serve as identity for a tipset.
What's in this PR?
This PR changes the signature and name of the existing chain state identity-acquiring method, and adds that method to all
*Node
interfaces which query for (or will query for, in the short future) chain state.