-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
light client cannot work when the number of validators is equal 100 #6010
Comments
This was referenced Jan 29, 2021
melekes
added
C:light
Component: Light
T:bug-unconfirmed
Type Bug (has been reported but not verified or triaged)
labels
Feb 1, 2021
melekes
added
T:bug
Type Bug (Confirmed)
and removed
T:bug-unconfirmed
Type Bug (has been reported but not verified or triaged)
labels
Feb 1, 2021
melekes
added a commit
that referenced
this issue
Feb 1, 2021
also, restrict the number of pages to avoid iterating forever Closes #6010
melekes
added a commit
that referenced
this issue
Feb 1, 2021
also, restrict the number of pages to avoid iterating forever Closes #6010 - rpc/client: change timeout type to be time.Duration in NewWithTimeout - light/provider/http: set 5s timeout for all requests to avoid blocking forever
melekes
added a commit
that referenced
this issue
Feb 1, 2021
melekes
added a commit
that referenced
this issue
Feb 4, 2021
melekes
added a commit
that referenced
this issue
Feb 4, 2021
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Tendermint version (use
tendermint version
orgit rev-parse --verify HEAD
if installed from source):unreleased-master-b1646e51e263d579b4cc522668b4a2b81c1f56bd(v0.34.*)
What happened:
If the number of validators is equal
100
(defined by maxPerPage), the light client cannot work.How to reproduce it
Option 1: Modify
maxPerPage
to1
and run a network with one validator, https://github.com/chengwenxi/tendermint/tree/vincent-maxPerPage-1run a testnet network
run a light client proxy server
It will be stuck for a long time and then return the following error:
Option 2: Use an existing network with 100 validators. The IRISnet bifrost testnet that based on tendermint@v0.34.1 and the validators has reached 100, we can access it by public node
34.80.22.255:26657
.It returns the same error as
Option 1
.Why happened:
In function validatorSet,
we retry call
p.client.Validators
to get all validators by pages, if thelen(validatorSet) = maxPerPage
,p.client.Validators
will returnpage should be within [1, {total_page}] range, {page}
, see https://github.com/tendermint/tendermint/blob/master/rpc/core/env.go#L111.Proposal
Minor fix: ignore this error in function validatorSet.
The text was updated successfully, but these errors were encountered: