Skip to content
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

ENR waku2 field always sets relay to true and others to false #951

Closed
D4nte opened this issue May 4, 2022 · 4 comments
Closed

ENR waku2 field always sets relay to true and others to false #951

D4nte opened this issue May 4, 2022 · 4 comments
Assignees
Labels
bug Something isn't working

Comments

@D4nte
Copy link
Contributor

D4nte commented May 4, 2022

When trying different combination of the --relay, --store, --lightpush and --filter parameters with wakunode v0.9, it seems that the ENR URI displayed in the logs and returned in the info JSON RPC API always set the waku field to relay=true and the rest false.

There are extensive ENR testing in js-waku so I am starting to think the issue is on nwaku side.

See here the test cases against nwaku: https://github.com/status-im/js-waku/blob/11e6f91036563ca415bca8661a9da0a98bcabb8e/src/lib/enr/enr.node.spec.ts

Both Relay + Store and All test cases fail because the result is relay: true and the rest false.

nwaku_ENR_Interop_nwaku_All.log
nwaku_ENR_Interop_nwaku_Relay.log
nwaku_ENR_Interop_nwaku_Relay_+_Store.log

@D4nte D4nte added the bug Something isn't working label May 4, 2022
@D4nte
Copy link
Contributor Author

D4nte commented May 4, 2022

Here are a couple of sample encoded by js-waku to help finding the issue:

all fields set to true:

enr:-IS4QJVLfEAZ8NJSrBZsG5Vj5N5O0Mv9X-8lA-txPAk7TqyyCK-s9UycO3Y5_J7QuQg6GshspV1HaFFQUGsIa1svUpECgmlkgnY0iXNlY3AyNTZrMaEDvI0lrq_uD81GkJDELPxfmX8X1WzqITL1tlmsYp6QHv6Fd2FrdTKIAQEBAQAAAAA

only relay set to true:

enr:-IS4QG4AsPPisSEDQC6kUQmxAu-KhlIHj-_GCKlEAotZQeN3AbwHC12_vCvL41cMeGNo1yhFwOxqe1CD0Pn_1iNEgfYCgmlkgnY0iXNlY3AyNTZrMaEDgB1FBFe2uFUPefSDFWkv15Eqmvjj5Vq7Zz66PncW9GiFd2FrdTKIAQAAAAAAAAA

only store set to true:

enr:-IS4QFzpeULt8QwnTvBZlJdFIhzaybADfj6VVNLcj143R7FhHAa_CZlZGwMintyyY7sESfnq_F5WlVRMdEboTCavkJsCgmlkgnY0iXNlY3AyNTZrMaECvybj-frAZ43FDjqh8yb-XMwfQsfH0PGnTSWO18aQ_liFd2FrdTKIAAEAAAAAAAA

@D4nte
Copy link
Contributor Author

D4nte commented May 4, 2022

js-waku bug.

@D4nte D4nte closed this as completed May 4, 2022
@kaiserd
Copy link
Contributor

kaiserd commented May 4, 2022

In the logs you showed, I can only find a DNS ENR, so I assume discv5 was not active.

The ENRs are

Relay + Store

enr:-KO4QMs915YD8gHiYnIB_b_wq5Me6LqTqd4upOm7yrPXbMIZZ_JMgfKBif6V5084LMkOO3oq2LCvPW6ykt3yiBxQa8EBgmlkgnY0gmlwhH8AAAGKbXVsdGlhZGRyc4wACgR_AAABBh9F3QOJc2VjcDI1NmsxoQO6A2BLBMCgMyigys5mBggiZtCGt-7h5mQuYAQ_DD0yiIN0Y3CCH0SFd2FrdTID

All

enr:-KO4QMs915YD8gHiYnIB_b_wq5Me6LqTqd4upOm7yrPXbMIZZ_JMgfKBif6V5084LMkOO3oq2LCvPW6ykt3yiBxQa8EBgmlkgnY0gmlwhH8AAAGKbXVsdGlhZGRyc4wACgR_AAABBh9F3QOJc2VjcDI1NmsxoQO6A2BLBMCgMyigys5mBggiZtCGt-7h5mQuYAQ_DD0yiIN0Y3CCH0SFd2FrdTID

Relay only

enr:-KO4QP18ugC5KQXW-ZFG5VRYXxs8VZD2Xg0nfAlpQAVXv5wOOi2hPxWOAt8NRsz2nFjxFWS7Yvvkfr5liw-c5Zokl6sBgmlkgnY0gmlwhH8AAAGKbXVsdGlhZGRyc4wACgR_AAABBh9C3QOJc2VjcDI1NmsxoQJmAiRqrmpocPCydF_0HP1QsFbJ0WgbwK217XnIh60V_4N0Y3CCH0GFd2FrdTIB

These all contain the respective flags.

What was the full cmd you ran?
In case you had --discv5-discovery active for some runs, consider there are two ENR versions: see #915.
(This should not cause the problem, just something to be aware of.)

@kaiserd kaiserd self-assigned this May 4, 2022
@D4nte
Copy link
Contributor Author

D4nte commented May 5, 2022

discv5 discovery was not active. Apologies for the waste of time, if it was a fundamental issue on js-waku side. Now fixed and merged.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants