-
Notifications
You must be signed in to change notification settings - Fork 25
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
Check for more required fields #159
Conversation
Will have to dig into this one more deeply. The risk is that we wind up silently ignoring an event which makes it very hard to debug what went wrong. Currently we'd throw an exception that would get logged so would see that something is wrong. I really dislike the whole pipeline and filtering pattern in use though so need to really think through how this fits together. |
src/main/java/org/ethereum/beacon/discovery/pipeline/handler/NextTaskHandler.java
Outdated
Show resolved
Hide resolved
src/main/java/org/ethereum/beacon/discovery/pipeline/handler/MessageHandler.java
Outdated
Show resolved
Hide resolved
src/main/java/org/ethereum/beacon/discovery/pipeline/handler/WhoAreYouPacketHandler.java
Outdated
Show resolved
Hide resolved
src/main/java/org/ethereum/beacon/discovery/pipeline/handler/WhoAreYouPacketHandler.java
Show resolved
Hide resolved
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 just need to work out why circleci didn't run...
PR Description
So for these handlers, I believe these fields should be required. As a rule of thumb, if
envelope.get(FIELD)
is called in the handler,FIELD
should be required, right? For one instance,MessageHandler
, all of the specific message handlers (NodesHandler
,PingHandler
, etc) seem to assume a valid session.