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

feat: Supports amend transactions #3134

Merged
merged 11 commits into from
May 20, 2024
Merged

feat: Supports amend transactions #3134

merged 11 commits into from
May 20, 2024

Conversation

devchenyan
Copy link
Collaborator

@devchenyan devchenyan commented Apr 19, 2024

@Danie0918
Copy link
Collaborator

@devchenyan Please review the above comments.

@Danie0918
Copy link
Collaborator

@homura @yanguoyu Please have a review.

@Danie0918
Copy link
Collaborator

@Keith-CY @homura Please have a review.

@silySuper
Copy link
Collaborator

silySuper commented May 8, 2024

/package

Packaging for test is done in 8994883540. @silySuper

@devchenyan devchenyan requested a review from Keith-CY May 11, 2024 04:37
@silySuper
Copy link
Collaborator

silySuper commented May 14, 2024

/package
Packaging for test is done in 9072896666. @silySuper

@silySuper
Copy link
Collaborator

Please merge latest code to this branch to sync normally @Keith-CY @devchenyan

@Keith-CY
Copy link
Collaborator

Please merge latest code to this branch to sync normally @Keith-CY @devchenyan

Conflicted @devchenyan

@Keith-CY
Copy link
Collaborator

Please merge latest code to this branch to sync normally @Keith-CY @devchenyan

Merged

@Keith-CY
Copy link
Collaborator

neuron-ui: Module not found: Error: Can't resolve '@nervosnetwork/ckb-sdk-utils' in '/home/runner/work/neuron/neuron/packages/neuron-ui/src/components/AmendPendingTransactionDialog'

@nervosnetwork/ckb-sdk-utils was removed by PR #3149

@silySuper
Copy link
Collaborator

silySuper commented May 14, 2024

/package
Packageing failed in 9076288137. @silySuper

@devchenyan
Copy link
Collaborator Author

devchenyan commented May 14, 2024

/package
Packaging for test is done in 9076510260. @devchenyan

@silySuper
Copy link
Collaborator

silySuper commented May 14, 2024

send transaction shows error.
截屏2024-05-14 18 02 23

main.log

@devchenyan
Copy link
Collaborator Author

send transaction shows error. 截屏2024-05-14 18 02 23

main.log

Is this an occasional or mandatory error, I didn't encounter this error when I downloaded the package and tested it.

@silySuper
Copy link
Collaborator

send transaction shows error. 截屏2024-05-14 18 02 23
main.log

Is this an occasional or mandatory error, I didn't encounter this error when I downloaded the package and tested it.

In my computer ,it is appear certainly,you can watch which informantion you need to check and I will offer you to solve it.

@yanguoyu
Copy link
Collaborator

send transaction shows error. 截屏2024-05-14 18 02 23

main.log

It will be better to describe how to reproduce this issue. And it looks like the replace_fee is less than required.
We can export the replacement transaction and the original transaction.

@silySuper
Copy link
Collaborator

send transaction shows error. 截屏2024-05-14 18 02 23
main.log

It will be better to describe how to reproduce this issue. And it looks like the replace_fee is less than required. We can export the replacement transaction and the original transaction.

It was created during send transaction, I have send transaction successfully once ,then click refresh ,then send transaction again ,then show the error always,also deposit show this error too.It is not created by special operration,but by normal operation.I guess it may related to sync block.

@silySuper
Copy link
Collaborator

silySuper commented May 15, 2024

sync has problem(sync progress see this issue:nervosnetwork/ckb#4462 I watch some situations which does not need transaction confirmed.
截屏2024-05-15 14 54 37
截屏2024-05-15 14 57 39

@devchenyan
Copy link
Collaborator Author

sync has problem(sync progress see this issue:nervosnetwork/ckb#4462 I watch some situations which does not need transaction confirmed. 截屏2024-05-15 14 54 37 截屏2024-05-15 14 57 39

1、amend transaction does not support selection of unit prices
2、“Unconfirmed Outputs are allowed in the transaction” is necessary
3、Too large a fee causes outputs to be larger than inputs, so cannot submit the transaction

@Danie0918
Copy link
Collaborator

sync has problem(sync progress see this issue:nervosnetwork/ckb#4462 I watch some situations which does not need transaction confirmed. 截屏2024-05-15 14 54 37 截屏2024-05-15 14 57 39

1、amend transaction does not support selection of unit prices 2、“Unconfirmed Outputs are allowed in the transaction” is necessary 3、Too large a fee causes outputs to be larger than inputs, so cannot submit the transaction

1.Why is the 'Price' button not available here, and also, how is the 'Suggested price' calculated?
2,3 OK

@devchenyan
Copy link
Collaborator Author

devchenyan commented May 15, 2024

sync has problem(sync progress see this issue:nervosnetwork/ckb#4462 I watch some situations which does not need transaction confirmed. 截屏2024-05-15 14 54 37 截屏2024-05-15 14 57 39

1、amend transaction does not support selection of unit prices 2、“Unconfirmed Outputs are allowed in the transaction” is necessary 3、Too large a fee causes outputs to be larger than inputs, so cannot submit the transaction

1.Why is the 'Price' button not available here, and also, how is the 'Suggested price' calculated? 2,3 OK

sync has problem(sync progress see this issue:nervosnetwork/ckb#4462 I watch some situations which does not need transaction confirmed. 截屏2024-05-15 14 54 37 截屏2024-05-15 14 57 39

1、amend transaction does not support selection of unit prices 2、“Unconfirmed Outputs are allowed in the transaction” is necessary 3、Too large a fee causes outputs to be larger than inputs, so cannot submit the transaction

1.Why is the 'Price' button not available here, and also, how is the 'Suggested price' calculated? 2,3 OK

Because it is recommended that the price options routinely suggested are likely to be lower than the price needed to amend the transaction.And the user does not need to amend the suggested price by himself.

Get min_replace_fee via api and calculate it with the size of the transaction to get the 'Suggested price'

@Danie0918
Copy link
Collaborator

sync has problem(sync progress see this issue:nervosnetwork/ckb#4462 I watch some situations which does not need transaction confirmed. 截屏2024-05-15 14 54 37 截屏2024-05-15 14 57 39

1、amend transaction does not support selection of unit prices 2、“Unconfirmed Outputs are allowed in the transaction” is necessary 3、Too large a fee causes outputs to be larger than inputs, so cannot submit the transaction

1.Why is the 'Price' button not available here, and also, how is the 'Suggested price' calculated? 2,3 OK

sync has problem(sync progress see this issue:nervosnetwork/ckb#4462 I watch some situations which does not need transaction confirmed. 截屏2024-05-15 14 54 37 截屏2024-05-15 14 57 39

1、amend transaction does not support selection of unit prices 2、“Unconfirmed Outputs are allowed in the transaction” is necessary 3、Too large a fee causes outputs to be larger than inputs, so cannot submit the transaction

1.Why is the 'Price' button not available here, and also, how is the 'Suggested price' calculated? 2,3 OK

Because it is recommended that the price options routinely suggested are likely to be lower than the price needed to amend the transaction.And the user does not need to amend the suggested price by himself.

Get min_replace_fee via api and calculate it with the size of the transaction to get the 'Suggested price'

OK.

@silySuper
Copy link
Collaborator

In cell management:
1.when click submit the transaction,transaction hash is null ,but can copy,copy result is undefined.
截屏2024-05-16 14 55 18

截屏2024-05-16 14 50 04

@devchenyan
Copy link
Collaborator Author

devchenyan commented May 17, 2024

In cell management: 1.when click submit the transaction,transaction hash is null ,but can copy,copy result is undefined. 截屏2024-05-16 14 55 18

截屏2024-05-16 14 50 04

fixed @silySuper

@devchenyan
Copy link
Collaborator Author

devchenyan commented May 17, 2024

/package
Packaging for test is done in 9121303973. @devchenyan

@silySuper
Copy link
Collaborator

In Nervos Dao:
withdraw/create account amend can only be operated once,when amend twice it shows
截屏2024-05-17 09 44 27

unlock does not see amend button.

截屏2024-05-17 09 45 09

@devchenyan
Copy link
Collaborator Author

In Nervos Dao: withdraw/create account amend can only be operated once,when amend twice it shows 截屏2024-05-17 09 44 27

unlock does not see amend button.

截屏2024-05-17 09 45 09
  1. withdraw/create account amend can amend twice. Please make sure that the amend tx is new transaction, as the amended transaction will fail and be removed.
    image
Screen-2024-05-17-113455.mp4
  1. The type of Unlcok is 'receive'. The treatment condition inputs-fee=outputs is not satisfied
image

@silySuper
Copy link
Collaborator

silySuper commented May 20, 2024

/package
Packaging for test is done in 9152602959. @silySuper

@silySuper
Copy link
Collaborator

silySuper commented May 20, 2024

In Nervos Dao: withdraw/create account amend can only be operated once,when amend twice it shows 截屏2024-05-17 09 44 27
unlock does not see amend button.
截屏2024-05-17 09 45 09

  1. withdraw/create account amend can amend twice. Please make sure that the amend tx is new transaction, as the amended transaction will fail and be removed.
    image

Screen-2024-05-17-113455.mp4
2. The type of Unlcok is 'receive'. The treatment condition inputs-fee=outputs is not satisfied

image

For the first problem,your video is different from mine.My operation is clicking amend when status is pending on amend transaction(not the first transaction). I guess is the status is failed in db,but shows pending in page cause this problem,so you can click amend but cannot fill in amend data.This can be considered to optimize when you are convenient later.

@yanguoyu yanguoyu added this pull request to the merge queue May 20, 2024
Merged via the queue into develop with commit 2fcc43d May 20, 2024
23 checks passed
@yanguoyu yanguoyu deleted the fix-332 branch May 20, 2024 07:42
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