-
Notifications
You must be signed in to change notification settings - Fork 122
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
Anchor Bugs - reward payout order, missing anchor (failed anchor detection) #524
Comments
@DefichainHelper33: Thanks for opening an issue, it is currently awaiting triage. The triage/accepted label can be added by foundation members by writing /triage accepted in a comment. DetailsI am a bot created to help the DeFiCh developers manage community feedback and contributions. You can check out my manifest file to understand my behavior and what I can do. If you want to use this for your project, you can check out the DeFiCh/oss-governance-bot repository. |
On the 12.06 and the 13.06 there were again a lot of undiscovered anchors. The latest anchor reward on 13.06 was also paid to an The undiscovered anchors can be seen here: https://www.blockchain.com/btc/address/1FtZwEZKknoquUb6DyQHFZ6g6oomXJYEcb. Two of this anchors belong two me and I can guarantee that they were valid and build on the same anchor chain as the latest selected anchor. Here is the list of undiscovered anchors which competed for the latest anchor reward:
There were also 2 undiscovered anchors, two anchor rewards earlier. 3 anchors were within the same bitcoin block (687207) and only the anchor with the worst
|
I can confirm the above mentioned issues (I have created some of the above mentioned anchors). Additional comments:
defi-cli spv_createanchortemplate df1q9j8trl4xvrldf6fcusf39x3t2tfr308qxjy349 When an anchor with a non-legacy address is created, the reward is never recieved. |
Legacy and Bech32 addresses are accepted and will be paid if they are an active anchor. The anchor above was paid, here's the entry for it from Thanks for the report on missing anchors, I'm looking into it now.
|
Thanks for the information! I got the impression that the reward is not paid, because the reward is not showing up via
|
It is a UTXO reward paid here. The funds have already been spent sending them to the account layer. https://chainz.cryptoid.info/dfi/address.dws?df1q9j8trl4xvrldf6fcusf39x3t2tfr308qxjy349.htm |
@DefichainHelper33 about the second bug, you said about anchors that were created but not discovered for hours. Can you confirm that the anchor that was not being seen was confirmed on the Bitcoin network, in that it had made its way into a Bitcoin block and was still not seen by your node? Anchors are not accepted for payment until they are included in a block and have six confirmations, an anchor paying a high fee could be added after another anchor and still be confirmed by Bitcoin and paid by DeFi chain first. There is a certain inconsistent experience expected with anchors due to their decentralised nature that relies on masternodes to create the anchor data, read and confirm anchors and then pay them. |
Those undiscovered anchors were found but were invalid, the DFI anchor block time should be at least three hours before the Bitcoin block time the anchor is embedded in. This can be changed in future releases to make sure anchor data is created further back.
|
@Bushstar Yes I can confirm. All anchors were confirmed by the bitcoin network within one block and had more then 6 confirmations without being added to Thanks for the info, this means that |
/triage accepted |
The masternodes create anchor data for use in anchors, the data includes the block to be anchors, it is created every 15 blocks and goes back 3 hours from that blocks time and then a further number of blocks to a 15 block interval which may be no blocks at all. With the super miner update blocks are being created in the future up to five minutes, I expect this is responsible to the anchors falling foul of the time rule. In the next major update we will increase the block sample time to go further back in the DFI chain. |
Please note that 1.7.11 has been updated to not select anchor data less than three hours older than the local time, this should help with missing anchors. 1.7.11 has also been updated to pay anchors in Bitcoin height order though this will not take effect until MNs have updated. |
I discovered two anchor bugs since the eunos hard fork:
First Bug
the newer anchor received the bigger anchor reward (wrong order of anchor reward payment)
on 9.06.2021 two valid anchors were created:
The second anchor references the first anchor as prev-anchor => they are both valid in the same chain
The second anchor received the higher reward of 376.768208 DFI - reward tx 73ffa06a11c57868df878711fed5a2fb2cc6e3ee5555e42bbbe0a1edeb7e8d52 (block: 909843)
The first anchor received the reward afterwards of 0.081008 DFI - reward tx 9a638b3e3ed2823981ebdee24d1c7050f0d717111570e2eb9a352085f1afb06e (block 909844)
Expected behavior:
First anchor should receive the full reward and second anchor should receive the 0.08 DFI. This was also the behavior before the hard fork (maybe it was random and the correct anchor got to rewards by luck)
Second Bug
Not all anchors are discovered in time. (reward went to wrong anchor because of undiscovered anchor)
The anchor tx: e950a67fb3636ddf83d3b72ff9e2c34a743c0a1c5de4ff9814a0fbdcb9b00ac6 was created on 11.06 13:14 but only discovered by the nodes a few hours later. (Note: this anchor was/is invalid because it breaks the anchor chain)
The anchor tx: b17b2919c807cbd61e82f4faa4464850c4b2a06f2002b0808c0fb31f42000000 was created on 11.06 17:26 but has not yet been discovered by the nodes. This anchor is valid and would have received a reward of 80 DFI.
The anchor tx: d6d001203d24fb495d70ce0e01a762bffa9dbf765268114478ec73049a28f1e4 was created on 11.06 18:19 and has been discovered by the nodes about 30min later. This anchor received the reward which would normally go to the b17b... anchor.
Before Eunos: Anchors were discovered immediately -> this is also the expected behavior.
The text was updated successfully, but these errors were encountered: