-
Notifications
You must be signed in to change notification settings - Fork 92
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
Features for reverse calls, notifs, custom-params #88
Conversation
53e73de
to
5abb7ba
Compare
5abb7ba
to
72c92bf
Compare
This is related to filecoin-project/lotus#9863 (comment) |
Reviewer note - reviewing commit-by-commit may be easiest, I tried to put each feature into it's own commit. |
72c92bf
to
da92324
Compare
da92324
to
81b43de
Compare
81b43de
to
36330f4
Compare
// hasCtx is 1 if the function has a context.Context as its first argument. | ||
// Used as the number of the first non-context argument. | ||
hasCtx int |
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.
Thanks for commenting this. Very confusing.
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.
Approved with one question
var t T | ||
err := json.Unmarshal(p, &t) | ||
|
||
// todo also handle list-encoding automagically (json.Unmarshal doesn't do that, does 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.
Do we need this now?
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.
Nope, it's a nice to have, but not needed afaict. The spec doesn't say that endpoints need to support both, so it's up to the endpoint really.
All of the above is needed to make it possible to implement / consume
eth_subscribe
correctly with this library.See rpc_test.go for usage examples.