DigiByte-Core / digibyte

DigiByte Core 7.17.3 - CURRENT (5-12-2021) - 8.22.0 Development
https://digibyte.org
MIT License
102 stars 62 forks source link

Manually Selecting 15+ TX Inputs Throws TX FEE Error, Can't De-Dust Wallet #163

Closed JaredTate closed 9 months ago

JaredTate commented 9 months ago

When using coin control & selecting 15 or more manual inputs, the QT core wallet throws a TX error. We don't have the fee rates set correctly. Screenshot 2024-01-29 at 3 16 01 PM Screenshot 2024-01-29 at 3 16 10 PM Screenshot 2024-01-29 at 3 16 59 PM

The error is defined here in code: https://github.com/DigiByte-Core/digibyte/blob/e8247b0d596a443eb75f7bd6a9760534970eb25d/src/util/error.cpp#L32-L33

It looks like the bug is now in MAX_FEE_EXCEEDED Well, the bug is the fee rates we just changed most likely. Should be an easy fix, just need to calculate all the fee rates correctly. MAX_FEE_EXCEEDED is defined here: https://github.com/DigiByte-Core/digibyte/blob/e8247b0d596a443eb75f7bd6a9760534970eb25d/src/node/transaction.cpp#L67-L78

ghost commented 9 months ago

Dev branch https://github.com/DigiByte-Core/digibyte/blob/e8247b0d596a443eb75f7bd6a9760534970eb25d/src/wallet/wallet.h#L99-L104

Screenshot from 2024-01-30 23-12-41

DEFAULT_TRANSACTION_MAXFEE From COIN /10 to COIN HIGH_MAX_TX_FEE from 100 to 1000

//! -maxtxfee default constexpr CAmount DEFAULT_TRANSACTION_MAXFEE{COIN};

//! -maxtxfee will warn if called with a higher fee than this amount (in satoshis) constexpr CAmount HIGH_MAX_TX_FEE{1000 * HIGH_TX_FEE_PER_KB};

Screenshot from 2024-01-30 23-10-13

JaredTate commented 9 months ago

Fixed with https://github.com/DigiByte-Core/digibyte/pull/165