Skip to content

fix: Mock mainnet begin block deployment fix btc duplicate payment#1266

Merged
ws4charlie merged 4 commits intomock-mainnet-begin-block-deploymentfrom
mock-mainnet-begin-block-deployment-fix-btc-duplicate-payment
Oct 11, 2023
Merged

fix: Mock mainnet begin block deployment fix btc duplicate payment#1266
ws4charlie merged 4 commits intomock-mainnet-begin-block-deploymentfrom
mock-mainnet-begin-block-deployment-fix-btc-duplicate-payment

Conversation

@ws4charlie
Copy link
Contributor

Description

After double payment on nonce 0, the expected nonce mark UTXO was already spent
txid:71395db26ae81147dd79176e394c598b9480036c5ef6e44608b3356283168872 vout: 0 amount: 2000

To recover, we can use this UTXO as the nonce-mark
txid:26aa6b32b7f16cc6671ac1419e91bac5fb78b5d24536df0da0120a3f75bf9116 vout: 0 amount: 2000

Closes:

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Include instructions and any relevant details so others can reproduce.

  • Tested CCTX in localnet
  • Tested in development environment
  • Go unit tests
  • Go integration tests
  • Tested via GitHub Actions

Checklist:

  • I have added unit tests that prove my fix feature works

…begin-block-deployment-fix-btc-duplicate-payment
@ws4charlie ws4charlie merged commit 70b94ff into mock-mainnet-begin-block-deployment Oct 11, 2023
lumtis pushed a commit that referenced this pull request Oct 16, 2023
* add begin blocked deployemnts for mock mainent

* panic when telemetry server does not start

* report bitcoin fee in sat/byte instead of stas/KB

* compensate for the low gaslimit on BTC

* fix: Mock mainnet begin block deployment fix btc duplicate payment (#1259)

* special handling to avoid duplicate payment on bitcoin outbound nonce 0

* use cctx amount instead of txResult's amount because it's not available in bitcoin mainnet

---------

Co-authored-by: charliec <charliec@zetachain.com>

* fix: Mock mainnet begin block deployment fix btc duplicate payment (#1266)

* special handling to avoid duplicate payment on bitcoin outbound nonce 0

* use cctx amount instead of txResult's amount because it's not available in bitcoin mainnet

* mockmain bootstrap from double payment on nonce 0

---------

Co-authored-by: charliec <charliec@zetachain.com>

* revert hard coded outTx hash for nonce 0

* removed division by 1000 in fee calculation (#1275)

Co-authored-by: charliec <charliec@zetachain.com>

* try to fix smoketest due to BTC ZRC20 audit

---------

Co-authored-by: Tanmay <tanmay.bhattacharya.smit@gmail.com>
Co-authored-by: Tanmay <tanmay@zetachain.com>
Co-authored-by: Charlie Chen <34498985+ws4charlie@users.noreply.github.com>
Co-authored-by: charliec <charliec@zetachain.com>
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.

2 participants