Skip to content

[BUG] Error "Send Failed : mandatory-script-verify-flag-failed (Signature is found in scriptCode) (code 16)" on hydradex.org devnet #15

@nenantonov

Description

@nenantonov

Description:
In some cases hydradex.org will not swap and the error Send Failed : mandatory-script-verify-flag-failed (Signature is found in scriptCode) (code 16) will be displayed.

Wallet used to replicate the error on devnet:
Address: HQyFULzdyYv4jQiwsHVhDRVrxB8EshWjEX

DEX used in devnet:
https://hydraw-swap.herokuapp.com/#/swap

Extension used in devnet:
devnet_hydrawallet_working.zip

Video to replicate the issue:

2022-04-11.11-32-43.mp4

Image with the last tx in the wallet (coinbase tx) when the issue occurs:

image

Findings:

  1. The error occurs when the UXTO used for the swap has a coinbase transaction (empty first tx, with reward from staking);
  2. Making a transaction to send 10 Hydras to the same wallet does not help circumvent the error in this particular case, because the staking wallet uses for the send tx the smallest suitable UTXO, while the DEX likely tries to use the biggest available UTXO, which happens to be a coinbase UTXO;
  3. Making a transaction to send the whole balance to the same wallet helps circumvent the error, becasue then the biggest available UTXO is no longer a coinbase UTXO.

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions