Skip to content

feat: Add set light client start block number - #2786

Merged
yanguoyu merged 2 commits into
nervosnetwork:developfrom
yanguoyu:feat-set-start
Aug 7, 2023
Merged

feat: Add set light client start block number#2786
yanguoyu merged 2 commits into
nervosnetwork:developfrom
yanguoyu:feat-set-start

Conversation

@yanguoyu

Copy link
Copy Markdown
Contributor
  1. Create a new wallet
creat-new-wallet.mov
  1. Import wallet by mnemonic
import-words.mov
  1. Import from Keystore
import_keystore.mov
  1. Import Extended Public Key
import-pbkey.mov
  1. Import Hardware Wallet
import-hardwallet.mov

@Danie0918

Copy link
Copy Markdown

@Keith-CY @homura @WhiteMinds @devchenyan Please review.

Comment thread packages/neuron-ui/src/components/PageContainer/hooks.ts Outdated
Comment thread packages/neuron-ui/src/components/PageContainer/hooks.ts Outdated
Comment thread packages/neuron-ui/src/components/PageContainer/hooks.ts Outdated
Comment thread packages/neuron-ui/src/components/PageContainer/hooks.ts
Comment thread packages/neuron-ui/src/components/PageContainer/hooks.ts
Comment thread packages/neuron-wallet/src/controllers/wallets.ts Outdated
Comment thread packages/neuron-ui/src/services/localCache.ts Outdated
Comment thread packages/neuron-ui/src/locales/zh.json Outdated
Comment thread packages/neuron-ui/src/locales/zh-tw.json Outdated
1. Rename `startBlockNumberInLight` to `startBlockNumber`.
2. Change transaction
3. Better variable name and function name.
@yanguoyu

yanguoyu commented Aug 3, 2023

Copy link
Copy Markdown
Contributor Author

/package
Packaging for test is done in 5747138483. @yanguoyu

@silySuper

silySuper commented Aug 3, 2023

Copy link
Copy Markdown

1.When I click clear light client all data,the block number which is set before will be saved.How can I clear the set block number?

2023-08-03.16.07.38.mov

2.【Import wallet by mnemonic】Set start block number can only operate one time?Second set can not affect,if it can set only once,maybe the button set gray and can not operate after first set.

2023-08-03.16.33.20.mov

3.Does the start block number of one neuron can affect another neuron?

2023-08-03.16.55.02.mov

@Danie0918 @yanguoyu

@yanguoyu

yanguoyu commented Aug 3, 2023

Copy link
Copy Markdown
Contributor Author

1.When I click clear light client all data,the block number which is set before will be saved.How can I clear the set block number?

There is no way to reset the start block number, IMO set the start block number to 0 is the same as reset.

2.【Import wallet by mnemonic】Set start block number can only operate one time?Second set can not affect,if it can set only once,maybe the button set gray and can not operate after first set.

From the video, I see the second setting is success. The light client starts the sync from 650,000. What problem with that?

Does the start block number of one neuron can affect another neuron?

I don't get the point. Every wallet's sync block number is separate. And the start block number is also set for one wallet.

@silySuper

Copy link
Copy Markdown

2.When I set 650000,it changes 610000->621000->650000.In expect ,after I set the start block number,it changes 610000->650000.
3.
The situation:
截屏2023-08-04 12 55 19

When I switch in these four neuron, in expect their change is
截屏2023-08-04 12 59 31

but actually their change are these:firstly show another neuron start block number ,then change to 0->their self start block number.

2023-08-04.13.12.51.mov

@yanguoyu

yanguoyu commented Aug 4, 2023

Copy link
Copy Markdown
Contributor Author

but actually their change are these:firstly show another neuron start block number ,then change to 0->their self start block number.

The start block number is used to set the light client start block, but if your wallet has synced to bigger than the start block number, the start block number is invalid.

@yanguoyu

yanguoyu commented Aug 4, 2023

Copy link
Copy Markdown
Contributor Author

And after setting the start block number, it will cost a few seconds to change the synced block number. So you need to wait for a while then the synced block number will change. @silySuper

@silySuper

Copy link
Copy Markdown

👌

@yanguoyu
yanguoyu added this pull request to the merge queue Aug 7, 2023
Merged via the queue into nervosnetwork:develop with commit 1900ff1 Aug 7, 2023
@yanguoyu
yanguoyu deleted the feat-set-start branch August 7, 2023 07:34
@Keith-CY Keith-CY mentioned this pull request Sep 20, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants