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

Client: RPC Block Retrieval By Portal Network (experimental) #3444

Open
wants to merge 10 commits into
base: master
Choose a base branch
from

Conversation

holgerd77
Copy link
Member

This is a PR on top of the getBlockByPortal branch, since the code is otherwise hard to find.

Copy link

codecov bot commented Jun 1, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 81.46%. Comparing base (d24ca11) to head (dd562c4).
Report is 27 commits behind head on master.

Current head dd562c4 differs from pull request most recent head e62dfe6

Please upload reports for the commit e62dfe6 to get more accurate results.

Additional details and impacted files

Impacted file tree graph

Flag Coverage Δ
blockchain ?
common ?
statemanager ?
util 81.46% <ø> (+0.02%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

@ScottyPoi
Copy link
Contributor

ScottyPoi commented Jun 6, 2024

Can confirm that portal client starts successfully with client start (tsx bin/cli.ts --enablePortal)

Added some logging to the startup within the client info logs
Screenshot from 2024-06-06 03-46-51

@acolytec3
Copy link
Contributor

You can also view all the portal debug logs with the DEBUG=*Portal* environmental variable as well. Works like a charm

@ScottyPoi
Copy link
Contributor

The failing test-all-browser test doesn't look like it has anything to do with the changes made in this PR, so I am reluctant to debug it from here...

@acolytec3
Copy link
Contributor

The failing test-all-browser test doesn't look like it has anything to do with the changes made in this PR, so I am reluctant to debug it from here...

Absolutely no relation. Vitest is broken in some obscure way.

@ScottyPoi
Copy link
Contributor

Take note of changes in
f20434f
and
4fe901a

The --enablePortal option has been renamed to --enablePortalHistory to make room for network config options for other networks.

Also added are radius config options for each network. Keep in mind here that you are setting the exponent for the radius. meaning that a --portalHistoryRadius setting of 250 will result in a node radius of 2^250 -1

The radius for each network defaults to 0. A node with a 0 radius can retrieve and store data, but should not accept gossip. A max radius of 2^256-1 will accept ALL gossip.

@acolytec3
Copy link
Contributor

Is there any value in keeping this open at this point?

@holgerd77
Copy link
Member Author

I cannot judge. I would still be super eager to see Portal Network/Ultralight "in action" withint the client in whatever form, haven't gotten to this point yet. Cannot judge if this PR here is still an appropriate way to achieve this as some PoC or not.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants